21

I use df -h to see formatted size, but how to see actual?

I believe one of my disks is 3TB but formatted as 2TB but not sure which. (they're remote so I can't look!)

Lucio
  • 19,191
  • 32
  • 112
  • 191

3 Answers3

35

You can try lsblk.

That should list all disks including size. It will also list partitions and mount points.

l3dx
  • 501
4

You could try parted

sudo parted -l

or if you know the particular disk's block device e.g. /dev/sda

sudo parted /dev/sda print 

As well as looking at the formatted partition size(s), take note of the 'Partition Table' line - if the disk was formatted with 'Partition Table: msdos' then you may be bumping up against the intrinsic 2TB limit - the disc may need to be converted to a GPT partition table in order to access the full 3TB

steeldriver
  • 142,475
1

You can also try the following command:

sudo hdparm -I /dev/your_device |grep GB

Change your_device with a the device name (sda, sdb, etc)

jctoledo
  • 1,589