Re: making more room in root partition for distribution upgrade
On Sun, May 20, 2018 at 3:19 AM, Pascal Hambourg <pascal@plouf.fr.eu.org> wrote:
> Le 18/05/2018 à 02:05, Mark Copper a écrit :
>>>
>>>
>>>> There was a day when a 10 gb partition seemed like plenty of space to
>>>> leave
>>>> for the system but now it's not. An upgrade to Stretch appears to need
>>>> more.
>
>
> How do you know ?
I don't, actually. I'm reacting to warnings of limited space received
when upgrading Jessie. And previously when upgrading from Wheezy IIRC.
>
>>>> Device Boot Start End Sectors Size Id Type
>>>> /dev/sda1 * 2048 19531775 19529728 9.3G 83 Linux
>>>> /dev/sda2 19533822 312580095 293046274 139.8G 5 Extended
>>>> /dev/sda5 19533824 27578367 8044544 3.9G 82 Linux swap /
>>>> Solaris
>>>> /dev/sda6 27580416 312580095 284999680 135.9G 83 Linux
>>>>
>>>> $ cat /etc/fstab
>>>> # / was on /dev/sda1 during installation
>>>> # /home was on /dev/sda6 during installation
>>>> # swap was on /dev/sda5 during installation
>
>
>>>> This must be a FAQ. But there appear to be two ways forward.
>>>>
>>>> 1. Back-up /home, enlarge / partition, copy back-up back to new, smaller
>>>> /home partition (because /home will then start on a different cylinder
>>>> so
>>>> data will be lost).
>
>
> You will have to move/delete and re-create the swap too.
> Gparted allows to resize and move an unused partition. Better have a backup
> though.
yes, if I understand, the file system is lost on any partition,
primary or logical, whose first cylinder is changed.
>
>>>> 2. Carve out a new partition for /usr at end of disk which will free up
>>>> over 6 gb.
>
>
> The Debian initramfs supports a separate /usr since Jessie.
Given the system as it currently exists, this seems the easiest way to
go. (actually there are several boxes like this needing attention).
>
>> $ du -h /var
>> ...
>> 598M /var
>>
>> but
>>
>> $ du -h /usr
>> ...
>> 4.2G /usr/share
>> 6.5G /usr
>
>
> What about the rest ? How much free space is available ?
> Maybe the upgrade requires more space in order to download and store the new
> packages. Have you considered moving /var/cache/apt/archives to the /home
> partition (through a symlink or bind mount) so that downloaded packages do
> not use space in the / filesystem ?
>
Yes, should have included that:
:~# df -h
Filesystem Size Used Avail Use% Mounted on
/dev/sda1 9.1G 7.8G 870M 91% /
udev 10M 0 10M 0% /dev
tmpfs 402M 6.1M 396M 2% /run
tmpfs 1005M 92K 1005M 1% /dev/shm
tmpfs 5.0M 4.0K 5.0M 1% /run/lock
tmpfs 1005M 0 1005M 0% /sys/fs/cgroup
/dev/sda6 134G 6.0G 121G 5% /home
tmpfs 201M 8.0K 201M 1% /run/user/1000
/dev/sdb3 915G 5.8G 863G 1% /media/mark/d-live 9.4.0 gn amd64
/dev/sdb1 2.3G 2.3G 0 100% /media/mark/d-live 9.4.0 gn amd641
No, I had not considered playing with any part of /var. With /var
taking less than 1 gb and /var/cache/apt/archives less than 1mb, /usr
had seemed the elephant in the room. Might that be a way to go? I just
need to get to Stretch for now.
Thank you.
Reply to: