Home » Infrastructure » Unix » df help
df help [message #147471] Thu, 17 November 2005 14:28 Go to next message
alka205
Messages: 18
Registered: August 2005
Junior Member
How do I sort the filesystem using df on maximum used on top??

df -k (what other switch)

Thanks

Re: df help [message #147479 is a reply to message #147471] Thu, 17 November 2005 16:26 Go to previous message
andrew again
Messages: 2577
Registered: March 2000
Senior Member
On Solaris:
sun1> df -k
Filesystem           1024-blocks        Used   Available Capacity  Mounted on
/dev/md/dsk/d1          10325760     2128111     8094392    21%    /
/proc                          0           0           0     0%    /proc
fd                             0           0           0     0%    /dev/fd
mnttab                         0           0           0     0%    /etc/mnttab
swap                     3258288          16     3258272     1%    /var/run
/dev/md/dsk/d3            494235        2397      442415     1%    /tmp
/dev/md/dsk/d4           3458922     2360622     1063711    69%    /users


sun1>  df -k | awk 'NR != 1 { print $0 }' | sort -r +n +3
/dev/md/dsk/d1          10325760     2128111     8094392    21%    /
/dev/md/dsk/d4           3458922     2360622     1063711    69%    /users
/dev/md/dsk/d3            494235        2397      442415     1%    /tmp
/proc                          0           0           0     0%    /proc
fd                             0           0           0     0%    /dev/fd

-r=Reverse
+n=Treat as numeric
+3=4th column

[Updated on: Thu, 17 November 2005 16:29]

Report message to a moderator

Previous Topic: Problem in using uuencode to attach files in mail
Next Topic: Oradebug utility works but no trace file
Goto Forum:
  


Current Time: Mon Nov 25 10:37:55 CST 2024