copying a lfs installation

Craig Howard craig.howard at
Tue Nov 20 22:11:38 PST 2001

Jan Patorra wrote:

> hi there,
> what steps are necessary to duplicate a whole lfs installation to another
> partition, say for testing new applications and keep the base system clean ?
> i'm aware that there are some issues in repect to root-devices and where the
> kernel expects to find this...
> bye,
> jan.

Just copying the partition should do it.  When I copy a partition, I tar 
the files and pipe to an untar.  Something along the lines of

PATH_TO_NEW_ROOT# tar cl --preserve $PATH_TO_OLD_ROOT | tar xv --preserve

The cl is for create, one file system.  ie, don't copy proc, devfs...
The xv is for extract verbose, you can ditch the v is you have faith 
(I'm a little nervous doing important copies like this)
The --preserve is to keep as much of the permission and date info as 

Note: adding the z option to compress the data will slow you down, as 
you are no longer just block copying though the bus, but you're 
involving your CPU to do the compression, decompression.

I didn't test this while writing it, so do some careful checks before 
you trust my method completely.  I'd recommend running a diff of your 
old and new roots.  This has worked for me modulo memory and typos.

Craig Howard
craig.howard at

Unsubscribe: send email to listar at
and put 'unsubscribe lfs-support' in the subject header of the message

More information about the lfs-support mailing list