Client initiated Imaging with Deployment Solution
Hi,
I'm looking into a way of getting clients re-imaged from menu systems accessible in automation. The idea is that existing clients can re-imaged from a selection of abstracted jobs (or folders) in-situ without resorting to a console log-in to schedule the jobs.
I've spent a few hours playing with some scripts, and am happy that this can be sensibly done, but before I spend the days required to make them 'production ready' I thought I should ask the obvious question has this already been done?
Using the Initial Deploy feature has a few of disadvantages,
- Critical: For existing machines, Initial Deploy forces in the automation agents to register themselves as new clients. This means the computers are moved out of their computer group hierachy into the root.
- Critical: Sometimes there can be a 'stuck' job scheduled which needs to be executed to be cleared automatically. The initial deployment job will not execute until the stuck one has, which can be a problem if the production system is buggered.
- Pain: Jobs are given their 'real' names (can be rectified with job shortcuts however).
- Pain: I cannot see a way of deploying folders of jobs without linking (which is messy)
So, I've been thinking about scripts based on a mix of initial deployment philosophy with the ideas presented in AKB 18830 Proof of concept: How to allow end user to start Deployment Solution jobs (self-help mechanism)
Does anyone else out there do anything similar?
Kind Regards,
Ian./
Comments
I will be curious about the
I will be curious about the responses as well. This is something we've thought about and even tried. We've also wanted to setup a separate partition and keep an image on that partition but then we realized we have too many script jobs after the fact so that wasn't an option either. So.....I'm going to watch if there are any responses here.
I wouldn't be opposed to
I wouldn't be opposed to it.. Sort of like a software portal but for images.
www.thesystemsengineer.com
PXE boot option
I have done this with a DOS boot. We do use Initial deploy but not for this. What I did was I made a menu option on the specified PXE server and edited the mapdrv.bat file and forced it to boot to menu option (had to add a choice.com to the image to allow for the menu). We use ghost for this so if you just wanted it to boot to ghost you just need the command line for the imaging. To edit the mapdrv.bat file you have to tell the pxe manager to edit the PXE (get to step 9 of 12) and then in Windows Explorer go to ...Deployment Server\Bootwiz\cfg-tmp\MenuOption1xx\shared and edit the file there as the PXE Editor will not let you modify that file. I am not sure if this will work as a shared configuration but we wanted different drive mappings per site so we created the PXE images locally for each PXE server and set them to Network instead of Automation PXEs (the network PXEs can only be created as local PXE servers). If you need more info on how to do this let me know and I will try to make some more specific directions. You can do the same thing for WinPE, and it is the same file. If you want to do this in linux you will need to add it to the mounts.local file and know the commands for linux, although it shouldn't be very difficult even for a non-linux person.
Hi Spazzen, I'm now working
Hi Spazzen,
I'm now working something similar to the above, but my menu system is designed to call DS jobs, rather than images. We can't use a simple rdeploy call, as our HII process requires lots of tasks in addition to the imaging to produce a bootable system. On top of that we also have a post-deployment software installs like the Altiris Agent, Antivirus etc....
But, for anyone reading this who only needs images to be called (not DS jobs) then give spazzen a prod!!
So, progress at my end so far... Got a prototype system up and runnning...
Client Automation
Server
ToDo
There is still a ways to go.
Display Text, Menu Index, Job Folder Name, Job Name
Currently if the jobname is ALL, then all jobs in that folder are scheduled. The parsing program splits these options into an array (delimeted by the commas). I think regex is perhaps a better way to go.
The current prototype script has been active for a few days now and seems stable. Will fire back an update onces i've ironed out the outstanding regex and SQL work.
Kind Regards,
Ian./
Ian Atkin, Senior Developer for the ICT Support Team, Oxford University, UK
Connect Etiquette: "Mark as Solution" those posts which resolve your problem, and give a thumbs up to useful comments, articles and downloads&
Post Solution
When you get this working, I would be very instrested in how you got this working. This is something I would love to be able to implement in our enviourment, but I don't know Linux well enough much less how to use the SQL to schedule the jobs.
Progress Report
This is just to let you know where I'm at.
SQL
I've now finished the SQL side of the house. Now any existing scheduled jobs will be cleared from the client prior scheduling a job (or folder of jobs) from the imaging menu.
Logging
I've increased the logging, and moved the ini files to good and bad subfolders once they've been processed.
Initial Deployment
I've also resolved an issue which popped up today with computers which aren't in the database. Menu driven ini files referring to computers not currently in the database will no longer be instantly moved to the bad folder. Instead they will modified with an iteration number. Only when a such 'initial deployment' type files have been through the grinder 60 times will they be moved into a bad folder.
Whats left
This leaves to do some work with regular expressions, and perhaps packaging up the code properly. I can only spend a little time each day on it, but with luck I should have something in the connect downloads this time next week.
Kind Regards,
Ian./
Ian Atkin, Senior Developer for the ICT Support Team, Oxford University, UK
Connect Etiquette: "Mark as Solution" those posts which resolve your problem, and give a thumbs up to useful comments, articles and downloads&
This is turning out to be a
This is turning out to be a blog, so apologies for that.
The last couple of days i've spent creating a little client-server exchange in the menu interface to allow a verification of scheduling for imaging computers not already in the database. As all this has to be done before the agent is loaded, I've had to create some simple comms which allow the client computer to tell the server the destined computer name, MAC Address, SMBIOS UUID and Serial Number.
This has been a little complicated, but it removes the initial deployment problem where computers not in the database have to wait until the agent is loaded in order to get there. Now the client-server exchange built into the menu takes care of that transparently with instant feedback.
I'm going to leave the regex string matching for a later version.
I need to now add some error feedback from the server into client menu, so that if there are problems scheduling the jobs the client gets notified. This should be simple, as I can piggy-back in the client-server exchange I've just implemented.
After that, it time for the laborious Windows and Linux code tidy-up.
Here's some screenshots of where its at. First, here's the screen of the menu a new computer sees after activating the imaging menu after booting into Linux automation,
This 'job' selected above, actually refers to a folder of jobs in the console. Once this is selected, the menu program checks with the server to see if the computer already exists. If not, the following screen is presented,
And here i've set the computer name to be test2. Now the menu program contacts the server with the computers identity data and the jobs it was scheduled,
After a couple of seconds, the following screen appears if all the data recieved by the server is sane and the job has been scheduled,
At this point the menu program exists, and the Altiris Agent loads. When the agent contacts the server, it sees a computer object with a bunch of preloaded jobs so off it goes,
And all this without touching the console. The improvement over initial deploy is the setting of the computer names on the fly and a menu selection which allows folders of jobs to be scheduled.
For machines already in the database, they can now be re-imaged without using the initial deploy force switch which pushes the computer out of your nice groups hierahy into the root (as if it were a new computer).
Ian Atkin, Senior Developer for the ICT Support Team, Oxford University, UK
Connect Etiquette: "Mark as Solution" those posts which resolve your problem, and give a thumbs up to useful comments, articles and downloads&
All done
After making a few more improvements, I put this into production onto one of our subnets today, so can now sit back and relax. ;-)
I'll start writing the juice download for this next week, but will hold off posting it until I am sure the IT dudes have worked it through its paces enough to be sure its stable.
Kind Regards,
Ian./
Ian Atkin, Senior Developer for the ICT Support Team, Oxford University, UK
Connect Etiquette: "Mark as Solution" those posts which resolve your problem, and give a thumbs up to useful comments, articles and downloads&
Would you like to reply?
Login or Register to post your comment.