Wednesday, November 14, 2012

MS-DOS Commands.


MS-DOS Commands.

      Internal Commands.

01.   To clear the Screen.
Syntax: - Cls   pres enter
Example: - C :\> cls pres enter.

02.   To move one partition to another partition.
Syntax: - Partition Name: pres enter
Example: - D :\> E: pres enter

03. To create a file.
Syntax: - CopyCon pres enter
Example: - D:\>copycon Pres enter

04. To Open a File.
Syntax: - Type pres enter
Example: - D :\> Type pres enter

05. To save a File.
Syntax: - Ctrl + Z or F6.

06. To “Delete” a File or “Erase” a File.
Syntax: - Del < File Name> Pres enter
               ErasePres enter
Example: - D:\>DelPres enter
                 D:\>Erasepres enter

07. To Rename a File.
Syntax: REN Pres enter
Example: - D:\>RENpres enter

    08. To copy an existing File.
    “Ramu” is the existing file from this file, we can make a duplicate  
     File “Krishna” by using this syntax
     Syntax: - Copy < New file Name> Pres enter.
     Example: - D: \> Copy <Krishna> Pres enter.

09. To Make a Directory (or) Folder.
Syntax: -MD Pres enter
Example: - D:\>MDPres enter

10. To Display the list of files and Directories.
Syntax: - Dir Pres enter
Example: - D :\> Dir pres enter.

11. To change Directory.
Syntax: - CD Pres enter
Example: - D:\>CDPres enter
12. To come out the Directory.
Syntax: - Cd...   (Or) Cd|
Example: - D :\>< turaga007> cd..  Pres enter
                 D:\>cd\ pres enter

13. To display the Disk Volume Serial Number (VOL).
Syntax: - VOL pres enter
Example: - D:\>VOL Pres enter

14. To display the version of current Microsoft disk Operating System being used (VER).
Syntax: - VER Pres enter
Example: - D:\>VER Pres enter

15. To display, change and delete the volume label.
Syntax: - Label Pres enter
Example: - D :\> Label Pres enter.

16. Display files with specified attributes.
Syntax: - Dir/A Pres enter.
Example: - D :/> dir / A Pres enter.

17. Display only Attributes Directories.
Syntax: - Dir /AD Pres enter.
Example: - D :\> Dir/ AD Pres enter.

18. Display Attributes Hidden files.
Syntax: - Dir/ AH Pres enter.
Example: - D :\> Dir/ AH Pres enter.

19. Display Attributes System Files.
Syntax: - Dir/AS Pres enter.
Example: - D :\> dir/AS Pres enter.

20. Display Attributes Read- only files.
Syntax: - Dir/ AR Pres enter.
Example: - D:\>Dir /AR Pres enter.

21. Display Attributes files ready for archiving.
Syntax: - Dir / AA Pres enter.
Example: - D :\> dir / AA Pres enter.

22. Display Attributes Pre fix meaning not.
Syntax: - Dir /A – Pres enter.
Example: D :\> Dir / A - Pres enter.


23. List without heading (Or) summary. [Base format.]
Syntax: - Dir/ B Pres enter.
Example: - D: \> Dir/ B Pres enter.

24. Display the thousand separators in file sizes.
Syntax: - Dir/ C Pres enter.
Example: - D :\> Dir / C Pres enter.

25. Disable displays the thousand separators.
Syntax: - Dir / - C Pres enter.
Example: - D :/> Dir / - C Pres enter.

26. Display same as wide but files are list sorted by column.
 Syntax: - Dir / D Pres enter.
 Example: - D :|> Dir/ D Pres enter.

27. To display list of files and directories in lower case.
Syntax: - Dir/L Pres enter.
Example: - D: \> Dir / L pres enter.

28. To Display New long list format where file names are on the far right.
Syntax: - Dir /N Pres enter.
Example: - D :\> Dir / N Pres enter.

29. To display List by files in sorted order.
Syntax: - Dir/O Pres enter.
Example: - D :\> Dir / O Pres enter.

30. List date wise in “Ascending” order.
Syntax: - Dir / OD pres enter.
Example: - D: \> Dir / OD Pres enter.

31. List date wise in “Descending” order.
Syntax: - Dir/ O – D Pres enter.
Example: - D: \> Dir / O – D pres enter.

32. List Extension wise in “Ascending” order.
Syntax: - Dir/OE Pres enter.
Example: - D: \>Dir / OE Pres enter.

33. List Extension wise in “Descending” order.
Syntax: - Dir /O – E Pres enter.
Example: - D: \> Dir / O – E pres enter.

34. Display group directories first then files.
Syntax: - Dir/OG Pres enter.
Example: - D :\> Dir/OG Pres enter.


35. Display Group files first then directory.
Syntax: - Dir/O-G pres enter.
Example: - D:\>Dir/O-G pres enter.


36. To display list name wise (Alphabetically) in “Ascending” order.
Syntax: - Dir/ ON Pres enter.
Example: - D :\> Dir/ON pres enter.

37. To display list name wise (Alphabetically) in “Descending” order.
Syntax: - Dir/O-N Pres enter.
Example: - D :\> Dir / O –N Pres enter.

38. List size wise in “Ascending” order.
Syntax: - Dir/ OS Pres enter.
Example: - D :|> Dir / OS pres enter.

39. List size wise in “Descending” order.
Syntax: - Dir/ O – S Pres enter.
Example: - D: \> Dir / O – S Pres enter.

40. Display Prefix to reverse order.
Syntax: - Dir/ O – Pres enter.
Example: - D :\> Dir /O – Pres enter.

41. To displays the list of directories and Files “Page wise.”
Syntax: - Dir/P Press enter
Example: - D:\>Dir/P Press enter

42. Display the owner of the file.
Syntax: - Dir / Q Pres enter.
Example: - D :\> Dir / Q Pres enter.

43. Displays alternate data streams of the file.
Syntax: - Dir / R Pres enter.
Example: - D: / > Dir / R Pres enter.

44. To display all directories and Sub Directories of the current directory (Or) Specified Directory.
Syntax: - Dir/s Pres enter.
Example: - D :\> Dir/s Pres enter.

45. Controls which time field displayed or used for sorting time field.
Syntax: - Dir / T Pres enter.
Example: - D: \> Dir / T Pres enter.

46. Creation
Syntax: - Dir / TC Pres enter.
Example: - D :\> Dir / TC Pres enter.


47. Last Access.
Syntax: - Dir / TA Pres enter.
Example: - D :\> Dir / TA Pres enter.


48. Last Written.
Syntax: - Dir / TW Pres enter.
Example: - D: \ > Dir / TW Pres enter.

49. Display Directory Width wise.
Syntax: - Dir/w Pres enter.
Example: - D :\> Dir/w Pres enter.

50. This displays the short names generated for non – 8 dot 3 file names. The format is that of / N with the short name is sorted before the long name if no short name is present, blanks are displayed in its place.
Syntax: - Dir / X Pres enter.
Example: - D: \> Dir / X Pres enter.

51. Display directory with 4 digit in year like 1999, 2000, 2001…
Syntax: - Dir / 4 Pres enter.
Example: - D :\> Dir /4 Pres enter.

52. Displays all directories and Sub directories with switches.
Syntax: Dir /? Pres enter.
Example: - D :\> Dir/? Pres enter.

53. Displays all hidden files.
Syntax: - Dir / ah Pres enter.
Example: - D :\> Dir / ah Pres enter.

54. “Remove” Directory.
Syntax: - RD directory – name Pres enter.
Example: - D :\> RD Pres enter.
Precautions for “Remove of Directory”.
(a). Delete all files from the directory, which you want to remove.
(b). Pres CD.. for changing the directory and entering in to Parent directory.
(c). Pres “RD to remove the specified directory.

55. Move file name as Directory Name.
Syntax: - Move Pres enter.
Example: D :\>< Accounts> Pres enter.
Syntax 2: - Move < Target File Name> Pres enter.

56. To display the System “Time”.
Syntax: - Time Pres enter.
Example: - D :\> Time Pres enter.



    57. To display the System “Date”.
    Syntax: - Date Pres enter.
    Example: - D:\>Date Pres enter.

    58. Sort.
    Syntax: - Sort Pres enter.
    Example: - D: \>Sort < Ramu> Pres enter.

    59. To exit Ms - Dos.
    Syntax: - Exit Pres enter.
  Example: - D :\> Exit Pres enter.

External Commands

01. Edit: - Used to create (or) modify a file.
Syntax: - Edit Pres enter.
Example: - D :\> Edit < Ramu> Pres enter. Here Ramu is the file name.

02. X Copy: - Used to Copy files and subfolders at a time.
Syntax: - X copy < Filename> destination Partition: / e
Example: - C :\> X copy < Ramu> D: /e.  Here /e for entire data.

03. More: - used to display list of information in page wise.

Syntax: - dir pipe more for directories.
Syntax: - Type new pipe more for files.
Syntax: - Edit new Pipe more for files edit.
Example: - D :\> dir Pipe more Pres enter.
Example: - D :/> Type new pipe more Pres enter.
Example: - D :\> Edit new pipe more Pres enter.

04. Del tree: - Used to Del tree files & directories at a time.

Syntax: - Del tree folders/ s pres enter.
              RM dir directory name /s pres enter.

Example: - D :\> Del tree folders /s Pres enter.
                 D :/> RM /s Pres enter.
Here /s for sub folders.

05. Tree: - This command displays the files, directories and their sub directories in a pictorial manner.

Syntax: -Tree Pres enter.
Example: - D :\> Tree< Directory Name > Pres enter.

Here, we can use tree/f also f for files. It will shows tree like Hierarical structure.

06. Check Disk: - used to check the partition for errors.

Syntax: - CHKDSK Partition: (or) CHKDSK Partition: / F. Here F for fixing errors.
Example: - D:\>CHKDSK C:\f Pres enter.
Check disk option did not used in running Drive (Or) Current Drive.
07. Attrib: - Used to view or change attributes of files.

Attributes Properties.
A = Achieve.
H = Hidden.
R = Read only.
S = System.
Syntax: - Attrib Pres enter.
Example: - D:\> attrib Pres enter.
Syntax 2: - Attrib Pres enter.
Example: - D:/> Attrib Pres enter. Here “Ramu” is the file name.
For Hidden files
Syntax: - Attrib +H Pres enter.
Example: - D :\> Attrib+H Pres enter.
For UN Hide
Syntax: - Attrib – H Pres enter.
Example: - D :\> Attrib – H < Ramu > Pres enter. Here “Ramu” is the file name.
For Read only.
Syntax: - attrib +R Pres enter.
Example: - D :\> Attrib + R< Ramu> Pres enter.

For removing Read only option.

Syntax: - Attrib – R Pres enter.
Example: - D :\> Attrib – R < Ramu > Pres enter. Here “Ramu” is the file name.

08. Print
Syntax: - Print Pres enter.
Example: - D :\> Print< Ramu> Pres enter. Here “Ramu” is the file name.

09. Dos format Command.
Syntax: - Format< Drive Name>:  Pres enter.
Example: - D:\>Format C: Pres enter.

10. Defrag: It is a command used to dfragmented a partition. ( To increase the Performance.)
Syntax: - Defrag< drive name>: Pres enter.
Example: - D :\> Defrag C: Pres enter.

11. F disk: It is used to create and modify partitions in the hard disk.
It is supported in Dos 95, 98, & Millennium.
Syntax: - F disk Pres enter.
Example: - D :\> F disk Pres enter.

12. Un delete: it is used to recover deleted data.
Syntax: - Un delete pres enter.
Example: - D :\> Un delete Pres enter. Here “Ramu” is the file name.

Dos System Files.

01. IO.Sys.
02. Ms Dos.Sys (or) Kernel File.
03. Configu.Sys.
04. Command.com (or) Shell File.
05. Autoexec.bat.

01. IO.Sys: - It initializes all input & outputs.
02. MsDos.Sys (or) Kernel File: - Main file / Kernel File.
03. Configu.Sys: - It contains, configuration information of drives in the System.
04. Command.com: - It is the shell file. It is a user interface, command interpreter.
05. Autoexec.bat: - To open Autoexec.bat
Syntax: - Edit Autoexec.bat
Example: - D:\> Edit Autoexec.bat.
It contains the series of the Dos commands that should be excuted by Dos at startup.
Prompt symbols.

 This command is used to print some special sign instead of original Prompt (D :|>)

Operation.                                                                    Symbols.

01. Less than sign (<).                                                      $L.
02. Greater than Sign (>).                                                $G.
03. Equal to Sign (=).                                                       $Q.  
04. Piping / bar sign                                                        $B.
05. Current Date.                                                             $D.
06. Current Drive.                                                            $N.
07. Current Path.                                                             $P.
08. Current Time.                                                            $T.
09. Version of Operating System.                                    $V.
10. Line feed.                                                                  $ —
11. Dollar Sign.                                                               $$.
Cursor Movement.
01. Left arrow.                           One character left.
02. Right arrow.                        One character right.
03. Up arrow.                             One line up.
04. Down arrow.                        One line down.
05. Ctrl + Left arrow.                 One word left.
06. Ctrl + Right arrow.               One word right.
07. Home button.                        Beginning of line.
08. End button.                          End of line.
09. Ctrl + Home button.              Beginning of file.
10. Ctrl + End   button.              End of file.
11. Page up button.                   One screen Previous.
12. Page down button.              One screen next.

13. Enter button.                      Start a new line.
14. Delete button.                     Delete one character at cursor position.
15. Back Space button.            Delete left character of cursor position.


     (C. U.)

Arithmetic &
Logical Unit.
     (A.L.U.)

Output device.
. Monitor.                                                                              Input device.
                                              . Mouse.
              

No comments: