Where is my disk space?
I'm supposed to have 50GB of space.
:/$ df -h --total
:/$ df -h --total
Filesystem Size Used Avail Use% Mounted on
/dev/root 30G 8.1G 20G 30% /
devtmpfs 980M 0 980M 0% /dev
tmpfs 984M 0 984M 0% /dev/shm
tmpfs 984M 720K 983M 1% /run
tmpfs 5.0M 0 5.0M 0% /run/lock
tmpfs 984M 0 984M 0% /sys/fs/cgroup
tmpfs 197M 0 197M 0% /run/user/1000
total 34G 8.1G 24G 26% -
It says total size is 34GB. What am I missing here?
Thanks.
Al
(Is there a way to format so that columns are lined up? The spaces were stripped out here.)
5 Replies
That is only the partition or filesystem’s size.
The underlying storage disk should be 50GB, and you can resize the partition and filesystem into it.
Try a guide like this: https://www.cyberciti.biz/faq/linux-extend-file-system-after-resize-disk-volume/
To further apmplify @andysh's point, the rest of it is probably allocated to swap…either a swap partition or swap file. See:
https://averagelinuxuser.com/linux-swap/
You can verify this by looking at your disc configuration in the Cloud Manager.
(Is there a way to format so that columns are lined up? The spaces were stripped out here.)
See the [http://demo.showdownjs.com/](Markdown cheatsheet). To answer your specific question, format the section as code by inserting a line of ``` (3 bacticks) before and after the section you want formatted as code:
```
Filesystem Size Used Avail Use% Mounted on
udev 932M 0 932M 0% /dev
tmpfs 200M 21M 180M 11% /run
/dev/sdb2 456G 3.8G 429G 1% /
tmpfs 999M 0 999M 0% /dev/shm
tmpfs 5.0M 0 5.0M 0% /run/lock
tmpfs 999M 0 999M 0% /sys/fs/cgroup
/dev/mmcblk0p1 15G 31M 15G 1% /media
tmpfs 999M 4.0K 999M 1% /tmp
tmpfs 200M 0 200M 0% /run/user/1000
total 474G 3.9G 447G 1% -
```
will appear as
Filesystem Size Used Avail Use% Mounted on
udev 932M 0 932M 0% /dev
tmpfs 200M 21M 180M 11% /run
/dev/sdb2 456G 3.8G 429G 1% /
tmpfs 999M 0 999M 0% /dev/shm
tmpfs 5.0M 0 5.0M 0% /run/lock
tmpfs 999M 0 999M 0% /sys/fs/cgroup
/dev/mmcblk0p1 15G 31M 15G 1% /media
tmpfs 999M 4.0K 999M 1% /tmp
tmpfs 200M 0 200M 0% /run/user/1000
total 474G 3.9G 447G 1% -
You can do the same with a single line or series of words by surrounding the line or phrase with a single backtick (`)…e.g., `like this` will appear like this
.
-- sw
Steve:
You can verify this by looking at your disc configuration in the Cloud Manager.
Where is that in the manager? All I can find is:
Disks
Ubuntu 16.04 LTS Disk ext4 30464 MB 2016-11-27 14:02
256MB Swap Image swap 256 MB 2016-11-27 14:02
Here is what I posted above in a better format. Why don't the partition sizes add up to 50 GB?
xxxx@mars:~$ df -h --total
Filesystem Size Used Avail Use% Mounted on
/dev/root 30G 8.1G 20G 29% /
devtmpfs 980M 0 980M 0% /dev
tmpfs 984M 0 984M 0% /dev/shm
tmpfs 984M 712K 983M 1% /run
tmpfs 5.0M 0 5.0M 0% /run/lock
tmpfs 984M 0 984M 0% /sys/fs/cgroup
tmpfs 197M 0 197M 0% /run/user/1000
total 34G 8.1G 24G 26% -
Thanks for the Markdown help. I've never gotten into it since I know HTML so well.
Al
Where is that in the manager?
It's at http://cloud.linode.com. Login, click on your Linode's name then click on the link entitled Storage. In your listing, the line
total 34G 8.1G 24G 26% -
^
+--- should roughly add up to the size of your file
system partition in the Cloud Manager.
For example, my 'total' line is:
total 27G 6.8G 20G 26% -
Cloud Manager reports my filesystem partition is 20971 MiB (roughly 20 GiB)…so things (roughly) match up.
Why don't the partition sizes add up to 50 GB?
You may not have allocated all the disc space available to your Linode to your Linode's file systems. I do that…so I have the space to restore backups if I need to.
The file systems involved (ext4 and swap) have overhead required for operation. ext4 is a journaling file system and needs to reserve usable space in the partition for the journal.
If you need any more information, I suggest you file a support ticket. They can explain the ins/outs of this much better than I can.
-- sw
Login, click on your Linode's name then click on the link entitled Configuration.
I don't see anything about sizes, etc. All I see is:
My Ubuntu 16.04 LTS Profile – Latest 64 bit (5.11.13-x86_64-linode143) /dev/sda - Ubuntu 16.04 LTS Disk /dev/sdb - 256MB Swap Image eth0 – Public Internet
Anyway, this disk space thing was all just a curiosity… not a 'real' issue.