Posts
23
Comments
229
Trackbacks
0
October 2006 Blog Posts
Cloning with Different Mass Storage Controllers

 

OK, so you have a bunch of servers and they are all similar. Say for instance, you have 10 HP Proliant DL360's. They are a mix of first generation through the latest generation (currently G5.) You install Windows Server 2003 on one server along with whatever apps you want. Then you image the server with your favorite imaging program, saving the image to a network share. Next you push your image to another server. Upon bootup you plan to run something like newsid to rename the server and give it a new sid. However, upon initial bootup of your new clone you get a blue screen. "What is this?" you may ask yourself. "I haven't seen one of these BSOD's since I installed those bad drivers last year on my file server" you might comment to yourself. Or maybe you'll exclaim "But they are both HP Proliant DL360's, this should have worked!!!"

Well stop talking to yourself and start reading. The problem you are facing is called "Controller Driver Required On Mount" or CDROM. OK, I just made that up, but it's true. You see, your clone OS is expecting to boot up to one type of controller, but sees that it is booting up to another. It then blue screens because it can't load the driver. Well actually, mass storage drivers aren't plug and play anyway so there is no way for it to find your driver so the boot process just croaks. So lessoned learned. You can't make one image for all your servers. You need to make one image for each type of controller driver. Right? Wrong. There is a way to do this. I've done it, and I'm going to pass my knowledge on to you.

I'm going to use HP servers in my examples, but the idea is the same for Dell's, IBM's, or any other server hardware. In fact, you can probably make an image on an HP server and push it to a Dell or IBM server using the method I'm going to explain. So folks, we are talking about image freedom here. And when I say folks, I mean geeks.
My experience was that I needed 11 Citrix Presentation 4.0 servers. I didn't want to install them all manually. The odds of missing something that should have been installed, installing a different version of something, or misconfiguring something simply increases with each manual install. So the idea is to only need to install things one time, then create and image of that installation to push to any other servers you might have. Having an image is also great for disaster recovery. Imagine losing your servers to a fire, or even losing just one server to a hardware failure. What a pain! However with an image you can setup a replacement server within an hour of opening the box that your replacement server came in. Sweet deal.

So, what I did was this: After getting Citrix installed and installing all the programs needed I downloaded the latest sysprep tool. Go to the sysprep page and download the latest tool. The link is for XP but it's all the same. Unzip the tools into a folder, name it sysprep, on the root of C:\. Inside the folder is a tool called setupmgr.exe. You will use that tool to create a sysprep.inf file, which will by default save in the sysprep folder. Sysprep.inf is an answer file. It answers the installation prompts. So, you know how when you install Windows manually you need to put in information like the product key and the administrator's password and whether you want to join a domain or a workgroup? Well setupmgr.exe asks you all these questions and saves the answers in an answer file, called sysprep.inf.

Before you do anything else. If you have mirrored drives like I do, shut down your computer and pull one out. That way, once you are done with sysprep you won't need to run setup on your master machine (the one you are taking the sysprep image of.) Once you take the image you turn off the machine, then pull out the drive that was in the computer during sysprep, and put back in the drive that you just took out. You boot back up and it's like you never changed anything. It saves you some time. Otherwise you'll need to run the mini install (more on that later) on your master machine, as if it was a clone. So, shut down, pull a drive, boot up, fail over to the drive that is still in your server, then come back to this page.


OK, are you back? Let's do this.


So, run setupmgr.exe and do the following:


1: Create a new answer file and click next.



2. Select Sysprep Setup and click next.



3. Choose your edition of Windows you are running sysprep on.
4. Select a fully automated installation.
5. Now you are in the final phase. Enter your name and Organization.
6. Choose display settings that are pretty generic. This will eliminate any possible problems.16 bit at 800 x 600 @ 60 Hz.
7. Choose your timezone.
8. Enter your legal product key that you have on your package that you bought at the store. ;-)
9. Automatically generate a computer name. You're going to change it anyway.
10. Enter the admin password. This will be the local password, not the domain password. ENCRYPT IT!!!! No need for auto login but you can if you want. Whatever.
11. Set your network card to DHCP. This is kind of important. You don't want the same IP as the master server.
12. Join a workgroup.
13. Make sure to set your area code and stuff.
14. The default regional settings are fine.
15. No need for language stuff unless, of course, you need it.
16. That's usually it for me. I just click Next, Next, Next Finish. It will ask you where to save, just click OK.
17. Setupmgr.exe is kind of broken. I've noticed that after clicking finish it just sits there. You either need to click Cancel or X out. It's fine though.
Now you should have a nice sysprep.inf file. Go ahead and open it up, because we're not done with it. It should look something like this:


OK, so you can see that there are sections to the file. Something like [UserData] is a section header. You can add some things to the different sections. But what we are going to do is cooler. We are going to add a whole new section. Yeah folks, I'm excited, are you?
So, below the [Networking] section make a new header called [Sysprep]. Inside that section add the following:

BuildMassStorageSection=yes

Next, make another section header called [SysprepMassStorage]


So here's an image of my new sysprep.inf file:



Next you need to close the sysprep.inf file and then run sysprep.exe. Just double-click on it, click OK to the warning, then finish. It's going to take awhile. I like to not reboot when it's done. I suggest you do the same, that way we can look at our new sysprep.inf file. Go ahead and open the sysprep.inf file again and check it out. You'll see that all sorts of stuff has been added to the [SysprepMassStorage] section. Those entries are controller device identifiers along and the location where windows can find the drivers. In my next article I'll show you how to make your own custom [SysprepMassStorage] section and not even need the [Sysprep] section. You'll learn a lot about how drivers work. For instance, did you know that every company that makes mass storage devices has it's own unique code? HP/Compaq is 0E11. You'll notice when looking at the HP drivers that they all say Compaq in them. Just kind of a neat side note for you folks. And you know what I mean when I say folks.


OK, for the final step. It's time to reboot to your image program. I use Acronis at work, so I boot to our Acronis disk and image the server, placing the image on a network share.


Once done imaging I shut down the server, take out the drive that's just been syspreped, and put in the drive that I took out before sysprep was run.


I use Acronis to apply the image to my other servers. What happens is the image gets applied to the clone after which I boot up the clone and a mini-setup runs automatically. All the answers from the sysprep.inf file get applied. I then log into the new clone and rename it and join it to the domain. No need for changing the sid because it gets a new sid via the mini-setup.


Imaging across our gigbit network is quite fast. It usually takes ten minutes. Now with Citrix Presentation Server 4.0 there are a few things that need to be changed after joining the clone to the domain and rebooting. That's another article though.


What's that you say? You don't have an imaging program? Well why didn't you say so? I'll write an article on how to do this using a wonderful technology called RIS. If you have Windows Server, then you have RIS.


That's it for now. I hope this article helped. Let me know if you have questions. I'll do my best to help.


-Patrick Durling

posted @ Wednesday, October 11, 2006 10:00 PM | Feedback (53)
Window Live Writer

I just installed Windows Live Writer. Now I can create my Blogs locally and then upload them. Kind of nice. Let's see how this looks.

posted @ Wednesday, October 11, 2006 9:58 PM | Feedback (3)
Soccer
Well, my second daughter is in soccer. My first daughter likes to go and play at the park during practice. So my wife takes our two girls on Monday and Wednesday and I stay at home with my son, who is almost two years old.

Tonight I'm going to start on an article about syspreping a server to create an image capable of being successfully installed on servers with different mass storage controllers. My son is just going to play.

I'm really hungry. I joined weight watchers and I lost five pounds the first week. Even though I had $60 in sushi and $12 in cheap mexican food (including a super burrito with sour cream and guacamole.) Adelberto's is my favorite mexican place, and Wasabi is my favorite sushi place. I figure if I had all that food and lost weight, then this week I'll stick to my diet and lose even more. I really want to hold that 10 pound rock. Yeah, they let you hold a 10 pound rock after losing your first 10 pounds so that you can feel how much you've lost. I've done it once before and it's amazing. I wonder if the rock weighs more than 10 pounds.

Lost is on tonight. I've saved up enough points for a Chocolate Blast from Baskin Robbins. Gonna do the Lost/Blast thing every Wednesday. And still lose weight.

OK, my boy is getting into my CD's. Gotta run.
posted @ Wednesday, October 11, 2006 3:56 PM | Feedback (3)
Installed!

Well, it took some trial and error, but I finally got subtext installed! I learned a lot about how IIS 6 works in the process which made the trouble worth wading through.

My goal for this site is to share my most useful experiences in IT. "Useful" in this context is those experiences that others can benefit from, without having to make the same mistakes I made. After all, isn't that one of the great purposes of the web? To share our knowledge?

My first technical article will be about how I got subtext installed. Thanks to Stuart Verweij for suggesting that I reinstall DOTNET2.0. Although that wasn't the fix, your suggestion helped point me in the right direction.

Also, thanks to haacked for all your help, and for this great blog server.

I almost forgot to introduce myself. My name is Patrick Durling. I am a sysadmin at a medium sized nonprofit organization in Sacramento California. I am an MCSA Messaging specialist as well as an MCSE 2000. I'm currently working on my CCA (Citrix Certified Administrator) and when I'm done I will upgrade my MCSE certification to 2003. I've been working in the field full time for over five years now.

The first computer I ever personally owned was a 66 MHz Pentium on which I installed Caldera Linux. That was back in 1998. I love computers and am not partial to any OS platform. I grew up using my dad's Mac SE, which I now have in my closet. I then used Linux for a bit before deciding to get my Microsoft certification so I could go for a job in our MIS department. Well, I got the job, and I haven't looked back.

Well, check back here at least once a week and see what's cooking!

posted @ Tuesday, October 10, 2006 7:46 PM | Feedback (3)