[Gllug] migrating install to larger hd

Tethys tet at createservices.com
Wed Jun 2 11:10:56 UTC 2004


Richard Jones writes:

>OK, well don't know much about LVM partitions

You don't need to. They're just the same as a physical partition -- i.e.,
just a block device on which you can stick a filesystem. The difference
is just that they happen to be resizable.

>but it is also perfectly possible to do:
>
>tar cflp - / | tar xflp - /mnt/newdisk

Yep, do that once per filesystem:

	for fs in / /usr /var /usr/local
	do
		mkdir -p "/mnt/newdisk$fs" 2>/dev/null
		cd "$fs" && tar cvlpf - . | (cd "/mnt/newdisk$fs" && tar xlpf -)
	done

For all those suggesting dd for copying the filesystems over -- why?
Using tar lets you maintain all the data, while retaining the ability
to increase the filesystem size at the same time (which after all is
usually the reason for moving data to a new disk in the first place).

Tet
-- 
Gllug mailing list  -  Gllug at gllug.org.uk
http://lists.gllug.org.uk/mailman/listinfo/gllug




More information about the GLLUG mailing list