cancel
Showing results for 
Search instead for 
Did you mean: 

fdisk on Linux

zhaogui
Super Advisor

fdisk on Linux

fdisk -l only lists file systems in blocks(by cylinders or sectors), how can I get it in unit of MB?
Is there swapinfo equivalent on Linux?

Thanks,
2 REPLIES
I_M
Honored Contributor

Re: fdisk on Linux

Hi

> Is there swapinfo equivalent on Linux?

cat /proc/meminfo
free

regards,
Stuart Browne
Honored Contributor

Re: fdisk on Linux

The 'fdisk' command has no arguments to translate the block count into megabytes.

Probably the easiest way would be to use either 'df', or possibly 'cfdisk -Ps', and then parse the appropriate column...

One long-haired git at your service...