On the WindowsXP CP, in the SUPPORT\TOOLS directory,
there is a file called DEPLOY.CAB.
Extract the programs DEPLOY.CHM (help file) and SETUPMGR.EXE (main program)
Run SETUPMGR and answer the prompts.
This will create both a unattend.bat and unattend.txt file you can use for automated installs.
Note: The batch file might need some minor modification for file locations but it is fairly basic.
Sunday, December 6, 2009
WindowsXP Command Line Utilities
While there are a lot of command line utilities in WindowsXP, here are some that I have been using lately.
bootcfg - Configures, queries, or changes Boot.ini file settings.
driverquery - Displays a list of all installed device drivers and their properties.
getmac - Returns the media access control (MAC) address and list of network protocols associated with each address for all network cards in each computer
gpresult - Displays Group Policy settings and Resultant Set of Policy (RSOP) for a user or a computer
netsh - You can use commands in the Netsh Interface IP context to configure the TCP/IP protocol
schtasks - Schedules commands and programs to run periodically or at a specific time
systeminfo - Displays detailed configuration information about a computer and its operating system
bootcfg - Configures, queries, or changes Boot.ini file settings.
driverquery - Displays a list of all installed device drivers and their properties.
getmac - Returns the media access control (MAC) address and list of network protocols associated with each address for all network cards in each computer
gpresult - Displays Group Policy settings and Resultant Set of Policy (RSOP) for a user or a computer
netsh - You can use commands in the Netsh Interface IP context to configure the TCP/IP protocol
schtasks - Schedules commands and programs to run periodically or at a specific time
systeminfo - Displays detailed configuration information about a computer and its operating system
Labels:
Windows XP
Hiding the Last User Logged On
If you use the standard NT style of login and want to hide the last user:
Start the Group Policy Editor (gpedit.msc)
Go to Computer Configuration / Windows Settings / Security Settings / Local Policies / Security Options
Scroll down to Interactive logon: Do not display last user name
Set it to Enable Go to top
Start the Group Policy Editor (gpedit.msc)
Go to Computer Configuration / Windows Settings / Security Settings / Local Policies / Security Options
Scroll down to Interactive logon: Do not display last user name
Set it to Enable Go to top
Removing Thumbs.db Files
When viewing a folder with the Thumbnail view, WindowsXP creates a thumbs.db file.
This is a cache of the current pictures in that directory.
If you want to turn this feature off and save a little disk space
Start the Windows Explorer
Go to Tools / Folder Options / View
In the first section under Files and Folders, check Do not cache thumbnails
Now you can search for the thumbs.db file on your computer and remove them. No more should be created.
This is a cache of the current pictures in that directory.
If you want to turn this feature off and save a little disk space
Start the Windows Explorer
Go to Tools / Folder Options / View
In the first section under Files and Folders, check Do not cache thumbnails
Now you can search for the thumbs.db file on your computer and remove them. No more should be created.
Enable / Disable the Task Manager
Start Regedit
Go to HKEY_CURRENT_USER\Software\m*cro$oft\Windows\Curre ntVersion\Policies\System
Create the Dword value DisableTaskMgr
Give it a value of 0 to enable it
Give it a vaule of 1 to disable it Go to top
Go to HKEY_CURRENT_USER\Software\m*cro$oft\Windows\Curre ntVersion\Policies\System
Create the Dword value DisableTaskMgr
Give it a value of 0 to enable it
Give it a vaule of 1 to disable it Go to top
Labels:
Windows XP
NTLDR or NTDETECT.COM Not Found
If you get an error that NTLDR is not found during bootup,
If you have FAT32 partitions, it is much simpler than with NTFS.
Just boot with a Win98 floppy and copy the NTLDR or NTDETECT.COM files
from the i386 directory to the root of the C:\ drive.
For NTFS:
Insert and boot from your WindowsXP CD.
At the first R=Repair option, press the R key
Press the number that corresponds to the correct location for the installation of Windows you want to repair.
Typically this will be #1
Enter in the administrator password when requested
Enter in the following commands (X: is replaced by the actual drive letter that is assigned to the CD ROM drive.
COPY X:\i386\NTLDR C\:
COPY X:\i386\NTDETECT.COM C:\
Take out the CD ROM and type exit
Bringing Up the Shutdown Dialog Box
Create a new txt file somewhere on your system, open it and put in this one line:
(new ActiveXObject("Shell.Application")).ShutdownWindow s();
Save and Close the file. Change the extension to js and your got it.
You can make a shortcut to that file to make it easy to shut down your system.
If you have FAT32 partitions, it is much simpler than with NTFS.
Just boot with a Win98 floppy and copy the NTLDR or NTDETECT.COM files
from the i386 directory to the root of the C:\ drive.
For NTFS:
Insert and boot from your WindowsXP CD.
At the first R=Repair option, press the R key
Press the number that corresponds to the correct location for the installation of Windows you want to repair.
Typically this will be #1
Enter in the administrator password when requested
Enter in the following commands (X: is replaced by the actual drive letter that is assigned to the CD ROM drive.
COPY X:\i386\NTLDR C\:
COPY X:\i386\NTDETECT.COM C:\
Take out the CD ROM and type exit
Bringing Up the Shutdown Dialog Box
Create a new txt file somewhere on your system, open it and put in this one line:
(new ActiveXObject("Shell.Application")).ShutdownWindow s();
Save and Close the file. Change the extension to js and your got it.
You can make a shortcut to that file to make it easy to shut down your system.
Labels:
w
NTOSKRNL Missing or Corrupt
If you get an error that NTOSKRNL not found:
Insert and boot from your WindowsXP CD.
At the first R=Repair option, press the R key
Press the number that corresponds to the correct location for the installation of Windows you want to repair.
Typically this will be #1
Change to the drive that has the CD ROM.
CD i386
expand ntkrnlmp.ex_ C:\Windows\System32\ntoskrnl.exe
If WindowsXP is installed in a different location, just make the necessary change to C:\Windows
Take out the CD ROM and type exit
Insert and boot from your WindowsXP CD.
At the first R=Repair option, press the R key
Press the number that corresponds to the correct location for the installation of Windows you want to repair.
Typically this will be #1
Change to the drive that has the CD ROM.
CD i386
expand ntkrnlmp.ex_ C:\Windows\System32\ntoskrnl.exe
If WindowsXP is installed in a different location, just make the necessary change to C:\Windows
Take out the CD ROM and type exit
Labels:
Windows XP
HAL.DLL Missing or Corrupt
If you get an error regarding a missing or corrupt hal.dll file, it might simply be the BOOT.INI file on the root of the C: drive that is misconfigured
Insert and boot from your WindowsXP CD.
At the first R=Repair option, press the R key
Press the number that corresponds to the correct location for the installation of Windows you want to repair.
Typically this will be #1
Type bootcfg /list to show the current entries in the BOOT.INI file
Type bootcfg /rebuild to repair it
Take out the CD ROM and type exit
Corrupted or Missing \WINDOWS\SYSTEM32\CONFIG
If you get the error:
Windows could not start because the following files is missing or corrupt
\WINDOWS\SYSTEM32\CONFIG\SYSTEM or \WINDOWS\SYSTEM32\CONFIG\SOFTWARE
Insert and boot from your WindowsXP CD.
At the first R=Repair option, press the R key
Press the number that corresponds to the correct location for the installation of Windows you want to repair.
Typically this will be #1
Enter in the administrator password when requested
cd \windows\system32\config
Depending on which section was corrupted:
ren software software.bad or ren system system.bad
Depending on which section was corrupted
copy \windows\repair\system
copy \windows\repair\software
Take out the CD ROM and type exit Go to top
Insert and boot from your WindowsXP CD.
At the first R=Repair option, press the R key
Press the number that corresponds to the correct location for the installation of Windows you want to repair.
Typically this will be #1
Type bootcfg /list to show the current entries in the BOOT.INI file
Type bootcfg /rebuild to repair it
Take out the CD ROM and type exit
Corrupted or Missing \WINDOWS\SYSTEM32\CONFIG
If you get the error:
Windows could not start because the following files is missing or corrupt
\WINDOWS\SYSTEM32\CONFIG\SYSTEM or \WINDOWS\SYSTEM32\CONFIG\SOFTWARE
Insert and boot from your WindowsXP CD.
At the first R=Repair option, press the R key
Press the number that corresponds to the correct location for the installation of Windows you want to repair.
Typically this will be #1
Enter in the administrator password when requested
cd \windows\system32\config
Depending on which section was corrupted:
ren software software.bad or ren system system.bad
Depending on which section was corrupted
copy \windows\repair\system
copy \windows\repair\software
Take out the CD ROM and type exit Go to top
Labels:
Windows XP
Repair Install
If XP is corrupted to the point where none of the previous solutions get it to boot,
you can do a Repair Install that might work as well as keep the current settings.
Make sure you have your valid WindowsXP key.
The whole process takes about half an hour depending on your computer
If you are being prompted for the administrator's password, you need to choose the 2nd repair option, not the first.
Insert and boot from your WindowsXP CD
At the second R=Repair option, press the R key
This will start the repair
Press F8 for I Agree at the Licensing Agreement
Press R when the directory where WindowsXP is installed is shown. Typically this is C:\WINDOWS
It will then check the C: drive and start copying files
It will automatically reboot when needed. Keep the CD in the drive.
You will then see the graphic part of the repair that is like during a normal install of XP (Collecting Information, Dynamic Update, Preparing Installation, Installing Windows, Finalizing Installation)
When prompted, click on the Next button
When prompted, enter your XP key
Normally you will want to keep the same Workgroup or Domain name
The computer will reboot
Then you will have the same screens as a normal XP Install
Activate if you want (usually a good idea)
Register if you want (but not necessary)
Finish
At this point you should be able to log in with any existing accounts. Go to top
you can do a Repair Install that might work as well as keep the current settings.
Make sure you have your valid WindowsXP key.
The whole process takes about half an hour depending on your computer
If you are being prompted for the administrator's password, you need to choose the 2nd repair option, not the first.
Insert and boot from your WindowsXP CD
At the second R=Repair option, press the R key
This will start the repair
Press F8 for I Agree at the Licensing Agreement
Press R when the directory where WindowsXP is installed is shown. Typically this is C:\WINDOWS
It will then check the C: drive and start copying files
It will automatically reboot when needed. Keep the CD in the drive.
You will then see the graphic part of the repair that is like during a normal install of XP (Collecting Information, Dynamic Update, Preparing Installation, Installing Windows, Finalizing Installation)
When prompted, click on the Next button
When prompted, enter your XP key
Normally you will want to keep the same Workgroup or Domain name
The computer will reboot
Then you will have the same screens as a normal XP Install
Activate if you want (usually a good idea)
Register if you want (but not necessary)
Finish
At this point you should be able to log in with any existing accounts. Go to top
Labels:
Windows XP
