GreenLake Administration
- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- "df -b" vs "df -k" vs bdf
Operating System - HP-UX
1850102
Members
2910
Online
104050
Solutions
Forums
Categories
Company
Local Language
back
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Forums
Discussions
back
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-20-2001 06:42 PM
08-20-2001 06:42 PM
"df -b" vs "df -k" vs bdf
Anybody knows what's the difference between df -b and df -k? How come the free space is different in these two output?
Thanks,
# bdf /home
Filesystem kbytes used avail %used Mounted on
/dev/vg00/lvol4 79701 58345 13385 81% /home
# df -b /home
/home (/dev/vg00/lvol4 ) : 21356 Kbytes free
# df -k /home
/home (/dev/vg00/lvol4 ) : 71730 total allocated Kb
13385 free allocated Kb
58345 used allocated Kb
81 % allocation used
Thanks,
# bdf /home
Filesystem kbytes used avail %used Mounted on
/dev/vg00/lvol4 79701 58345 13385 81% /home
# df -b /home
/home (/dev/vg00/lvol4 ) : 21356 Kbytes free
# df -k /home
/home (/dev/vg00/lvol4 ) : 71730 total allocated Kb
13385 free allocated Kb
58345 used allocated Kb
81 % allocation used
1 REPLY 1
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-20-2001 10:07 PM
08-20-2001 10:07 PM
Re: "df -b" vs "df -k" vs bdf
Hi
df -b reports the number of kilobytes free
df -k reports the allocation in kilobytes( calculates free as total - used )
sometimes there is inconsistency between the two when say, some file has been deleted but there still exist some file handlers accessing that file.
Suppose a process writes into a file and you have deleted the file. The space allocated to the file is released but as long as the process accessing the file exists the space is not totally free. This has been a recurring problem when we run our applications in a debug mode. The log gets large filling up the entire file system and when we delete the file manually df -b ,df -k and du show different values. Only we stop our application, the commands show the same values.
Something of this kind may be happening about your place.
Hope this helps.
...BPK...
df -b reports the number of kilobytes free
df -k reports the allocation in kilobytes( calculates free as total - used )
sometimes there is inconsistency between the two when say, some file has been deleted but there still exist some file handlers accessing that file.
Suppose a process writes into a file and you have deleted the file. The space allocated to the file is released but as long as the process accessing the file exists the space is not totally free. This has been a recurring problem when we run our applications in a debug mode. The log gets large filling up the entire file system and when we delete the file manually df -b ,df -k and du show different values. Only we stop our application, the commands show the same values.
Something of this kind may be happening about your place.
Hope this helps.
...BPK...
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
Company
Events and news
Customer resources
© Copyright 2026 Hewlett Packard Enterprise Development LP