Wednesday, February 24, 2010

Commands for Command prompt

Type following commands on command window to perform the required task.
By typing "help" on command prompt you can get commands for most common tasks e.g. cd, dir, del, exit, copy etc.
Here I will write down some uncommon commands which will be helpful when working on windows XP using command prompt.

  • hostname: Gives hostname of the machine you are using
  • attrib : Shows or updates Attributes of a file, -h removes hidden attrib from file, while +h adds hidden attrib
  • cacls : Changes the ACLS (security settings) for files and folders, similar to chmod in linux
  • control : Unpublished, use "control userpasswords2"findstr: To find strings, similar to grep in linux
  • gpresult : gets the summary of group policy settings and user settings
  • ipconfig : Shows IP Configuration for your system, use "ipconfig -all " for all settings, "ipconfig /release" for releasing Ip Addresses, "ipconfig /renew" for renewing IP address
  • openfiles : Enables administrator to display a list of open files and folders that have been opened 
  •  reg : A console registry tool to edit registry settings
  • systeminfo : displays system information
  • tasklist: list of all running tasks
  • taskkill: to kill running task
  • taskmgr: To open Task manager from command window
  • tree : Really amazing utility, gives the list of files and folders in tree form , should try at least once.
  • shutdown: Will show help for shutting down the windows XP. This will be helpful when you want to shutdown or restart remote computer.
             shutdown -s : shutdown this computer
             shutdown -r : Restart this computer
             shutdown -m \\computername : Remote computer to shutdown/restart/logoff
             shutdown -i : GUI interface for shutdown

Check this lonk for more detailed info and all other available commands:
Microsoft windows command line tools

No comments:

Post a Comment