UPDATE - How to manually use a BDD Task Sequence to test application installation
In a previous post I detailed the process for using a cut down version of the task sequence to test application installation, unfortunately this process has not worked for a number of people so I thought I should add the following tip.
If you leave any folders behind then make sure that you remove any conditions. A example of this is the folder for the state restore phase, when using the custom task sequence BDD will see that it is not in the state restore phase and skip the folder. This means that non of the tasks in that folder will be run. The screen shot below shows the condition that should be removed.
Another good tip is to leave the "Gather local only" task in your task sequence as this will then ensure that the BDD environment variables are collected. These are then able to be used by other scripts.
UPDATE - 01/09/08
MDT 2008 now includes built in support for custom task sequences and you do not need to use this process.
Disclaimer: The information on this site is provided "AS IS" with no warranties, confers no rights, and is not supported by the authors or Microsoft Corporation. Use of included script samples are subject to the terms specified in the Terms of Use .
Comments
Anonymous
January 01, 2003
I am often asked how to setup a custom task sequence that will continue after a reboot. If you have createdAnonymous
January 01, 2003
I am often asked how to setup a custom task sequence that will continue after a reboot. If you have createdAnonymous
January 01, 2003
No LTI is not SMS OSD, so you should be fine. Thanks, BenAnonymous
January 01, 2003
So to the clients join a domain? I have not precreated multiple profiles before in a non domain environemt. So with out doing some testing I am not sure what to suggest. Maybe some reading these comments can help. Thanks, BenAnonymous
January 01, 2003
Hi WJO, Can you send me a copy of your ts.xml and customsettings.ini files. ben dot hunter at microsoft dot com. Thanks, BenAnonymous
January 01, 2003
Hello Ben, Many Thanks for your reply. I will give it a go n let you knowAnonymous
January 01, 2003
Yes it will.Anonymous
January 01, 2003
You can set these directly in the customsettings.ini file. Did you get a chance to look at the configuration reference document in the BDD documentation folder? Thanks, BenAnonymous
January 01, 2003
I am very happy with the progress of the deployment guys blog so far. Hopefully you all agree that weAnonymous
January 01, 2003
hello ben, many thanks for your help n reply. How to customize System Management Server - BDD Lite touch installation screen which runs thruout the installation from start to finish of application installation. Is there any way i can customize the image and modify the picture..so my user will see customize image...? RizAnonymous
January 01, 2003
Hi Ted, It shouldn't do that! Have you removed all of the tasks accept the ones you want to test from the task sequence? Thanks, BenAnonymous
January 01, 2003
Hi Jeromy, That is a general error meaning "an error has occured". This is usually caused by an error in the script you are trying to launch. Does the script run when you launch it manually? Thanks, BenAnonymous
January 01, 2003
Hi Jonathan, There is not a way do do this using BDD. You may be able to find a way but I don't know of one. The method I use is to customise the administrator profile in a scripted manner during the image creation. This is not too hard to do and is very easy to repeat when needed. Thanks, BenAnonymous
January 01, 2003
Hi Ted, Can you send me a copy of the files in the minint folder? ben dot hunter at microsoft dot com Thanks, BenAnonymous
January 01, 2003
There are two problems you could run into when using this process with Deployment 4.
- If you create a custom task sequence based on a REPLACE template then it fails saying it cannot find distribution$controlts.xml
- If you use a different template then I get an error saying I haven’t specified a deploymenttype value. This is you to checks put in place to verify the type of task sequence being executed. This design essentially means that you cannot use a custom task sequence unless you include an “Install Operating System” task in the task sequence. However, you can disable this task and the process will then function as it would in BDD 2007. Thanks, Ben
Anonymous
January 01, 2003
That screen cannot be customised.Anonymous
January 01, 2003
Hi Brian, Have you seen the fllowing blog post by Michael Niehaus? http://blogs.technet.com/mniehaus/archive/2007/03/07/adding-custom-tasks-to-bdd-2007-task-sequences.aspx It is really helpful with this stuff. Thanks, BenAnonymous
January 01, 2003
The comment has been removedAnonymous
January 01, 2003
You could try doing this with a vbscript using the run command. object.Run(strCommand, [intWindowStyle], [bWaitOnReturn]) For more information on using this command then refer to the following link: http://msdn2.microsoft.com/en-us/library/d5fk67ky.aspx The following script should do the job. Dim oShell Set oShell = WScript.CreateObject ("WSCript.shell") oShell.run "cmd /C ""START %SCRIPTROOT%SetupDFz.BAT""",0,false Set oShell = Nothing Thanks, BenAnonymous
January 01, 2003
Hi Greg, Michael Niehaus has a blog post on just this topic: http://blogs.technet.com/mniehaus/archive/2007/03/07/adding-custom-tasks-to-bdd-2007-task-sequences.aspx Thanks, BenAnonymous
January 01, 2003
hello ben, i will send you my customsettings.ini and screen shot of prompt which I m getting.many thanksAnonymous
January 01, 2003
Hi Maro, You should use the %DEPLOYROOT% value when running a batch file. For example the working diredtory would be ""%DEPLOYROOT%Application". Thanks, BenAnonymous
January 01, 2003
Hi Jared, That is expected behaviour, you should just ignore all of the screens accept the one that prompts you to select the build.Anonymous
January 01, 2003
Will It still run the LTICleanup.wsf script and clean all the Directory’s and reg keys?Anonymous
January 01, 2003
As with BDD 2007 you have the ability to create a separate task sequence that allows you to test anythingAnonymous
January 01, 2003
Hi Adam, The buildid can be set using the customsettings.ini file. You simply need to add some logic into the CS.ini that determines the buildid based on the computer name. To do this I would suggest using the BDD database or a userexit script. Thanks, BenAnonymous
January 01, 2003
Unfortunately this wont help :(. This is a requirement of Windows PE 2.0. Thanks, BenAnonymous
January 01, 2003
hello ben, see the below url..i have upload the bdd lite touch screen i m refering to http://img5.imagevenue.com/img.php?image=05103_bdd-lt_122_465lo.jpgAnonymous
January 01, 2003
Ben, If you change the requirements of the Validate task would that allow the Task Sequence to run with only 256MB?Anonymous
January 01, 2003
Hi Mike, Sysprep will be over writing the profiles you are copying with the administrator profile. It is generally not recommended to copy profiles to the client during deployment. Espically the default user profile. What I do is setup the Administrator profile exactly as I need it during the image creation process. This profile will then be copied over the default user profile. Hopefully this will give the end result you are looking for. Thanks, BenAnonymous
January 01, 2003
Hi Riz, there are two options that you could use. The first option is to update the LiteTouch.wsf file, to add a reboot after the cleanup is performed. Here is an example: ' Clean up Cleanup Reboot WScript.Sleep 600000 ' Wait for the system to be rebooted out from under the script The second is to add a task at the end of the task sequence that runs the following command: c:windowssystem32shutdown.exe -r -t 10 -c "Rebooting the PC to complete the Build" This allows for a full reboot which enables a lot of things in group policy and allows a reboot to complete the installs of some post image software. By setting it to 10 seconds it also allows the wizard to complete which then runs the clean up.Anonymous
January 01, 2003
What you need to do is create a task that updates the required registry keys to enable autologon. BDD will then reset these keys at the end of the task sequence. Thanks, BenAnonymous
January 01, 2003
The comment has been removedAnonymous
January 01, 2003
Hi Riz, If you have a look at the help for the shutdown command you will see there are a number of different options. It should work the way it is but you can remove the comment and it will definitely automatically reboot without needing to press close.Anonymous
January 01, 2003
Hi Mike, There will be a simple upgrade path from BDD 2007 to Deployment 4. Deployment 4 is more of an incremental improvement rather than a huge shift so you should have no problems moving. Thanks, BenAnonymous
January 01, 2003
What is the second profile you are copying? Thanks, BenAnonymous
January 01, 2003
How often when creating a your perfect image do you find that you run through image build process onlyAnonymous
January 01, 2003
Hi Rich, do you have the following settings in your sysprep.inf file? [GuiRunOnce] "cscript.exe %SystemDrive%MININTScriptsLiteTouch.wsf /start" Thanks, BenAnonymous
January 01, 2003
The comment has been removedAnonymous
January 01, 2003
Hi Paul, I use scripts to do things like configure the start menu, configure reginal settings etc. I do this from within BDD when I create the image. This means that I don't have to sysprep the machine twice. There are also times when you cannot script the changes required in this case I pause the task sequence and then resume when I have made the manual changes. Here is a link that explains the process: To do this I create an application that includes the text file and a VB script containing the lines below and then add this application to the task sequence: set oShell= CreateObject("Wscript.Shell") oShell.Run " C:windowsNotepad.exe ManualTasks.txt ",3,True Thanks, BenAnonymous
January 01, 2003
Hi Mike, This is not something I have tried. This may require a little creative scripting. You could create a script that creates an instance in the windows task scheduler to launch another script that will install the program and perform the settings you are looking for. This task could then be added to the end of the build task sequence. Thanks, BenAnonymous
January 01, 2003
Hi Mike, You can use the imagex export option to copy your image from one WIN to another. Here is an example: imagex /export d:imagingdata.wim 1 d:imagingnewfile.wim "Exported Image" Thanks, BenAnonymous
January 01, 2003
The comment has been removedAnonymous
January 01, 2003
The comment has been removedAnonymous
January 01, 2003
Yes this can be done. Have a look at the configuration reference document in the BDD documentation folder for information on how to automated a Lite Touch deployment. Thanks, BenAnonymous
January 01, 2003
The comment has been removedAnonymous
January 01, 2003
Hi Andrea, This is really not my area of expertise. I would recommend looking at the BitLocker blog for this type of information. http://blogs.technet.com/bitlocker/ Thanks, BenAnonymous
January 01, 2003
The comment has been removedAnonymous
January 01, 2003
What is the best way to create an Application that runs a Batch file? Should i set the working directory .ApplicationMy Application? Should i use "%DEPLOYROOT%ApplicationMy ApplicationSetup.exe" /options in my Batch file?Anonymous
January 01, 2003
BDD will install all applications as the local administrator. You do not need to modify any scripts too use the domain admin account as BDD does npt need to use it. When installing applications I prefer to add them as applications in the deployment workbench then add them into the task sequence.Anonymous
January 01, 2003
Hello Ben, thanks, In my current bdd lite touch installation..all the applications are installed by default local administrator account..do i need to modify script in order to run the installation with the domain account or just change the unattend.xml with domain account login..? i m not sure whether application installation is done by bdd task sequence script or by unattend.xmlAnonymous
June 05, 2007
Ben, When I do your method,and launch the litetouch.vbs file, it brings up the refresh computer screen and not the Custom task installs that I thought it would. any suggestions ? trying to get the custom tasks additions ive done to launch and test. as you know, it take forever to do a complete build only to find out you fat fingered some code. I think this process will help, just need some assistance. Thanks in advance. Jared WetmoreAnonymous
June 14, 2007
Hello, please provide me the command to add on custom task in BDD lite touch so machine can logoff after os is deployed and application is installed. I want to run a custom task to logoff the machine automatically after application installation. I have tried the command : shutdown -l but no luck..task seq..return error warning..please helpAnonymous
June 18, 2007
hello Ben, many thanks...it did work but i have 1 query..if you dont mind...please... as i try option 2 with c:windowssystem32shutdown.exe -r -t 10 -c "Rebooting the PC to complete the Build" Promt n then click close..WHT i m looking is it should automatically logoff without myself pressing close...Anonymous
June 19, 2007
The comment has been removedAnonymous
July 30, 2007
Hi Ben, Thanks for this great idea, saves ton of time in testing. Also, thanks for all your work with the BDD community it is much appreciated!! I have an application that needs the computer to reboot after installing and after installing this application I want to continue installing a couple others that depend on this first one. So I have application "A", "B", and "C". "C" and "B" depend on "A" to be installed, and "A" needs to reboot the computer after being installed. I tried just adding a reboot task in the sequence, but when windows restarts I am prompted to login and the task sequence does not continue where it left off. How can I accomplish this with your method? Thanks, EricAnonymous
August 22, 2007
How can I add a task to only reboot after the finished button has been pressed? If I add the task like (The second is to add a task at the end of the task sequence that runs the following command: c:windowssystem32shutdown.exe -r -t 10 -c "Rebooting the PC to complete the Build") the machine keeps rebooting. Can you add a task after the LTICleanup.wsf scripted runs? If not can the script it self be modified to reboot once complete?Anonymous
September 04, 2007
Hi Ben, Thanks for the tip! It works great when the task launches exe file. Unfortunately when you want to use cmd, it fails (however it works perfectly when executed during full install). I understand that it is related to the problem with paths when UNC is used (apps launched from deployment point on the network). I there any workaround available? Thanks GregAnonymous
September 13, 2007
ben i am trying to install a process for building vista via BDD07 with as little user action as possible. so far most of the process is automated but I cannot seem to by-pass the input language and keyboard layout scrren at the very start. I have edited the unattend.xml to UIShow to settings "never" an "on error" but it does not seem to have fixed the issue....any tips?Anonymous
September 17, 2007
When I launch litetouch.vbs it actually goes through the entire process including the imaging. Is it suppose to do this (I didn't think so)? Any ideas as to why this is occuring?Anonymous
September 18, 2007
Yes, I created an APPLICATIONONLY build with only State Restore (nothing in options tab)folder and then the custom tasks: Gather Local Only and my application install. One thing is that my Win PE Rules are set as follows so I don't have too many options to choose from: [Settings] Priority=Default Properties=MyCustomProperty [Default] OSInstall=Y UserDataLocation=NONE SkipAppsOnUpgrade=YES SkipCapture=YES SkipAdminPassword=YES SkipProductKey=YES SkipBDDWelcome=YES SkipDomainMembership=YES SkipApplications=NO SkipDomainMembership=NO JoinDomain=domainname SkipUserData=Yes SkipTimeZone=YES MachineObjectOU=OU=PreStage,OU=Vista,OU=Client Production,DC=domain,DC=com BuildiD=20070910_VISTA SkipLocaleSelection=Yes SkipTimeZone=YES SkipBuild=YES TimeZoneName=Eastern Standard TimeAnonymous
September 18, 2007
The comment has been removedAnonymous
September 18, 2007
All this AND fast responses! Was that 10mins from posting to answer? Thanks for the responses. I found somewhere that changing the PageFile.SYS size to free up some memory and created a LiteTouch boot disk which did that but wasn't able to partition the drive because that's where the PageFile.SYS resides. One more question...If I'm just deploying XP, are there any advantages to using Deployment4 over BDD2007? If I install Deploy4 is there any chance that it will stuff up my existing BDD environment? I'd hate to finally get it working and then try Deploy4 and have it stop :-(Anonymous
September 19, 2007
Thanks Ben, that did the trick.Anonymous
September 19, 2007
The comment has been removedAnonymous
September 25, 2007
Ben, I am trying this process with v4 and it does not work. I was successfully using it with BDD 2007. When I run the litetouch.vbs I get the dialogs to select the build I want but after that nothing.Anonymous
September 25, 2007
The comment has been removedAnonymous
September 26, 2007
Thanks Ben, that did it.Anonymous
October 05, 2007
The comment has been removedAnonymous
October 08, 2007
Ben, Is there any way to add a task (or 2) to be performed immediately after the BDD2007 has completely finished? I want to change the default domain, via registry setting, and install a program (DeepFreeze) which automatically reboots (the program gives you no choice in this). I don't want to be left with the MININT folder and the registry changes to change the domain are cleared as soon as BDD2007 completes.Anonymous
October 09, 2007
The comment has been removedAnonymous
October 10, 2007
The comment has been removedAnonymous
October 11, 2007
Hi Ben, i think your blog is great and has helped me really customize BDD 2007. I keep running into an inssue installing applications using a .cmd or .bat file. i followed your instructions and created a custom build that installs only applications, select the application to install and i get the following error in BDD.log The error in ZTIApplications.log is "Application Adobe Acrobat Reader 8.0 returned an unexpected return code: 1" If then look at SMSTS.log then i'm getting this warning The warninig i get in my smsts.log is "Could not finalize logs to SMS client log directoru (80070002)" Here is my application properties: Quiet Install command = Acrobat8.bat Working Directory = .ApplicationsAcrobat Reader 8 Here is the commands i'm running in my batch file: msiexec.exe /i "%DEPLOYROOT%ApplicationsAcrobat Reader 8AcroRead.msi" /qb- DEL "%ALLUSERSPROFILE%DesktopAdobe Reader 8.lnk" /Q REGEDIT /S "%DEPLOYROOT%ApplicationsAcrobat Reader 8AcrobatReader.reg" Does this look like it would cause problems?Anonymous
October 11, 2007
Ben, A couple more questions:
- Is there any way to change the task sequence templates so that when I create another build it gets a couple of steps I always want?
- Is there any way to store ans use multiple images in the Operating System WIM file?
Anonymous
October 17, 2007
"It is worth noting that SMS OSD can only deploy the first image in a wim". If I am using BDD2007 LTI is that SMS OSD?Anonymous
October 18, 2007
There doesn't seem to be any way to combine 2 images with ImageX, once you've captured them? I have several XP images which I've captured with ImageX, all with the same HAL, and I want to put them all in the same .WIM file. I can't use the Task Sequences to just deploy the changes to a vanilla image as the machines came pre-imaged and loaded with software from our vendor.Anonymous
October 24, 2007
Ben, Thanks for that. It's worked a treat. My 40GB of .WIM images is now 12GB! Apart from creating it as the Local Administrator profile, is there any way to setup profiles? I have 2 different profiles I want setup on the same machine. I have tried copying the profiles to a folder on my Distribution$ then putting in a step to copy them back,but it doesnt seem to be working . It's almost like I want to save user data? But I don't want it removed after I've copied it to my image.Anonymous
October 25, 2007
Ben, Thanks. Yes I've already done that with the Administrator profile to be the default but I need a 2nd profile. Is there any way to have it copied as part of the UserData restore?Anonymous
October 25, 2007
Ben, Being a Secondary School we have a Student login and a Teacher login.Anonymous
January 07, 2008
Ben... Great posts. I would liek to use this method and launch it after we plug in our server. (ie launch this from Windows on the first login) is there a way to skip all the screen prompts and have a script of mine set the buildid based on the computername? (i can code te script to set the BuildID) but not sure where/or how to set the BuildID when running it manually :PAnonymous
January 08, 2008
Hi Ben, Thanks for such a quick answer. So basically I just need to populate Cs.ini - can this be used to supress all the screens when running manually. I have most of the screens supressed during a normal deployment, just wanted to make sure this could be applied when running the litetouch manually.. Thanks again, AdamAnonymous
January 08, 2008
Ben, Thanks for all your help. I have this working now... for one server. My last question is can I set my userexit script to set multiple values in CS.ini? I need to set a load of Skip=YES's and some propertys... do I have to write a seperate function for every one or can I just set multiple properties in one go? Thanks AdamAnonymous
January 09, 2008
Hi Ben, Yes I did and it was quite informative but I didn;t see much on user exit scripts. What I wanted to do was query a 3 letters within the computer name and set the build based on that. I have managed to write a user exit script which queries this and sets the BuildID to the correct number. I also hid all the wizard screens so the user is not prompted during the deployment. The complication was because there was already an O/S and we just wanted to use BDD to deploy the applicatoins only. Thank you for pointing me in the right direction Ben.. Cheers, AdamAnonymous
January 17, 2008
Hi Ben, I read the post you talk about the default profile being as the administrator profile is when creating the image. I have a copy of the default profile I would like to use... Is there a way to copy it over when i'm creating my image, so it can be applied to the administrator profile? Because, correct me if I'm wrong, but default profile is only used to create a profile. So if I understand your post correctly, the only way would be to do all my config manually once? Thanks for the help Keep up the good work, this site is a bible for me :) JonathanAnonymous
January 31, 2008
The comment has been removedAnonymous
February 05, 2008
Ben- Would there be any way to recover data on a Bitlocker drive? If the OS goes south would Windows recovery work? It seems possible now to add a non OS drive to Bitlocker, if I had a d drive that had user data and Bitlocker encryption, would I be able to re-install windows on c & recover data on d? I'm trying to figure out my strategy for our notebook users and would like a recomendation for best practice and a recovery solution. Thanks for any advise AndreaAnonymous
February 06, 2008
The comment has been removedAnonymous
February 13, 2008
Ben, You are a super star. This worked! [GuiRunOnce] "cscript.exe %SystemDrive%MININTScriptsLiteTouch.wsf /start" In a Windows XP deployment scenario from MDT. Is the TS looking at both of my sysprep.inf's (from captured image & TS)? Cheers, RichAnonymous
March 21, 2008
Ben, when you say: "The method I use is to customise the administrator profile in a scripted manner during the image creation. This is not too hard to do and is very easy to repeat when needed." can you give an example? Can I do this from within BDD as opposed to imaging a machine, making profile changes, sysprepping, capturing the wim, etc?