[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: df -h listing



On Mon, Oct 08, 2007 at 09:55:26AM EDT, Miles Bader wrote:
> Rick Pasotto <rick@niof.net> writes:
> >> I think you missed someting? like the -n flag? If you do a normal sort,
> >> its alphabetic. With -n, it is done numeric.
> >
> > That's true but it doesn't help anyway. 57K will sort larger than 2M.
> 
> You could do it in two stages, first without -h, to sort, then with -h,
> to display... e.g.:
> 
>    df -h `df | tail -n +2 | sort -n -k2 | awk '{print $NF}'`

Very elegant.

Thanks,
cga



Reply to: