df(1) in MacOS 10.9
I haven't used "Mavericks" that much yet, but one thing that caught my eye early on was a change in df(1):
$ df -h / Filesystem Size Used Avail Capacity iused ifree %iused Mounted on /dev/disk1 118Gi 14Gi 104Gi 12% 3626080 27340805 12% /Wtf? Why are they displaying inode allocation by default? Well, in their manpage they state:
-i Include statistics on the number of free inodes. This option is now the default to conform to Version 3 of the Single UNIX Specification (``SUSv3'') Use -P to suppress this output.Ah, SUSv3. That was released in 2002 - of course MacOS 10.9 has to catch up on portability here, sure1 :-)
Let's look at SUSv3 (aka "IEEE Std 1003.1-2001") then:
The df utility shall write the amount of available space [XSI] > and file slots <And this XSI stands for "Extension":
The functionality described is an XSI extension. Functionality marked XSI is also an extension to the ISO C standard. Application writers may confidently make use of an extension on all systems supporting the X/Open System Interfaces Extension.So, it's not so much a conformity issue but a mere choice to include the ouput of inode usage in the newest iteration of MacOS X. While it's still not clear why they changed it (and left
-t
a no-op), let's look at other Unix versions:
$ uname -srv; df -h / SunOS 5.10 Generic_144500-19 Filesystem size used avail capacity Mounted on /dev/md/dsk/d1 7.9G 3.0G 4.8G 39% / $ uname -srv; df -k / AIX 3 5 Filesystem 1024-blocks Free %Used Iused %Iused Mounted on /dev/hd4 262144 175244 34% 3919 10% /To restore the old behaviour in MacOS, use
-P
:
$ df -Ph / Filesystem Size Used Avail Capacity Mounted on /dev/disk1 118Gi 14Gi 104Gi 12% /
1Overlooking the fact that their manpage still reads "May 8, 1995" at the end...