[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Upgrading Kernel - Out of Disk Space



Gary Dale a écrit :
>> $ df -h
>> Filesystem                Size  Used Avail Use% Mounted on
>> /dev/mapper/lapsdeb-root  314M  237M   57M  81% /
>> /dev/mapper/lapsdeb-var   2.7G  318M  2.3G  13% /var
>> /dev/mapper/lapsdeb-usr   8.2G  2.6G  5.2G  34% /usr
>> /dev/mapper/lapsdeb-tmp   360M  2.1M  335M   1% /tmp
>> /dev/sda1                 228M   21M  196M  10% /boot
>> /dev/mapper/lapsdeb-home  274G  8.5G  252G   4% /home
> 
> That is an unusual file system.

Unfortunately not. It's the result of the Debian installer automatic
partitioner when you choose to separate all main system directories.
It is broken in several ways :
- / is too small for current kernels ;
- /usr, /tmp and /var may be too small too ;
- when using LVM, it does not reserve any free space for future
allocation/resizing.

For these reasons and others, I never use the automatic partitioner.

> The problem is that your / partition only has 314M allocated to it. This 
> is ridiculously small. I understand people use LVM because it supposedly 
> makes adding more space easier. Figure out how to use LVM to increase 
> your / allocation to something more reasonable. 20G is what I would 
> normally use as a minimum, with more for desktop use.
> 
> You've got 252G free on /home. Shifting some of that over to / would do 
> wonders.

First, check if you cannot free some (~100 MB) space in the / filesystem
(/root, /srv, /opt).

Otherwise, you can extend a mounted ext2/3/4 filesystem on an LVM
logical volume. However you cannot reduce an ext mounted filesystem.

Boot in rescue mode.
Unmount /home.
Reduce /dev/mapper/lapsdeb-home filesystem with resize2fs or relevant tool.
Reduce /dev/mapper/lapsdeb-home logical volume with lvreduce.
Extend /dev/mapper/lapsdeb-root logical volume with lvextend.
Extend /dev/mapper/lapsdeb-root filesystem with resize2fs or relevant tool.
Mount /home.
Exit rescue mode and resume system start (ctrl+d).


Reply to: