#Moving my system from one disk to another

69 messages · Page 1 of 1 (latest)

gloomy ledge
#

Hello, I want to upgrade my disk with more storage, how should I do that? I already have a bootable usb with gparted which I used for resizing my partitions some time ago

compact sandal
#

then use ext4 stuff to resize the newroot to use the whole partition

cloud silo
#

dd is slow because it copies everything, including the empty space

#

I usually create the new partitions and then rsync (with the right flags) and update the fstab, install the bootloader

gloomy ledge
# compact sandal dd -if=oldroot -of=newroot

That was my first idea, but it doesn't show up in the boot screen for some reason (maybe could because the other drive is still in, but I cant take it out because I can't find something to screw it out since yesterday)

cloud silo
gloomy ledge
#

The whole drive

cloud silo
#

The new drive is identical

#

So there's no way to differentiate them

#

other than the model

#

The efi entry points to a GUUID

gloomy ledge
#

Old one is nvme, new one is ssd

cloud silo
#

grub?

gloomy ledge
#

Btw, i just noticed something weird

#

I ran blkid

cloud silo
#

If you boot either system they're going to be confused

#

because you have identical UUIDs

gloomy ledge
#

And UUIDs are different

#

But PARTUUIDs are the same

#

Nvme is the old drive

#

Sda the new one

#

And sdb is the bootable usb

cloud silo
#

UUID is in the filesystem, PARTUUID is in the GPT

cloud silo
gloomy ledge
#

I tried booting

#

It mounted root and /boot on nvme, but /home and /mnt/shared (another partition with windows filesystem) on ssd

cloud silo
#

p1 is vfat and sda1 is ext4 but they have the same PARTUUID

#

So you formatted either the p1 or the sda1

gloomy ledge
cloud silo
#

You need to either change the fstab to mount with by-id or detach the sda

#

/dev/disk/by-id

#

Also your bootloader may boot either of them because they're identical

#

You can change the UUID of ext4 partitions

#

tune2fs -U random /dev/sdXX

gloomy ledge
#

I'll just try booting the ssd on my dad's pc, see if that works rn

cloud silo
#

?

#

If your bootloaders efi file isn't in the fallback location then you can't boot it from a another pc

#

If grub then you need --removable

#

Otherwise there's a entry in the nvram

gloomy ledge
#

Because I can't take out the nvme disk because I can't finda small enough screwdriver

cloud silo
#

I missed that the nvme was the old one

#

because usually nvme is the new one

#

Yeah so you did something wrong because sda1 is now ext4

#

p1 was vfat

gloomy ledge
#

Yeah, that's true, but I am just using what I have around, and I found a larger ssd than my nvme

cloud silo
#

But you could have just mounted it

gloomy ledge
cloud silo
#

/boot can be ext4 but the esp must be fat32

#

and it's often mounted at /boot or /boot/efi

gloomy ledge
#

How should I fix this?

gloomy ledge
#

It booted from sda

#

But for some reason decided to mount root on nvme

cloud silo
#

For both of the ext4 on the nvme

#

And the vfat

#
tune2fs -U random /dev/sdXX # ext4
mlabel -i /dev/sdXX -N 12345678 # fat32
gloomy ledge
#

(I'm dual booting and before I had linux on 500gb nvme and windows on 120gb ssd, now im planning to have linux on 1tb ssd and windows on 500gb nvme)

cloud silo
gloomy ledge
#

I think I'll keep it in mind if I'll need to do it, but now i want to reorganize my partitions on the new ssd

cloud silo
#

....

#

So remember you're diverging the state

gloomy ledge
#

I'm mainly working from a bootable usb here