Advertisment

Unexplored World of Win XP

author-image
PCQ Bureau
New Update

It is little known that Win XP onwards, several new commands have been brought in whose combined use would make our Win XP experience more powerful. They can be used to resolve some common problems such as locked files, inability to find out what or who is browsing through your PC and incorrectly installed drivers. 

Advertisment

Let's take a look at some of them and their usage. To find out more options with these commands, type the commands followed by '/?' at the Win XP command prompt.

Locked files



Whether you're running a standalone PC or one on a network, once someone opens a file from your machine and does not close it properly, your files get 'locked'. This means that you can neither modify nor delete or move them elsewhere. Even restarting your PC in some cases is of no avail and you keep getting this (locked) error. The solution is a simple command- 'openfiles'. But in order to use it, you need to tell your OS to start tracking file usage and then reboot the PC. Steps are as follows.

Direct Hit!
Applies to: Desktop PC users
USP: Learn to use the newly introduced and largely unknown commands in Win XP 
Links:

http://tinyurl.com/36leu 
Advertisment

Open a command prompt window (Start>Run>cmd) and type in:

C:\Windows> OPENFILES /LOCAL ON

This will turn on usage tracking. Now, reboot the system. After you get the desktop, come back to the command prompt and run:

Advertisment

C:\Windows> OPENFILES /LOCAL

And stare on amazed as it shows you exactly what program has opened what file. If you're on a network, you will get an additional table with network-opened files as well.

Shutdown and reboot



Thought only Linux had a 'shutdown' command? Think again! Win XP now has a command to do this too and, what's more, it has almost exactly the same syntax as its Linux equivalent.

Advertisment

To shutdown, you would say:

C:\> SHUTDOWN -S

To reboot, it would be:

Advertisment

C:\> SHUTDOWN -R

If you don't want to stay up late while downloading a large file, a neat trick would be to create a batch file to automatically shutdown your PC and execute it via Scheduled Tasks.

The driverquery with the /fo table switch displays a better-formatted list 



of loader drivers

Advertisment

Encrypt files



If your drive is formatted with the NTFS file system, then you can encrypt the files you put into it. The command to affect the encrypted state of a file or folder is 'cipher'. Encrypting a folder will encrypt all the files and folders inside it recursively. To encrypt all files and folders in the current folder:

C:\Documents and Settings\John Doe\My Documents> CIPHER /A /E /S /I /F *.*

To decrypt the above, simply pass '/D' instead of '/E'. 

Advertisment

Encryption is done using a cipher key (PFX/CER format). Cipher also provides options to back up and save these keys to a file for later use. This is useful if you're planning to re-install a system. You also have options to clean up your hard disk ('/W').

Drivers



With Win NT, we had a useful control panel applet called 'Devices', which let you manage what drivers were loaded. Unfortunately, the makers of Win XP decided to do away with it. However, there is still a way out in the form of an equivalent command, which is:

C:\> DRIVERQUERY /V

But, this will not allow you to start/stop these drivers like the NT applet. Again, there is a solution. Note down the name displayed in the first 'Module Name' column of the displayed list, and use that with the NET command as follows.

C:\> NET

For example, to stop a service called 'USBSTORE', you would do the following.

C:\> NET STOP USBSTORE

MAC address



Want to know your network adapter's MAC address? The GETMAC command is useful if you are also a system administrator and need to set up DHCP reservations and policies. You can also use this command to retrieve MAC addresses for other machines on a network.

C:\> GETMAC

One thing that would disappoint you is that this command will not tell you which adapter it is for, if you have more than one card installed.

These are not the only things new to Win XP. In the coming articles in this series, we shall see some more features and commands.

Sujay V. Sarma

Advertisment