Monday, 6 March 2017

Command Line Commands - Linux and DOS


http://comptia-microsoft-it-training-dublin.blogspot.ie/2017/03/command-line-commands-linux-and-dos.html














Before Graphical User Interfaces, operating a computer was done via text based commands and prompts. MS-DOS was an operating system which seemed to just sit waiting, its cursor blinking, eager for a line of input from the user who would first have to know what could be done and second, how exactly to go about doing it. Unlike a modern OS which is today designed to feel intuitive,  like some comfy room in your house, navigating folders in MS-DOS was too logically order your way through hierarchical paths and while for most, Control Panel settings windows are even perhaps one step too far into the dark basement of options and configurations, useful is it to know the command prompt window which is still commonly used by IT professionals to troubleshoot issues. 
 
Below is a list of some Windows Commands…
DIRECTORY ACCESS & NAVIGATION               

o   DIR
                                View Drive Directory

o   TREE
                                Displays Directory Listings

o   CD C:\
                                Access C Directory.

o   CD C:\users\username\desktop
                                Access Path.

o   CD..
                                To go back one Directory.

o   CD\       
                                Go to the Root of the Drive.

o   CHDIR  
                                Synonymous with CD.

o   MD Test
                                Create a (Test) directory within  the current Directory.

o   MKDIR “Paris Holiday”
                                Creates a (Paris Holiday) directory.
                                Quotation Marks required for a file name with a space.

o   MD C:\Barcelona
                                Creates the (Barcelona) directory within the C Drive.
 
FILE OPTIONS
o   COPY Galway.txt C:\users\username\desktop
                                Move (Galway.txt) File to Desktop.
                                First ensure your within the correct directory.

o   RENAME Galway.txt BALLINDOOLEY.TXT
                                Rename (Galway.txt) File.

o   MOVE Ballindooley.txt C:\users\username\libraries\documents
                                To transfer (Ballindooley.txt) File into the Documents Folder.

o   DEL Ballindooley.txt
                                Delete (Ballindooley.txt) File when within current Directory.

o   DEL C:\ users\username\libraries\documents\Ballindooley.txt
                                Delete (Ballindooley.txt) File.

o   COPY CON Rome.txt
                                Create (Rome.txt) within Directory.

o   FIND/?
                                Find Options List.

o   FIND “colosseum” Rome.txt
                                Search for word within document.

o   ATTRIB +h Rome.txt
                                Makes (Rome.txt) File hidden.
                                ATTRIB –h Rome.txt

o   ATTRIB  +r Rome.txt
                                Makes (Rome.txt) File Read-Only.
                                ATTRIB –r Rome.txt

o   ATTRIB/?
                                Attributes Option List. 

NETWORKING
o   IPCONFIG
                                Display Network Settings.

o   IPCONFIG /ALL
Display Detailed Configuration Data.

o   IPCONFIG /RELEASE
                                Release IPv4 address.

o   IPCONFIG /RENEW
                                Renew IPv4 address.

o   IPCONFIG /DISPLAYDNS
                                Display contents of the DNS Resolver Cache.

o   ARP –A
                                Display all ARP entries.

o   NBTSTAT
                                Displays Protocol Statistics

o   PING  <ip address>
                                Utility to check for errors on the network

o   TRACERT <ip address>
                                Examine the path of Packets in-transit

o   NETSTAT
                                Display Local Network Information

o   HOSTNAME
                                Display Computer Hostname                               

MISC

o   CLS
                                Clear Screen

o   CHKDSK
                                Check Drive for errors

o   DEFRAG
                                Disk Defragment Utility

o   DISKPART
                                Disk Partition

o   LOCK C:
                                Lock Drive

o   LOGOFF
                                Computer Log-off

o   ROBOCOPY
                                Copy Files, Drives & Directories

o   SYSTEMINFO
                                Display System Information

o   TIME 11:13
                                Change Time (11:13)

     Open Web Page             

 WINDOWS COMMANDS COMPARED TO LINUX COMMANDS




DOS COMMAND

LINUX COMMAND

CD

CD

CHDIR

PWD

DIR

LS

MKDIR

MKDIR

CLS

CLEAR

FORMAT

MKE2FS   or   MFORMAT

COPY

CP

EDIT

VIM
 

MOVE

MV
 





 

No comments:

Post a Comment