The officially official Devuan Forum!

You are not logged in.

#1 2022-08-29 10:10:16

amaro
Member
Registered: 2022-02-08
Posts: 97  

move Devuan to a bigger partition

Hello everybody!

Several months ago I wanted to test Devuan and installed it on a small partition (sda4).
I liked and want to keep it but the partition is full.
So now I want to move Devuan to a bigger partiton (sda3).
I have already installed it on the bigger partition.
In order to skip all the manual adjustments would it be enough to copy (rsync) /etc, /usr, /home directories?
If that is not enough what else needs to be done?
Thank you in advance!

p.s. Regarding the packages since I don't have copies of all of them in /var/cache/apt/archives/
I guess I will have to manually install them, right?

Last edited by amaro (2022-08-29 10:11:19)

Offline

#2 2022-08-29 11:16:58

Head_on_a_Stick
Member
From: London
Registered: 2019-03-24
Posts: 3,125  
Website

Re: move Devuan to a bigger partition

Can you not just backup the system (with rsync), blow away sda4, make sda3 bigger then copy the system back? It would need some adjustment to the bootloader & /etc/fstab but you wouldn't be left with a useless extra partition.

EDIT: or just copy sda4 to sda3 then delete sda4 and expand sda3 if you don't have a backup medium. But you really should have a backup anyway.

Last edited by Head_on_a_Stick (2022-08-29 11:20:10)


Brianna Ghey — Rest In Power

Offline

#3 2022-08-29 12:29:18

amaro
Member
Registered: 2022-02-08
Posts: 97  

Re: move Devuan to a bigger partition

Head_on_a_Stick wrote:

or just copy sda4 to sda3 then delete sda4 and expand sda3 if you don't have a backup medium. But you really should have a backup anyway.

thank you, hoas!
that was my idea, though, I was not sure which directories can be skipped.
btw, skipping some of the directories is just to save some time because the current installation is 8,5GB.

Offline

#4 2022-08-29 12:59:11

Head_on_a_Stick
Member
From: London
Registered: 2019-03-24
Posts: 3,125  
Website

Re: move Devuan to a bigger partition

amaro wrote:

I was not sure which directories can be skipped

I follow https://wiki.archlinux.org/title/Rsync# … tem_backup — that has a list of system directories which should be excluded (mostly the API filesystems). You would have to add your own exceptions for any other large files you don't want transferred.

/etc/fstab & GRUB for the new system can be configured with these commands run from sda4:

# apt install arch-install-scripts
# mount /dev/sda3 /mnt
# genfstab -U /mnt > /mnt/etc/fstab
# arch-chroot /mnt
[chroot]# dpkg-reconfigure grub-pc
[chroot]# grub-mkconfig -o /boot/grub/grub.cfg
[chroot]# exit
# umount /mnt
# apt purge arch-install-scripts # or keep it :-)

^ That presumes a non-UEFI system with only a single root (/) partition.

Last edited by Head_on_a_Stick (2022-08-29 13:01:28)


Brianna Ghey — Rest In Power

Offline

#5 2022-08-29 14:03:55

delgado
Member
Registered: 2022-07-14
Posts: 213  

Re: move Devuan to a bigger partition

Hi,
depending on the partition sizes, it could be an option to mount sda3 on "/home". Minimal effort and recommended anyway.

Offline

#6 2022-08-30 03:44:56

GlennW
Member
From: Brisbane, Australia
Registered: 2019-07-18
Posts: 648  

Re: move Devuan to a bigger partition

For the /home directory, I would use rsync -avh to copy files back to the new home.

But the system dir is another thing.  when you format or change a drive size it will get a new UUID, you'll need that for fstab and possibly grub.

blkid  and lsblk helps.

Last edited by GlennW (2022-08-30 03:50:09)


pic from 1993, new guitar day.

Offline

Board footer