29 basic Linux commands that O&M engineers must know for you to learn

Although the Linux distribution supports a variety of graphical user interfaces, the Linux command line interface (bash) is still simple and fast in some cases. Bash and Linux Shells require input commands to accomplish tasks and are therefore called command line interfaces.

Commands are instructions for computers to perform tasks. You can use commands to shut down the computer, or list the current directory's file list, or the contents of the current text, or display a message on the screen.

If you are a newbie and try to use the command line interface, we have collected a variety of basic Linux commands for you to learn and help you complete various tasks in various Linux distributions. Although not very detailed, it is very useful for Linux beginners, ordinary fire, or administrators.

1.ls - List

Ls will list the contents of the current working directory (file or folder) just as you would open a folder in the GUI to see what's inside.

2.mkdir – Make Directory

Mkdir Common new directory

3.pwd – Print Working Directory

Pwd shows the current working directory

4.cd - Change Directory

For the current running session in the terminal, cd Sets the given folder (or directory) to the current working directory.

5.rmdir – Remove Directory

Rmdir Delete the given directory.

6.rm - Remove

Rm Will delete the given file or folder, use rm -r Recursively delete folders

7.cp - Copy

Cp Command to copy a file or folder, use cp -r Options to recursively copy folders.

8.mv – MoVe

Mv The command moves the file or folder, and if the file or folder exists in the current working directory, the file or folder can also be renamed.

9.cat – concatenate and print files

Cat Used to view the contents of the file on standard output (monitor or screen).

10.tail – print TAIL (from last) >

Tail By default, the last 10 lines of the given file are displayed on the standard output. You can use tail -n N Specifies to display the last N lines of the file on standard output.

11.less – print LESS

Less Print the contents of the file by page or by window. It is very useful and efficient when viewing large files containing large amounts of textual data. You can use Ctrl+F to page forward and Ctrl+B to page backward.

12.grep

Grep " "" Search for the specified string in the given file. Grep -i " "" The case of the string is ignored when searching, and grep -r " "" You will recursively search for the specified string in the current working directory file.

13.Find

This command will search for a file that matches the criteria at a given location. You can use find -name -name option for case-sensitive searches, find -iname To perform case-insensitive searches.

Find -iname

14.tar

The tar command can create, view, and extract tar archives. Tar -cvf Is to create the corresponding compressed file, tar -tvf To view the corresponding compressed file, tar -xvf To extract the corresponding compressed file.

15.gzip

Gzip Command to create and extract gzip archives, also use gzip -d Extract the compressed file.

16.unzip

Unzip Extract the gzip file. Unzip -l can be used before unzipping Command to view the contents of the file.

17.help

--help will list all available commands on the terminal. You can use the -h or -help options of any command to see the specific usage of the command.

18.whatis - What is this command

Whatis A single line will be used to describe the given command.

19.man – Manual

Man A manual page will be displayed for the given command.

20.exit

Exit is used to end the current terminal session.

21.ping

Ping Ping a remote host (server) by sending a packet, which is commonly used to detect network connections and server status.

22.who – Who Is logged in

Who can list the currently logged in user name.

23.su – Switch User

Su Used to switch different users. Even without a password, superusers can switch to other users.

24.uname

Uname will display important information about the system, such as the kernel name, host name, kernel version, handler type, etc. Use uname -a to see all the information.

25.free – Free memory

Free will show the system's free memory, occupied memory, available swap memory and other information, free -m will convert the result to KB, and free -g will be converted to GB.

26.df – Disk space Free

Df Checks the use of the disks in the file system – the used and available storage space of the hard disk and other storage devices. You can use df -h to display the result in human-readable form.

27.ps - ProcesseS

Ps shows the progress of the system.

28.Top - TOP processes

The top command will default to the CPU usage and display the larger process. You can use top -u View a user's CPU usage rankings.

29.shutdown

Shutdown is used to shut down the computer, and shutdown -r is used to restart the computer.

Insulated Copper Tube Terminals

Insulated Copper Tube Terminals,High quality insulated terminal,copper tube terminal

Taixing Longyi Terminals Co.,Ltd. , https://www.longyicopperlugs.com