diskusagestats syntax error: invalid literal for int() with base 10: ''
Closed this issue · 3 comments
selene:/usr/lib/python2.7/site-packages/freeswitchESL
[33] root# munin-run diskusagestats config
EXCEPTION: invalid literal for int() with base 10: ''
Traceback (most recent call last):
File "/etc/munin/plugins/diskusagestats", line 9, in
load_entry_point('PyMunin==0.9.22', 'console_scripts', 'pymunin-diskusagestats')()
File "/usr/lib64/python2.7/site-packages/pymunin/plugins/diskusagestats.py", line 165, in main
sys.exit(muninMain(MuninDiskUsagePlugin))
File "/usr/lib64/python2.7/site-packages/pymunin/init.py", line 957, in muninMain
plugin = pluginClass(argv, env, debug)
File "/usr/lib64/python2.7/site-packages/pymunin/plugins/diskusagestats.py", line 107, in init
self._statsInode = self._info.getInodeUse()
File "/usr/lib64/python2.7/site-packages/pysysinfo/filesystem.py", line 115, in getInodeUse
fsstats['inuse_pcent'] = int(cols[4][:-1])
ValueError: invalid literal for int() with base 10: ''
Hi,
Could you send me the output for the following command after running first with the user root and then with an unprivileged user:
df -i -Pk
Thanks in advance...
selene:~
[13] root# df -i -Pk
Filesystem Inodes IUsed IFree IUse% Mounted on
rootfs 6553600 464311 6089289 8% /
udev 1534721 510 1534211 1% /dev
/dev/md0 6553600 464311 6089289 8% /
tmpfs 1535128 507 1534621 1% /run
cgroup_root 1535128 4 1535124 1% /sys/fs/cgroup
shm 1535128 2 1535126 1% /dev/shm
/dev/md1 0 0 0 - /home
/dev/md2 0 0 0 - /var/data
selene:~
[14] root# sudo -u munin df -i -Pk
Filesystem Inodes IUsed IFree IUse% Mounted on
rootfs 6553600 464312 6089288 8% /
udev 1534721 510 1534211 1% /dev
/dev/md0 6553600 464312 6089288 8% /
tmpfs 1535128 507 1534621 1% /run
cgroup_root 1535128 4 1535124 1% /sys/fs/cgroup
shm 1535128 2 1535126 1% /dev/shm
/dev/md1 0 0 0 - /home
/dev/md2 0 0 0 - /var/data
My pleasure :) I see the values for my /home and /var/data are empty, this is likely because they are btrfs partitions and do not contain inodes in the traditional sense.
Just pushed a change to fix this issue. I did some testing to assure that the issue has been fixed before closing the issue. Please do not doubt to reopen the issue in case you continue experiencing problems.
Thanks for helping improve PyMunin.