当我尝试在Centos 5.8(内核2.6.32.9)上运行iotop时,出现以下错误:
Traceback (most recent call last):
File "/usr/bin/iotop", line 16, in ?
main()
File "/usr/lib/python2.4/site-packages/iotop/ui.py", line 567, in main
main_loop()
File "/usr/lib/python2.4/site-packages/iotop/ui.py", line 557, in <lambda>
main_loop = lambda: run_iotop(options)
File "/usr/lib/python2.4/site-packages/iotop/ui.py", line 465, in run_iotop
return curses.wrapper(run_iotop_window, options)
File "/usr/lib64/python2.4/curses/wrapper.py", line 44, in wrapper
return func(stdscr, *args, **kwds)
File "/usr/lib/python2.4/site-packages/iotop/ui.py", line 457, in run_iotop_window
process_list = ProcessList(taskstats_connection, options)
File "/usr/lib/python2.4/site-packages/iotop/data.py", line 375, in __init__
self.update_process_counts()
File "/usr/lib/python2.4/site-packages/iotop/data.py", line 431, in update_process_counts
stats = self.taskstats_connection.get_single_task_stats(thread)
File "/usr/lib/python2.4/site-packages/iotop/data.py", line 158, in get_single_task_stats
reply = self.connection.recv()
File "/usr/lib/python2.4/site-packages/iotop/netlink.py", line 229, in recv
raise err
OSError: Netlink error: Invalid argument (22)
iotop是通过使用
yum install iotop
安装的 最佳答案
我可以按照以下步骤纠正此错误
yum remove iotop
yum install python26
rpm -ivh http://guichaz.free.fr/iotop/files/iotop-0.4.1-1.noarch.rpm
#!/usr/bin/python
编辑为#!/usr/bin/python2.6
iotop
并享受关于linux - Centos 5.8上的iotop-OSError : Netlink error: Invalid argument (22),我们在Stack Overflow上找到一个类似的问题:https://stackoverflow.com/questions/22786368/