Reputation: 719
I am writing a script which checks space on UNIX servers. But I am unable to find the right command. I used the following but it gives me same percentage for all paths.
st = os.statvfs("/dev/hd3")
Upvotes: 0
Views: 1947
Reputation: 4314
You give it the mount point, not the device name.
So, instead of e.g.
st = os.statvfs("/dev/hd3")
you do
st = os.statvfs("/boot")
Upvotes: 1