Title photo
frugal technology, simple living and guerrilla large-appliance repair
Fri, 11 Mar 2011

How do I have my 3 GB drive partitioned in Debian?

Here’s the output of df -h:

steven@compaq:~$ df -h
Filesystem            Size  Used Avail Use% Mounted on
/dev/sda2             2.2G  1.5G  604M  71% /
tmpfs                  70M     0   70M   0% /lib/init/rw
udev                   65M  104K   65M   1% /dev
tmpfs                  70M     0   70M   0% /dev/shm
/dev/sda5             388M   85M  283M  24% /home

It doesn’t show in this output, but /dev/sda1 is 500 MB of swap. /dev/sda5 is a logical partition.

One of the helpful steps in the Debian Squeeze release notes, which you really should use when upgrading from Lenny, is to check how much disk space is needed to do the upgrade. I’ve been keeping a relatively large root partition (2.2 GB) for overhead in an upgrade, and if I remember correctly I didn’t need anywhere near that much space to do the Lenny-to-Squeeze transition.

I’ve been burned more than a couple of times when doing upgrades, both Linux and OpenBSD, when I ran out of space in a critical partition in the middle of the process. Being able to check before doing the upgrade is a very good thing.

Now that I know I don’t need all this space for applications, I could start up Parted Magic, shrink the root partition and expand the extended partition that holds /home.