LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 02-19-2013, 12:29 AM   #1
studyete
Member
 
Registered: Feb 2013
Posts: 40

Rep: Reputation: Disabled
How to clone live server


Halo, I would like to know is their any way to clone a running serve over network or physically connecting to server? I can not stop my server, what i need is to clone my server hdd and replace newly imaged hdd when the old hdd crashes. I search many ways like clone zilla or acronis but almost all solution include stop the server.
 
Old 02-19-2013, 12:42 AM   #2
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.2
Posts: 18,359

Rep: Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751
mondorescue http://www.mondorescue.org/ is one. I believe there are others.

Note that if an RDBMS is involved, its best to use the hot backup tool that comes with it.
File or even byte level copying is not guaranteed to maintain integrity for eg in-flight txns.

If a system is really busy, you'd have to already have it setup for RAID and/or clustering.
Copying an open file is always a risk & and any copy procedure will take some time, so files can get out of sync ...
 
Old 02-19-2013, 02:24 AM   #3
sharadchhetri
Member
 
Registered: Aug 2008
Location: INDIA
Distribution: Redhat,Debian,Suse,Windows
Posts: 179

Rep: Reputation: 23
Quote:
Originally Posted by chrism01 View Post
mondorescue http://www.mondorescue.org/ is one. I believe there are others.

Note that if an RDBMS is involved, its best to use the hot backup tool that comes with it.
File or even byte level copying is not guaranteed to maintain integrity for eg in-flight txns.

If a system is really busy, you'd have to already have it setup for RAID and/or clustering.
Copying an open file is always a risk & and any copy procedure will take some time, so files can get out of sync ...
Either you can go for basic method as well.

(1) Take the system backup ( / ) with the help of any backup tool . For eg. Bacula or anything which you can have.
(2) Install the same OS in new system. Do the same kind of partition and partition size in new system
(3) Restore the system in new one (except users and group related files)
(4) At the end . in new system migrate users and group.

Note: The system should not have any changes in between of this procedure.

Here you have to check yourself what logics you can use.

rsync can help you in migrate many data if they are in different partition.

I already done about 10 migration few months back by this method where I had RedHat 4 and Redhat 5 running.


Other than this basic method explore some tool.
 
Old 02-19-2013, 02:59 AM   #4
studyete
Member
 
Registered: Feb 2013
Posts: 40

Original Poster
Rep: Reputation: Disabled
I have explore acronis so far. But fail to install it on centos. I found on windows os that acronis can take image of two hdd during running but as i was not able to install it on centos, i did not able to test it. Do you use any tool so far? I did not found any package for centos here http://www.mondorescue.org/
 
Old 02-19-2013, 03:40 AM   #5
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,128

Rep: Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120
As Chris said, the biggest problem is getting a consistent "point-in-time" copy.
Copying just the disk(s) is pointless if you have data in RAM buffers. Like for example any journalled filesystem or much more concerning any database system known to man.

For backups I use snapshot - but I make sure any data I care about is "hardened" to disk before I start. Once you have a snap you can back it up at your leisure.
 
Old 02-19-2013, 10:15 AM   #6
studyete
Member
 
Registered: Feb 2013
Posts: 40

Original Poster
Rep: Reputation: Disabled
well, can any one share the entire backup process of centos which you have successfully have done?
 
Old 02-19-2013, 10:47 AM   #7
studyete
Member
 
Registered: Feb 2013
Posts: 40

Original Poster
Rep: Reputation: Disabled
another thing, which package of mondo should i try for centos. i did not find any package for centos there. any suggestion?
 
Old 02-19-2013, 11:06 AM   #8
sharadchhetri
Member
 
Registered: Aug 2008
Location: INDIA
Distribution: Redhat,Debian,Suse,Windows
Posts: 179

Rep: Reputation: 23
What are the services are running in this Server ?
 
Old 02-19-2013, 09:31 PM   #9
studyete
Member
 
Registered: Feb 2013
Posts: 40

Original Poster
Rep: Reputation: Disabled
Mostly mail server and web server.
 
Old 02-19-2013, 09:55 PM   #10
studyete
Member
 
Registered: Feb 2013
Posts: 40

Original Poster
Rep: Reputation: Disabled
@chrism01,

Can you tell me which package i can use from mondo for centos
 
Old 02-19-2013, 10:37 PM   #11
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.2
Posts: 18,359

Rep: Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751
Go to this page http://www.mondorescue.org/downloads.shtml. As it says, for Centos use RHEL (Centos is a free rebuild of Centos)
Grab the 6 rpms listed
Quote:
afio: the packaging tool used to create the archive packets
gzip: the most standard compressor used by Mondo Rescue
mkisofs: the tool to create ISO images
mindi-busybox: the swiss army knife busybox configured for mindi: a full set of commands in a single binary (embedded)
mindi: the mini-distro builder part of the project
mondo: the disaster recovery tool itself
from the relevant download dir eg Centos6 64 bit ftp://ftp.mondorescue.org/rhel/6/x86_64/. Ensure you get the latest rpm file for each (not src.rpm)
iirc the last time I did this, those 6 were sufficient.

Now read docs eg http://www.mondorescue.org/docs.shtml & http://www.mondorescue.org/docs/mondorescue-howto.html.
Nice write up http://www.dedoimedo.com/computers/mondo.html
 
Old 02-19-2013, 10:55 PM   #12
sharadchhetri
Member
 
Registered: Aug 2008
Location: INDIA
Distribution: Redhat,Debian,Suse,Windows
Posts: 179

Rep: Reputation: 23
In mail server, is it POP or IMAP. Or both
 
Old 02-19-2013, 11:30 PM   #13
studyete
Member
 
Registered: Feb 2013
Posts: 40

Original Poster
Rep: Reputation: Disabled
Thanks all for your participation.

sharadchhetri@pop and imap both running on the server.

chrism01@ I'm not getting this packages on download pages. can you help me some more.

gzip: the most standard compressor used by Mondo Rescue
mkisofs: the tool to create ISO images
mondo: the disaster recovery tool itself
 
Old 02-19-2013, 11:44 PM   #14
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.2
Posts: 18,359

Rep: Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751
gzip is part of the std Linux install
mkisofs should be available from your repos
Code:
yum provides mkisofs
mondo is in the 'relevant download dir eg Centos6 64 bit ftp://ftp.mondorescue.org/rhel/6/x86_64/.'
 
Old 02-24-2013, 02:57 AM   #15
studyete
Member
 
Registered: Feb 2013
Posts: 40

Original Poster
Rep: Reputation: Disabled
thanks chrism01 for your response. I tried many ways to install mondo. But unable to get it on my linux 5.8 mail server. I have another web server and i failed to run mondo there too. Main problem is when i open afio and other six file to install by rpm, it give me dependency error and those package dose not get install.

Actually my requirement was i have to clone those server's hdd from running situation and connect the cloned hdd if running hdd crashes.
 
  


Reply



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
can you Create a live cd clone of installed system? OriginalCrazyone Linux - Newbie 2 11-15-2012 07:46 PM
LXer: How to clone a PC on the network with 2 live cd LXer Syndicated Linux News 0 11-27-2011 09:30 PM
How to clone a user account from one server to other server ZAMO Linux - Enterprise 5 03-19-2010 01:40 AM
I need to Clone a Red Hat drive and install clone in HP server drummer54 Linux - Newbie 14 03-07-2009 04:15 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 07:17 AM.

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