Naming the Workstation with Scripted Imaging
Novell Cool Solutions: Tip
By Martin Hartkopf
Digg This -
Posted: 7 Apr 2005
When you use Windows Unattended Installation, or SYSPREP, you always run into trouble with automatic naming of the workstation, especially when you also want the workstation to join the domain without any user interaction. Here's a solution that does it right after Image Restore.
First at all you need a ZENworks Image from the unattended installation from right after the first reboot. Then you rename the
In both config files you insert WSNAME for the Workstation Name Variable.
Looks like this:
And here is the script for the Scripted Imaging Engine:
ZISNAME='zisview Name' echo $ZISNAME if test ! $ZISNAME; then echo -e "No ZIS Information was found " echo -e "\n" while test ! $WSNAME; do echo -n "Please Enter Workstation Name ( FMSBXXXX ) : " read WSNAME; done; fi echo -e " Restore from ZEN Proxy" img pd1 img rp 172.31.11.4 //YOURZENSERVER/sys/images/YOURZENIMAGE.ZMG echo -e "Mounting the restored Partition for Variable xchange" mkdir /fat mount -t vfat /dev/hda2 /fat sed 's/wsname/'$ZISNAME'/g' /fat/$/Setup/win.txt > /fat/$/Setup/unattend.txt sed 's/wsname/'$ZISNAME'/g' /fat/'$win_nt$.~bt'/Win.txt > /fat/'$win_nt$.~bt'/Winnt.sif if test $WSNAME; then zisedit Name=$WSNAME; fi echo - e "Clearing and setting some Variables" zisedit workgroup= zisedit SID= zisedit WorkstationID= zisedit DNSHostName=$WSNAME
If you have any questions you may contact Martin at email@example.com
Novell Cool Solutions (corporate web communities) are produced by WebWise Solutions. www.webwiseone.com