+ All Categories

Dos 16

Date post: 20-Jun-2015
Category:
Upload: muhammad-ramzan
View: 1,023 times
Download: 0 times
Share this document with a friend
Popular Tags:
29
DOS
Transcript
Page 1: Dos 16

DOS

Page 2: Dos 16

DOS stands for DISK OPERATING SYSTEM and Like MS Windows, MS-DOS is operating

system.

DOS is the software program, which controls the input and output of your computer.

Unlike Microsoft Windows DOS requires the user to type commands instead of using a mouse.

DOS is a single-user, single-task operating system

Page 3: Dos 16

Brief History

MS-DOS is a non-graphical command line operating system created for IBM compatible computers.

DOS was first introduced by Microsoft in August 1981 and last updated in 1994 when MS-DOS 6.22 was released.

DOS operating system is not commonly used today.

Page 4: Dos 16

YEAR VERSION Released

1981 1.0 August, 19811982 1.25 August, 19821983 2.0 March, 1983.1984 MS-DOS 3.0 IBM PC AT

MS-DOS 3.1 For networks.1986 3.2 April, 19861987 3.3 April, 19871988 4.0 July, 19881988 4.01 November, 19881991 5.0 June, 19911993 6.0 August, 19931993 6.2 November, 19931994 6.21 March, 19941994 6.22 April, 1994

Page 5: Dos 16

DOS Files Never erase the following files, if you do the computer will most likely not start

these are called:

config.sys Loading OS & form kernel

msdos.sys System files Loading OS

io.sys System files Loading OS

command.com Command interpreter: It maintain C:\ prompt & reads user commands.

auotexec.bat Create lists of commands to run in sequence once the batch file is

executed.

Kernel is central module, it first loads OS and then remain in main memory.

Page 6: Dos 16

File Attributes (Properties)

Attributes is shortly named as attrib in DOS.

It has four different styles of file types, these are

Archive : Shows that file has not been archived yetand its attributes can be changed

System: Denotes that file is system file whatever that functions.

Hidden: It hides file from an ordinary directory.

Read Only: Write-protection, i.e file only can be read.

Page 7: Dos 16

Types of DOS

– Apple DOS For Apple Systems

– DOS Support FAT32 system

– Dr. DOS Support FAT32 & Boot Disk

– PC-DOS Support FAT32 & Boot Disk

– PTS-DOS 32 Support FAT32 system

– Real/32 DOS FAT32 & multi-tasking

Page 8: Dos 16

Command Prompt

Command Prompt is a native Windows program that lets you execute commands without using a GUI.

To open the Command Prompt. You can do this by going to Start > All Programs > Accessories > Command Prompt.

You should see a blinking cursor after a line that says C:\Documents and Settings\username. This shows that what directory you are currently in.

Page 9: Dos 16

Root & Sub Directories

Every disk you use under DOS has one main directory, called the root directory

C:\ Root Directory C:\DOS Root with sub directoryC:\DOS\NISTE Root with sub directory &

an other sub directory

Sub directory is itself a small file on hard disk.

DOS providing solution by adding sub directories to manage data or files.

Page 10: Dos 16

DOS Commands

If you want know the version of DOS just write

c:\>ver in command line prompt then the following message appears on your screen:

MS-DOS version 6.22

The ver command displays the version number of MS-DOS

Page 11: Dos 16

View contents of directoryView the contents of a directory by using the dir command. The dir command stands for "directory."

c:\>dir

A directory list appears. This is a list of all the files and subdirectories that a directory contains.

All the files and directories on your drive are stored in the root directory.

Page 12: Dos 16

Change Root directory to the DOS directory

Write cd dos in command prompt then it changes to C:\DOS>

Here command prompt shows which directory you are in.

In this case, you know you successfully changed to the DOS directory because the command prompt displays the directory's name.

Now the current directory is DOS.

Page 13: Dos 16

View the contents of a directoryc:\dirc:\dir/p The p actually stands for "page"

To view the contents on next screen of information, press any key on your keyboard. Repeat this step until the command prompt appears at the bottom of your screen. Another helpful switch you can use with the dir command is the /w, this could view the contents of a directory in wide format

c:\dir/w c:\dir/p/w

Page 14: Dos 16

Changing Back to the Root DirectoryThe root directory is the directory you were in before you changed to the DOS directory. Before you begin this section, make sure your command prompt looks like the following:

c:\DOS> cd\ No matter which directory you are in, this command always returns you to the root directory. Now it simply look like this

c:\>

c:\DOS\EDIT.COMIf you want to come back on DOS sub directory then it will write

cd.. then prompt can back it to

c:\DOS

Page 15: Dos 16

Creating a DirectoryTo create a directory, you will use the md command. The md command stands for "make directory."

C:\>md fruit You have now created a directory named FRUIT and if you want to create an other directory within the FRUIT directory named GRAPES then again write md grapes then it will look like this

C:\FRUIT\GRAPES>

To switch back to the FRUIT directory, type

cd ..

The command prompt should now look like the following: C:\FRUIT>

Page 16: Dos 16

Deleting a Directory

If you delete a Fruit directory

C:\FRUITthen use the rd command. The rd command stands for "remove directory."

just write

C:\rd fruit and press enter now fruit directory is removed and it will look like this

C:\

Page 17: Dos 16

Changing DrivesIf user writes a: then prompt will to switch drive A (Floppy Drive) and look like this

A:\> and type c:Your command prompt should return to the following:

C:\You change to that drive, when you type a drive letter followed by a colon. If you want to view files on drive A then type

dir a: A list of the files on the floppy disk will appears,

Now if you want to view the contents of the DOS directory on drive C just type

dir c:\dos A list of the files in the DOS directory now appears.

Page 18: Dos 16

Copying FilesTo copy a file, you will use the copy command. When you use the copy command, you must include two parameters. The first is the location and name of the file you want to copy (Source). The second is the location to which you want to copy the file (Destination). You separate the source and destination with a space.

Here you will copy the EDIT.HLP and EDIT.COM files from the DOS directory to the FRUIT directory, You will specify

c:\dos\edit.com c:\fruit The following message appears: 1 file(s) copied similarly

c:\dos\edit.hlp c:\fruit The following message appears: 1 file(s) copied

Page 19: Dos 16

Copying a Group of Files Wildcards is used to copy a group of files from the DOS directory

to the FRUIT directory.

C:\DOS>dir*.txt

To list all files ending with the extension TXT type

C:\DOS>dir *.txt

MS-DOS lists all the files that end with a TXT extension. The wildcard ignores different beginnings of the files and focus only on the extensions now

copy C:\DOS>dir*.txt c:\fruit

Page 20: Dos 16

Renaming Files

To rename a file, you will use the ren command. The ren command stands for "rename." When you use the ren command, you must include two parameters.

The first is the file you want to rename, and the second is the new name for the file. You separate the two names with a space. ren oldname newname

ren readme.txt peach.txt To confirm that you renamed the file successfully, type the following at the command prompt:

dir The name PEACH.TXT should appear instead of the name README.TXT.

Page 21: Dos 16

Renaming a Group of FilesAgain use wildcards to rename a group of files. To rename the files whose names begin with EDIT by using wildcards

To rename the files that begin with EDIT to the new name PEAR, type the following command: ren edit.* pear.* This command specifies that all the files that begin with EDIT should be renamed with PEAR, but extensions remains same.To confirm that you renamed the files successfully typedir pear.* When the files were renamed, their extensions remained the same. For example, EDIT.COM became PEAR.COM, and EDIT.HLP became PEAR.HLP.

If you want to rename extensions of several files then use wildcards to rename the files.

ren *.txt *.old To confirm that you renamed the files successfully, type the following at the command prompt: dir The files that had the extension TXT now have the extension OLD.

Page 22: Dos 16

Deleting FilesTo delete a file, you will use the del command. The del command stands for "delete." If you want to delete the PEAR.COM and PEAR.HLP files then type

del pear.com del pear.hlp

dir The PEAR.COM and PEAR.HLP files should no longer appears.Deleting a Group of Files To delete files in the current directory that end with the extension TXT by using wildcard. First view all the files that end with the extension TXT by typing dir *.TXT del *.TXTConfirm that all the files with the extension OLD have been deleted, type the following at the command prompt:

dir When directory is empty, you can delete it by using the rd (remove directory) command

rd directory name.

Page 23: Dos 16

Formatting a Floppy DiskIf user want to format a floppy disk then type format a: During formatting the disk, MS-DOS displays the percentage of the disk that has been formatted.

When the format is complete, the following message appears:

Volume label (11 characters, ENTER for none)?

A volume label is a name for your disk. You can give your disk any name to 11 characters.

Page 24: Dos 16

DOS Commands Here is a summary of what you can now do using the command prompt:

cd Change directorydir see a content and detail of files in the directorycopy copy a file from one location to another,

don’t forget file extension.

md Make or create a new directory rd Remove a directory & its’ contentsren Rename a file

help To see a detailed list of many commands. help /? Shows DOS help commands

chkdsk checks a diskscandisk check a disk (only if running dos 6 or 6.2 or up versions)mem shows your memory usage consumption and know about

remaining free space.

Page 25: Dos 16

cls clears the screen

date shows and allows the date to be changed

time shows and allows the time to be changed

vol show the volume label of a disk

comp compares two files

diskcomp a: b: compares two disks by several means.

*.* It means any file name and any extensionregardless of length.

*. Any file name ending with the extension dir*.bat

copy *.* copies all files

copy a:*.* c:\games

Page 26: Dos 16

dir/w directory wide across the screen

dir/p directory pause a page at a time

dir/w/p wide and pause directory

dir/o directory in order of alphabetic

dir/w/o/p All the above commands together (directory, wide, order, paused)

dir *.exe directory of files ending .exe

dir *.bat directory of files ending .bat

dir *.COM directory of files ending .com

dir t*.* directory of files beginning with the letter t

dir ta*.* directory of files starting ta

dir /s directory show file size

dir /s *.txt Files with txt extension will be display in full size.

Page 27: Dos 16

Format Commands

format would not format a disk

format a: format drive a:

format b: format drive b:

format a: /u formats without saving a mirror image/backup.

format a: /q supplies a quick format

format a: /u /q Formats quick and without backup

format a: /s makes a bootable system disk

Page 28: Dos 16

Delete commands

del delete a file (don’t forget to include the file extension)

del *.* Removes all files but not directory or sub directories.

RD Removes an empty sub directory

Deltree Removes a directory sub directories and all files within them.

UNDELETE: Accidentally erased file can be retrieved

Page 29: Dos 16

10 most useable Commands Top 10 DOS commands most commonly used in

all versions.

1. cd Chang directory

2. dir Contents of directory3. copy Copy files/contents4. del remove file(s)5. edit change file(s)6. move cut file(s)7. ren rename file(s)8. deltree remove directory and sub directories

9. cls clear screen10. format clear and form a floppy or disk


Recommended