Automating Windows XP Setup: An alternative to cloning - PowerPoint PPT Presentation

1 / 19
About This Presentation
Title:

Automating Windows XP Setup: An alternative to cloning

Description:

A scripted 'build' (imho) is easier to maintain for a very heterogeneous ... Bootable Win98 (dos)-based cd contains XP source files, in an image file for ... – PowerPoint PPT presentation

Number of Views:48
Avg rating:3.0/5.0
Slides: 20
Provided by: FAS96
Category:

less

Transcript and Presenter's Notes

Title: Automating Windows XP Setup: An alternative to cloning


1
Automating Windows XP Setup An alternative to
cloning
  • Dave Motovidlak - FAS
  • davemoto_at_rutgers.edu

2
Strengths of scripted builds (1)
  • Standardization, time savings (no babysitting)
  • Cloning is extremely useful, especially in large
    scale deployments of identical machines. But
  • A scripted build (imho) is easier to maintain
    for a very heterogeneous hardware population.
  • One build fits all. OemPnPDriversPath entry in
    answer file lets you add new drivers Setup does
    all the work of responding to different hardware
    (no concern about sysprep limitations).
  • Updates / additions to build are done only once.

3
Strengths (2)
  • A build is modular.
  • Modifying a build usually entails modifying some
    scripts, adding some files, editing a file or two
    not working with large, monolithic image
    files.
  • Except when updating drivers, testing / updating
    the build is not dependent on having a free
    machine of each particular model. (Can easily
    test with VMWare.)

4
Scripted builds just another tool
  • Though they are still hands-free, scripted
    builds take longer than cloning to produce a
    working machine (at least 30 minutes).
  • Not so appropriate for mass rollouts or cases
    when you need a machine built yesterday.
  • Require basic scripting skills ? Some debugging
    is necessary, which can be time consuming
    (modularity helps, though, since can usually test
    individual component)

5
Basic Framework how to set it up
  • Answer file scripting fully automated XP
    install
  • Use Setup Manager (setupmgr.exe) from Deploy
    folder on XP cd (get SP2 deploy tools updates -
    KB838080)
  • Setupmgr-gtbasic unattend.txt. Read deploy.chm
    and ref.chm for explanation of all sections and
    entries
  • Then perform additional tweaks by hand

6
Key components (1) Auto-logon
You may want to leave Administrator password
empty here and simply change it later with a
script.
7
Key components (2) Run Once
Commands get stored in HKLM \Windows\CurrentVersi
on\RunOnce but execute before explorer.exe loads.
This is sometimes a little finicky I work
around it by executing a script that creates a
shortcut in the Startup group, which then
executes my main script after the shell
loads. Pre_install_Boot1.vbs
Install_Boot1.vbs
8
Key components (3) - Addl Commands
Additional commands happen at end of setup
process, before final reboot and before
auto-logon occurs. Stored in cmdlines.txt in
i386\oem. This section should logically go
before Run Once. May require extra testing
machine is fully built but environment is not
entirely like a regular machine yet. In most
cases, you may want to rely on the Run Once
process that does things post auto-logon.
9
Sample answer file (part 1)
10
Sample answer file (part 2)
11
Sample answer file (part 3)
12
Source directory structure
  • Special folders
  • I386\oem
  • Cmdlines.txt
  • I386\oem\
  • Represents windows directory
  • Can contain system32 subdirectory ? contents will
    be copied to system32 during build (great place
    to put extra utils)

13
Google distribution share first link
14
Putting it all together
  • Support infrastructure
  • Place for source files
  • Distribution share (server)
  • CD / DVD
  • Pre-build environment
  • DOS network boot disk (16 bit environment)
  • WinPE or BartPE (32 bit environment)
  • Supporting batch files or scripts to format
    drive, connect to server, request info from
    builder

15
Pre-build environment scripts (1)
  • May be used to collect some basic information
    from the builder. E.g., ask computername and
    echo it unattend.txt (DOS example using
    get.exe)
  • GET S "COMPUTER NAME for this workstation"
    /vcname
  • echo ComputerName"cname"gtgtC\WINXPSRC\unattend.
    txt
  • echo.gtgtC\WINXPSRC\unattend.txt
  • echo IdentificationgtgtC\WINXPSRC\unattend.txt
  • echo JoinWorkgroupwrkgrpgtgtC\WINXPSRC\unatt
    end.txt
  • Will be used to connect to the server, issue the
    setup command, etc.

16
Sample setup commands
  • DOS environment
  • \\myserver\myshare\i386\Winnt.exe
    /s\\myserver\myshare\i386 /u\\myserver\myshare\u
    nattend.txt
  • Or maybe
  • set prefix\\myserver\myshare\i386
  • prefix\winnt.exe /sprefix /uprefix\unatten
    d.txt
  • Win32 environment
  • \\myserver\myshare\i386\winnt32.exe
    /s\\myserver\myshare\i386 /unattend\\myserver\my
    share\unattend.txt

17
First post-logon scripts
  • Kicked off by the Run Once command
  • Can be used to launch a series of scripts to
    perform remaining customizations
  • Account management (create new ones, disable
    Adminstrator or change password, etc.)
  • Registry / policy customizations
  • Software installation (will depend on support
    environment)
  • Whatever you can automate

18
An example
  • Bootable Win98 (dos)-based cd contains XP source
    files, in an image file for convenience (image
    contains only source files, not a working machine
    config)
  • Boot from disc -gt autoexec.bat launches
    install.bat ?
  • Do you want to continue?
  • Blows down fat32 part containing distribution
    share files onto local drive
  • Reboots, then prompts for PC name, etc.
  • Updates unattend.txt and runs unattended setup

19
Another example
  • BartPE (Win32) boot disc
  • Boot from disc, use script to connect to
    distribution server and run unattended setup from
    server source or format disk, copy source files
    to local drive, and run unattened setup from
    there
  • Or BartPE boot dvd containing all source files?
Write a Comment
User Comments (0)
About PowerShow.com