Monday, January 11, 2010

Useful DOS Commands

Though DOS or Disk operated system appears to be an obsolete OS, with availability of Java, Linux etc., there are still some utilities that can be performed using a DOS command. Many times when I wanted to find a DOS command for a particular operation either I didn’t remember it or didn’t find a book to look out for it. So now as and how I remembered a few DOS commands I have listed them for everyone’s help.

ATTRIB –R –A –S –H FILENAME.TXT
- Removes the Read only, Archive, System & Hidden attributes
Use the + sign instead to add/restore the attributes
ATTRIB FILENAME.TXT /S
- Locate Hidden Files & search in all Subdirectories
Use this command to find files that DIR can’t…
FDISK - Hard Disk Partition Manager

FDISK /MBR - Removes any FOREIGN items from the Master Boot Record
* WARNING: Do Not Use with Drive Overlays!
FORMAT C: /S /U - Formats the Hard Disk w/System Boot Files Unconditionally

SYS C: - Places the System Boot Files on the Hard Disk non-volatility

COPY CON WHATEVER.TXT
- Creates new files when EDIT is NOT available
COPY the CON (keyboard) to this FILENAME
DIR *.* /O:D /S - Searches for All Files in the current directory & subdirectories, Organizes by Date, then reports a TOTAL in Bytes of all Files & Folders

* Use this command to determine the SIZE of a Directory Structure

COPY C:\WINDOWS\*.EXE A:\TEMP
- Copies all of the EXE files to the Floppy in Temp Folder

PATH - Check the current PATH (where the PC looks for commands)

TYPE C:\CONFIG.SYS
- Displays the contents of a file

EDIT C:\CONFIG.SYS
- Edits the contents of a file

No comments:

Post a Comment