Robert Moskowitz
2008-Jul-04 01:11 UTC
[CentOS] Three Identical systems - short cut to setting up the drives?
I am building three identical systems. Well they will have different host names, and with time the software setups will drift. But at install time they are identical. Is there some way, (with dd I might guess) to do a hardare level copy? All three drives are Hitachi DK23DA-40F (40Gb). Supposedly factory reconditioned (they are in sealed bags with a drive sticker stating: "Refurbished to Hitachi Global Storage Technologies Specifications"). I would want to copy the paritition table and my 3 partitions (/boot, swap, LVM (/ and /home ext3 partitions in the LVM)) and all their contents. Thing is I only have one USB drive enclosure so I would be running from the drive I want to copy from. I would hope this is faster than 2 more installs.
Terry Polzin
2008-Jul-04 03:27 UTC
[CentOS] Three Identical systems - short cut to setting up the drives?
On Thursday July 3 2008, Robert Moskowitz wrote:> I am building three identical systems. Well they will have different > host names, and with time the software setups will drift. But at > install time they are identical. > > Is there some way, (with dd I might guess) to do a hardare level copy? > > All three drives are Hitachi DK23DA-40F (40Gb). Supposedly factory > reconditioned (they are in sealed bags with a drive sticker stating: > "Refurbished to Hitachi Global Storage Technologies Specifications"). > > I would want to copy the paritition table and my 3 partitions (/boot, > swap, LVM (/ and /home ext3 partitions in the LVM)) and all their contents. > > Thing is I only have one USB drive enclosure so I would be running from > the drive I want to copy from. > > I would hope this is faster than 2 more installs. > > > _______________________________________________ > CentOS mailing list > CentOS at centos.org > http://lists.centos.org/mailman/listinfo/centosKickstart the system 2 & 3 after the install on #1 -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 189 bytes Desc: This is a digitally signed message part. URL: <http://lists.centos.org/pipermail/centos/attachments/20080703/bcc70501/attachment-0002.sig>
Les Mikesell
2008-Jul-04 03:52 UTC
[CentOS] Three Identical systems - short cut to setting up the drives?
Robert Moskowitz wrote:> I am building three identical systems. Well they will have different > host names, and with time the software setups will drift. But at > install time they are identical. > > Is there some way, (with dd I might guess) to do a hardare level copy? > > All three drives are Hitachi DK23DA-40F (40Gb). Supposedly factory > reconditioned (they are in sealed bags with a drive sticker stating: > "Refurbished to Hitachi Global Storage Technologies Specifications"). > > I would want to copy the paritition table and my 3 partitions (/boot, > swap, LVM (/ and /home ext3 partitions in the LVM)) and all their contents. > > Thing is I only have one USB drive enclosure so I would be running from > the drive I want to copy from.Boot from the install CD with 'linux rescue' at the boot prompt so you can do the dd copy with none of the partitions mounted. -- Les Mikesell lesmikesell at gmail.com
William L. Maltby
2008-Jul-04 09:22 UTC
[CentOS] Three Identical systems - short cut to setting up the drives?
On Thu, 2008-07-03 at 21:11 -0400, Robert Moskowitz wrote:> <snip>> Is there some way, (with dd I might guess) to do a hardare level copy?I've seen many posts on this list that recommend Clonezilla for this sort of thing. You run off CD and it is said to be faster than DD because it is hardware aware (forgive the alliteration) and so only copies actual data. I've not had occassion to use it though.> <snip>> I would want to copy the paritition table and my 3 partitions (/boot, > swap, LVM (/ and /home ext3 partitions in the LVM)) and all their contents. > > Thing is I only have one USB drive enclosure so I would be running from > the drive I want to copy from. > > I would hope this is faster than 2 more installs. > <snip sig stuff>HTH -- Bill
Robert Moskowitz
2008-Jul-04 11:35 UTC
[CentOS] Three Identical systems - short cut to setting up thedrives?
Daniel_Curry at Dell.com wrote:> How about installing one, and using the anaconda-ks that is generated to > install the other two? >That was my first plan. But that just saves the time going through the install selection and getting the same stuff installed. I would still have to do the yum update (though there was the post about how to include the update repo in a kickstart install. Then I have the powerk8 kernel patch to install (these are old systems with new drives), followed by a number of config file changes (setting up IPtables, changing SSHD, configing VNC, etc). All that is a lot to work out for a kickstart install. The pointer of running dd fromLinux Rescue sounded good. But Clonezilla calls for some real investigation.> > -----Original Message----- > From: centos-bounces at centos.org [mailto:centos-bounces at centos.org] On > Behalf Of William L. Maltby > Sent: Friday, July 04, 2008 4:23 AM > To: CentOS mailing list > Subject: Re: [CentOS] Three Identical systems - short cut to setting up > thedrives? > > > On Thu, 2008-07-03 at 21:11 -0400, Robert Moskowitz wrote: > >> <snip> >> > > >> Is there some way, (with dd I might guess) to do a hardare level copy? >> > > I've seen many posts on this list that recommend Clonezilla for this > sort of thing. You run off CD and it is said to be faster than DD > because it is hardware aware (forgive the alliteration) and so only > copies actual data. > > I've not had occassion to use it though. > > >> <snip> >> > > >> I would want to copy the paritition table and my 3 partitions (/boot, >> swap, LVM (/ and /home ext3 partitions in the LVM)) and all their >> > contents. > >> Thing is I only have one USB drive enclosure so I would be running >> > from > >> the drive I want to copy from. >> >> I would hope this is faster than 2 more installs. >> <snip sig stuff> >> > > HTH >
Robert Moskowitz
2008-Jul-04 11:36 UTC
[CentOS] Three Identical systems - short cut to setting up the drives?
William L. Maltby wrote:> On Thu, 2008-07-03 at 21:11 -0400, Robert Moskowitz wrote: > >> <snip> >> > > >> Is there some way, (with dd I might guess) to do a hardare level copy? >> > > I've seen many posts on this list that recommend Clonezilla for this > sort of thing. You run off CD and it is said to be faster than DD > because it is hardware aware (forgive the alliteration) and so only > copies actual data. >Now this sounds of real interest. Off to google Clonezilla. Thanks.> I've not had occassion to use it though. > > >> <snip> >> > > >> I would want to copy the paritition table and my 3 partitions (/boot, >> swap, LVM (/ and /home ext3 partitions in the LVM)) and all their contents. >> >> Thing is I only have one USB drive enclosure so I would be running from >> the drive I want to copy from. >> >> I would hope this is faster than 2 more installs. >> <snip sig stuff> >> > > HTH >
Karanbir Singh
2008-Jul-04 12:30 UTC
[CentOS] Three Identical systems - short cut to setting up the drives?
Robert Moskowitz wrote:> I am building three identical systems. Well they will have different > host names, and with time the software setups will drift. But at install > time they are identical...snip...> I would hope this is faster than 2 more installs.its not do the install over the network from a http server, given the same network, it would be many times faster to do the 2nd and 3rd install using the ks.cfg generated from the 1st one ( as Terry Polzin already pointed out ). It will be many times faster than doing DD images of entire drives. eg. in my case here, i can provision a new machine in 2 min and 43 seconds for a base+core minimal centos-5 install. installing over http from a machine on a GiB/sec link and installing to a 2 disk raid-1 - KB
Robert Moskowitz
2008-Jul-04 13:32 UTC
[CentOS] Three Identical systems - short cut to setting up the drives?
Karanbir Singh wrote:> Robert Moskowitz wrote: >> I am building three identical systems. Well they will have different >> host names, and with time the software setups will drift. But at install >> time they are identical. > ..snip... >> I would hope this is faster than 2 more installs. > > its not > > do the install over the network from a http server, given the same > network, it would be many times faster to do the 2nd and 3rd install > using the ks.cfg generated from the 1st one ( as Terry Polzin already > pointed out ). > > It will be many times faster than doing DD images of entire drives. > eg. in my case here, i can provision a new machine in 2 min and 43 > seconds for a base+core minimal centos-5 install. installing over http > from a machine on a GiB/sec link and installing to a 2 disk raid-1There is much good to say about using kickstart method than learning a new approach like Clonezilla. I have not used kickstart since Centos 4.something, so I have no good notes and will have to dig again. But this is pretty much a one-time clone and Clonezilla does not seem to set up the partitioning info on the new drive so that would be one more thing to learn. So I take the anaconda-ks.cfg file, add stuff so it will boot off the network and use the update repo as well as the base. Then rediscover the command to run linux from a kickstart file on a diskette. Piece of CAKE! :)
Robert Moskowitz
2008-Jul-04 19:34 UTC
[CentOS] Three Identical systems - short cut to setting up the drives?
I am building the Clonezilla live CD now.... Les Mikesell wrote:> Robert Moskowitz wrote: >> >>> It will be many times faster than doing DD images of entire drives. >>> eg. in my case here, i can provision a new machine in 2 min and 43 >>> seconds for a base+core minimal centos-5 install. installing over >>> http from a machine on a GiB/sec link and installing to a 2 disk raid-1 > >> There is much good to say about using kickstart method than learning >> a new approach like Clonezilla. I have not used kickstart since >> Centos 4.something, so I have no good notes and will have to dig >> again. But this is pretty much a one-time clone and Clonezilla does >> not seem to set up the partitioning info on the new drive so that >> would be one more thing to learn. > > You are reading the wrong thing about clonezilla. In disk image mode > it will duplicate the partitioning for you and it knows enough about > most filesystems to just copy the used portions. There are options to > just take one partition if you want, but if you do the whole disk it > will set up the partitions for you. It understands LVM, but not > multi-disk software raid. I'd expect it to be faster than any other > way to duplicate systems if you don't count downloading the iso and > making your initial image copy from the master. > >> So I take the anaconda-ks.cfg file, add stuff so it will boot off the >> network and use the update repo as well as the base. Then rediscover >> the command to run linux from a kickstart file on a diskette. >> >> Piece of CAKE! > > Clonezilla can also be network-booted if you have enough machines to > be worth the trouble to set up (and it can clone windows and other > linux distributions as well). There is a companion project called DRBL > that handles network booting and provides NFS storage for the clients > to save and load images. >
Robert Moskowitz
2008-Jul-04 21:38 UTC
[CentOS] Three Identical systems - short cut to setting up the drives?
William L. Maltby wrote:> On Fri, 2008-07-04 at 11:41 -0500, Les Mikesell wrote: > >> <snip> >> > > >> Yes, dd is actually pretty slow in wall clock time. Where it wins is in >> human time since you just type a short command line and go away, and it >> duplicates any setup work you've done in addition too installing the >> packages. >> > > But it's not as slow as most think. They just don't take advantage of > capabilities, like bs=16384. This makes a *huge* difference in both > system overhead and wall clock time.Well Clonezilla is busy cloning the drive, but there is a problem here cloning to a USB attached drive. One of the partitions is LVM and since this is a drive clone, including the partition table and boot sector, both LVMs (source and target) have the same name. So Clonezilla switches to using DD with probably some bad parameters. After running an hour, it has only copied 4Gb out of 37Gb. Note that the USB port is v1.1. Now actually, I would have perfered renaming the LVM partition and its internal ext3 partitions. I even had a naming convention laid out if I had do this via Install instead.
Robert Moskowitz
2008-Jul-06 03:58 UTC
[CentOS] Three Identical systems - short cut to setting up the drives?
William L. Maltby wrote:> On Fri, 2008-07-04 at 17:38 -0400, Robert Moskowitz wrote: > >> <snip> >> > > >> Now actually, I would have perfered renaming the LVM partition and its >> internal ext3 partitions. I even had a naming convention laid out if I >> had do this via Install instead. >> > > If it's a boot drive, remember to rebuild your initrd and modify the > init file to ignore lvm lock failures with the new VG name. Otherwise > you'll be fighting some more battles. >ARGH!!!! Yes, I remember getting burned by this once. And I don't have any notes of what I did to do all this. :(> >> <snip sig stuff> >> > >