[wplug] Cloning a machine

Chris Romano romano.chris at gmail.com
Thu Sep 1 11:13:07 EDT 2005


On 9/1/05, Michael Skowvron <michaels at penguincentral.org> wrote:
> 
> Chris Romano wrote:
> > Say that I want to use Knoppix and use the network, what is the best way
> > to copy the data over? I have never did anything like this before.
> > Would I have to partition the disk and format it first with Knoppix?
> 
> Correct.
> 
> 1. Bring the system up on Knoppix and partition the system disk to
> match the source system.
> 
> 2. Make filesystems and mount the partitions. I usually use something
> like /d2, so I end up with:
> / is /d2
> /var is /d2/var
> /home is /d2/home
> 
> etc...
> 
> 3. Ensure that networking is up. If I recall, you'll configure this
> during the Knoppix boot.
> 
> 4. Move your data across using ssh
> 
> target # cd /d2
> target # ssh root at source "cd / ; tar cBlf - ." | tar xBf -
> target # cd /d2/var
> target # ssh root at source "cd /var ; tar cBlf - ." | tar xBf -
> 
> -B is required to block the data correctly across the net
> -l prevents tar from crossing into another mount point
> 
> 5. After populating the system drive, configure the boot loader, by
> chroot-ing into the root filesystem and running the appropriate
> command
> 
> target # chroot /d2
> target # lilo
> tarxet # exit
> 
> 6. Reboot!
> 
> Some folks might be concerned about copying a live filesystem and it's
> true that there is a small chance for a file to change during the
> copy. Most likely, it's just going to be a log file and will not be an
> issue.
> 
> I always use xfsdump to move my data because, by design, it is safe
> for dumping live filesystems. If you're using xfs filesystems, I
> highly recommend xfsdump/xfsrestore over tar.



I am using reiserfs. My partitions are very simple for these machines. I 
just have a swap and "/" partition. I normally break out "home" and "var", 
but these are only going to be proxy servers and nothing else .. well they 
will have some firewall rules and they will NAT so I guess they are just 
proxies.

I will give those a try.

Thanks,
Chris
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.wplug.org/pipermail/wplug/attachments/20050901/1b87e895/attachment.html


More information about the wplug mailing list