Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
0% found this document useful (0 votes)
10 views

DOS-Commands-Linux-Commands

The document provides an overview of essential DOS and Linux commands for file management, navigation, and system control. It includes descriptions of key commands such as ls, pwd, cd, mkdir, cp, mv, rm, and others in Linux, as well as top MS-DOS commands like cd, dir, copy, and del. The objective is to enhance efficiency in command-line environments and develop troubleshooting skills using these commands.

Uploaded by

Micco Nanong
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
10 views

DOS-Commands-Linux-Commands

The document provides an overview of essential DOS and Linux commands for file management, navigation, and system control. It includes descriptions of key commands such as ls, pwd, cd, mkdir, cp, mv, rm, and others in Linux, as well as top MS-DOS commands like cd, dir, copy, and del. The objective is to enhance efficiency in command-line environments and develop troubleshooting skills using these commands.

Uploaded by

Micco Nanong
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 29

DOS Commands &

2
Linux Commands
objectives
1. Understand the Basics: Learn the
fundamental DOS and Linux commands for file
management, navigation, and system control
to enhance efficiency in command-line
environments.

2. Practical Application: 3. Troubleshooting Skills:


Develop the ability to Acquire the skills to diagnose
execute complex tasks and resolve system issues
using DOS and Linux using command-line tools,
commands, including improving overall system
scripting and automation management.
to streamline workflows.
LINUX
commands
The ls command in Linux

The ls command is used to list files and directories in the current working directory, using
the command by itself without any arguments will give us an output with all the files and
directories in the directory. The command offers a lot of flexibility in terms of displaying the data
in the output.
The pwd command in Linux

The pwd command allows you to print the current working directory on your terminal.
Now, your terminal prompt should usually have the complete directory anyway. But in case it
doesn’t, this can be a quick command to see the directory that you’re in. Another application of
this command is when creating scripts where this command can allow us to find the directory
where the script has been saved.
The cd command in Linux

The cd command is one of the important Linux commands you must know, and it will
help you navigate through directories. Just type cd followed by directory, as shown below.
The mkdi command in Linux
r

The mkdir command allows you to create directories from within the terminal.
The cp & mv command in
Linux
The cp and mv commands are equivalent to the copy-paste and cut-paste
commands in Windows. But since Linux doesn’t really have a command for renaming
files, we also use the mv command to rename files and folders.
The r command in Linux
m

The rm command is used to delete files and folders and is one of the important
Linux commands you must know. To delete a directory, you must add the -r argument to
it. Without the -r argument, the rm command won’t delete directories.
The touch command in Linux

The touch command in Linux creates an empty file or updates the timestamp of
an existing file.
The In command in Linux
To create a link to another file, we use the ln command. This is one of the most
important Linux commands that you should know if you’re planning to work as a Linux
administrator.

The -s flag creates a symbolic link (also known as a symlink or soft link) to a file or
directory. A symbolic link is a special type of file that acts as a shortcut or pointer to
another file or directory.

By default, the ln command will make hard links instead of symbolic or soft links.
The clear command in Linux
The clear command in Linux clears the terminal screen. It removes all the text
and output currently displayed on the terminal and gives you a clean slate to work with.
The cat ,echo &les command in
s
When youLinux
want to output the contents of a file or print anything to the terminal output,
we use the cat or echo commands. Let’s see their basic usage.

the cat command, when used on our New-File, prints the contents of the file. At the same
time, when we use echo command, it simply prints whatever follows after the command.

The less command is used when the output printed by any command is larger than the
screen space and needs scrolling. The less command allows the user to break down the
output and scroll through it with the use of the enter or space keys.
The man command in Linux
The man command is a very useful Linux command one must know. When working with Linux, the
packages that we download can have a lot of functionality. Knowing it all is impossible.

The man command in Linux is used to display the manual page for a specific command. It provides
detailed information about the command, including its syntax, options, and examples.

Here’s an example of how to use the man command:

1.Open a terminal and type man ls to display the manual page for the ls command.

This will display a page that looks something like this


The uname & whoami command in
Linux
The uname and whoami commands allow you to access some basic information that comes in handy when you
work on multiple systems.

The uname command in Linux displays information about the system’s kernel, including the kernel name,
hostname, kernel release, kernel version, and machine hardware name.

The whoami command in Linux returns the current user’s username. It stands for “who am I?” and it’s often used
to determine the current user’s identity in shell scripts or the terminal.

Let’s see the output of both the commands and the way we can use these.
This will display a page that looks something like
this:
DOS commands are instructions used in the Disk Operating System (DOS) for managing
files and executing programs, primarily in Windows environments. Linux commands
serve a similar purpose in Linux operating systems, enabling users to interact with the
system, manipulate files, and manage processes through a powerful command-line
interface.

DOS and Windows command line top 10 commands

MS-DOS and Windows command line Below is a listing of the top 10 MS-DOS commands most commonly used and
are most likely be using during a normal DOS session.

1. Cd
2. Dir
3. Copy
4. Del
5. Edit
6. Move
7. ren (rename)
8. Deltree
9. Cls
10. format
CD (change directory) is a command used to switch directories in MS-DOS and the
Windows command line.
The dir command displays information about files and directories, and how much
disk space is available. By default, it displays the name, size, and last modification time
of every file in the current directory.
The copy command allows users to copy one or more files to an alternate location.
The del command is used delete files from a computer.
The MS-DOS text editor, edit, lets you view, create, or modify any text file on your
computer. While running edit, a screen similar to the picture below is shown.
The move command allows users to transfer files or directories from one directory to
another, or from one drive to another.
The ren and rename commands change the name of files and directories.
Short for delete tree, deltree is a command used to delete files and directories
permanently from a computer.
The cls (clear screen) command allows users to clear all the contents on the screen and
leave only a prompt.
The format command is used to erase information from a computer diskette or fixed
drive.
REFERENCES
https://www.computerhope.com/dostop10.htm

https://www.digitalocean.com/community/tutorials/linux-commands

THANK YOU!!!

You might also like