Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
Go Back > Forums > Linux Forums > Linux - Server
User Name
Linux - Server This forum is for the discussion of Linux Software used in a server related context.


  Search this Thread
Old 11-16-2008, 08:28 AM   #1
LQ Newbie
Registered: May 2008
Posts: 6

Rep: Reputation: 0
Lightbulb Clone an entire server

Hello the linux community !

Today I have a challenge: move my "old" server to a newer one.

I have a Dell PE 850 for my personnal use running on Debian Lenny (ZoneMinder, Apache, Cacti, Nagios, SqueezeCenter, Transmission, DNS, Squid, Wins and domain, MySQL, Postfix and so on) but he is overloaded now....
(2 GB Ram and one P4 HT @ 3,6 GHz, 2 SATA HDD)

And now I have another machine: Dell PE SC1425 with 4 GB Ram and two Xeon HT @ 2,8 GHz with SCSI HDD and hardware RAID.

My idea is to move my current server to the new one without re-configuring and installing everything.

The old server has software RAID on two 250 Gb SATA HDD, formated with ReiserFS and the new server has hardware RAID on two 146 Gb SCSI HDD, I'll format it with XFS

As I have a NAS, the server has not a lot of data, I use about 20 Gb on HDD (and has only one partition)

I've found a solution here:

But before broking everything, I would ask you witch is the best and secure method to migrate my server ?

What would you use if you have to do this migration ?

Many thanks for your ideas and comments

(Sorry for my bad english)

Last edited by galphanet; 11-16-2008 at 08:47 AM.
Old 11-16-2008, 10:20 AM   #2
Senior Member
Registered: Jul 2004
Distribution: Ubuntu 7.04
Posts: 1,991

Rep: Reputation: 76
I'd probably use rsync rather than netcat and tar, that way if something broke part-way through I could pick up where I left off without having to start again. But you would need to have ssh (or an rsync dæmon) running on the destination machine for that to work.

Note that the instructions you have are talking about copying data (eg the /home partition); they pre-suppose that you have a working operating system. You could easily do this with a live CD, but make sure you format, mount and cd to the partitions first.

If the partitions are EXACTLY the same size, then you could also use dd to grab a bite-wise copy of the entire filesystem; this would take longer to copy but you wouldn't have to format the partition.

It's always a good idea to mount a filesystem as read-only before copying it. That way, you won't get a snapshot of a file that's changing as you copy it. You can do that with this command:
mount / -o remount,ro
If you aren't able to re-mount it read-only (eg for a live server) then it's worth running fsck on the new system to make sure that there aren't any errors.

If you're copying the entire filesystem tree, then make sure to skip /proc, /sys and possibly /dev; these are auto-mounted filesystems and not stored on disk, so you don't want to copy these. You can use the mount command, or look at /etc/mtab to see which filesystems are physically stored on disk.

Hope that helps,

—Robert J Lee
Old 11-16-2008, 10:37 AM   #3
LQ Newbie
Registered: May 2008
Posts: 6

Original Poster
Rep: Reputation: 0

Thanks for your reply.

So you think if I install debian Lenny on the new server with ssh and rsync, I can copy all the data and remplace all files ?
Would the software raid just stop working and let the hardware raid doing his job ?

As the material configuration changes, will it not made some problems on the devices names ? (like in /dev)


migration, raid, server

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Clone captive portal server 0.o Linux - General 0 10-13-2007 03:02 PM
Clone a LAMP server newbe45 Linux - Server 2 09-13-2007 10:29 PM
How can I copy an entire CD (from WinXP) to a dir on my Linux server? hmendoza Linux - General 2 04-04-2007 07:06 PM
Best Way To Clone A Running Server? hurt138 Linux - Software 8 01-05-2007 03:41 AM
ntp server serving my entire network rjerina Linux - General 1 11-15-2005 05:00 PM > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 03:22 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration