Trick #1: Make a flat.
Close your eyes and imagine this for a second. You've made an unattended cd. A friend of yours who is computer illiterate calls you and has a problem with his computer. It hits you that you could save time by running your unattended cd at his house, doing a quick clean install. So you go over to his house, backup his data, and run your unattended cd. Once done you leave with the unattended cd. The next day your friend calls you up. This time he needs your xp cd because he installed something like IIS, and it needs files from the CD. Now you have to drive all the way over to his house again, just to give him your cd. Wouldn't it be nice if an unattended cd not just installed your favorite programs, but copied itself to the hard drive? That way you wouldn't need the cd again.
To make an unattended flat we're gonna need to make 2 files - source.bat and source.reg. We're gonna put both into the windows folder.
First, make this folder:
\$OEM$\$$
Copy what's below and save it as \$OEM$\$$\source.bat
Quote
IF EXIST C:\WIN51IP.SP1 set CDROM=C:
IF EXIST D:\WIN51IP.SP1 set CDROM=D:
IF EXIST E:\WIN51IP.SP1 set CDROM=E:
IF EXIST F:\WIN51IP.SP1 set CDROM=F:
IF EXIST G:\WIN51IP.SP1 set CDROM=G:
IF EXIST H:\WIN51IP.SP1 set CDROM=H:
IF EXIST I:\WIN51IP.SP1 set CDROM=I:
IF EXIST J:\WIN51IP.SP1 set CDROM=J:
IF EXIST K:\WIN51IP.SP1 set CDROM=K:
IF EXIST L:\WIN51IP.SP1 set CDROM=L:
IF EXIST M:\WIN51IP.SP1 set CDROM=M:
IF EXIST N:\WIN51IP.SP1 set CDROM=N:
IF EXIST O:\WIN51IP.SP1 set CDROM=O:
IF EXIST P:\WIN51IP.SP1 set CDROM=P:
IF EXIST Q:\WIN51IP.SP1 set CDROM=Q:
IF EXIST R:\WIN51IP.SP1 set CDROM=R:
IF EXIST S:\WIN51IP.SP1 set CDROM=S:
IF EXIST T:\WIN51IP.SP1 set CDROM=T:
IF EXIST U:\WIN51IP.SP1 set CDROM=U:
IF EXIST V:\WIN51IP.SP1 set CDROM=V:
IF EXIST W:\WIN51IP.SP1 set CDROM=W:
IF EXIST X:\WIN51IP.SP1 set CDROM=X:
IF EXIST Y:\WIN51IP.SP1 set CDROM=Y:
IF EXIST Z:\WIN51IP.SP1 set CDROM=Z:
ECHO Please wait, Recovery Console is being installed locally.
%CDROM%\i386\winnt32.exe /dudisable /cmdcons /unattend
md %systemroot%\Source\i386
ECHO Please wait, source files are being copied. This may take several minutes.
xcopy /Y /e %CDROM%\i386\*.* %systemroot%\Source\i386\
ECHO Adding registry entries.
regedit.exe /s Source.reg
ECHO Done.
exit
Quote
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Setup]
"SourcePath"="%systemroot%\\Source\\"
"ServicePackSourcePath"="%systemroot%\\Source\\"
Now, in your unattend file, make sure you have this:
Quote
OemPreinstall=Yes
OemSkipEula=Yes
[GuiRunOnce]
Command0="%windir%\source.bat"
That's it. When you install xp using the unattend file, recovery console and a flat will be made the first time you boot into windows. This is great for friends that don't have a clue about windows. Now when they call you for help you'll know they have recovery console installed locally and a flat locally.
Trick #2: Brand the my computer window:
You can put a custom logo and name in the my computer window by using a simple inf file and bmp.
First, make this folder:
\$OEM$\$$\System32
In this folder, copy below and save as \$OEM$\$$\System32\oeminfo.ini
Quote
WinVer=5.01
[General]
Manufacturer=gosh
Model=
[Support Information]
Line1="win2k build"
Find a small .bmp and save it as \$OEM$\$$\System32\oemlogo.bmp
Make sure your unattend file has the stuff listed in trick #1. That's it.
Trick #3: Associate file types:
One of the most annoying aspects about xp is how some file types aren't registered the way you want it. For example, most software is released with an .nfo file, but xp wants to open .nfo files in msinfo32. Below is a way to batch file associations:
Quote
assoc .blt=txtfile
assoc .cue=txtfile
assoc .diz=txtfile
assoc .eml=txtfile
assoc .iss=txtfile
assoc .log=txtfile
assoc .md5=txtfile
assoc .m3u=txtfile
assoc .nbi=txtfile
assoc .nfo=txtfile
assoc .nt=txtfile
assoc .pif=txtfile
assoc .sam=txtfile
assoc .sif=txtfile
assoc .sfv=txtfile
assoc *=txtfile
Tip #1: make a log file:
Unattended installs can be hard to troubleshoot. What i like to do is make a log file, which makes it easier to see where the problem is. To make a log file, have each command end in >> logfile.txt
An example from my current apps.bat file:
Quote
ECHO Apps.bat, version %cdver% >> %windir%\apps.log
ECHO Logging started: %date% %time% >> %windir%\apps.log
ECHO Computer: %computername >> %windir%\apps.log
ECHO User: %username% >> %windir%\apps.log
@echo. >> %windir%\apps.log
@echo. >> %windir%\apps.log
This will log information to apps.log.
Trick #3: Disable that stupid xp search companion:
Like the old win2k search? Bring it back!
Quote
regsvr32 /u /s %windir%\srchasst\srchui.dll
Using an oempreinstall you can copy files to your install, such as:
$OEM$\$$\Web\Wallpaper - put wallpapers here
$OEM$\$$\System32 - put screensavers, files such as cdimage.exe and cdburn.exe here
$OEM$\$$\Resources\Themes - put themes here. To specify default them make a .theme file and specify it in unattend file.
Tip #3: Use the server2003 classic accounts:
Copy keymgr.cpl from server2003 to your system32 folder to have classic accounts
Trick #4: Show classic user accounts in control panel.
To see the win2k user accounts window type control userpasswords2. To enable this in an unattended install, import this registry file:
Quote
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\ControlPanel\NameSpace\{7A9D77BD-5403-11d2-8785-2E0420524153}]
@="OldUserAccounts"
That's it for now. Let me know if you enjoy my tips and tricks.
-gosh



Help

Back to top









