Common commands in Linux

Source: Internet
Author: User

I. Common commands in Linux: file and directory operations
Basename: remove the path and extension from the file name
Cd: Switch the current working directory to the specified directory
Chgrp: Change the group to which the file belongs.
Chmod: Change File Permissions
Chown: Change the file owner and group
Cp: copy a file or directory
Dd: Copy and convert the File Content
File: determines the file type.
Find: find the file in the specified directory and perform the specified operation
Ln: create a file link
Locate/slocate: Quickly locates the file path
Ls/dir/vdir: displays the directory content
Mkdir: create a directory
Mv: Move or rename a file
Pwd: displays the current working directory
Rename: rename a file
Rm: delete a file or directory
Rmdir: delete an empty directory.
Touch: modifies the time attribute of a file.
Updatedb: Creates or updates a slocate database.
Whereis: displays the Instruction Program, source code, and man manual pages.
Which: displays the absolute path of a command.

Ii. Common commands in Linux: Backup and Compression
Ar: create, modify, and extract files from an archive file
Arj:. arj File compression instruction
Bunzip2: compress bzip2 files
Bzcat: Extract files to standard output
Bzip2: Create a. bz2 compressed file
Bzip2recover: repair the damaged .bz2 File
Bzless/bzmore: Decompress the. bz2 file and display the content on the split screen.
Compress: compress data files
Cpio: access files in an archive
Dump: File System Backup
Gunzip: Decompress the file compressed by gzip
Gzexe: compress executable programs
Gzip: GNU compression and decompression tool
Lha: compression and decompression commands
Resotre: Restore the file or file system backed up by dump
Tar: Creates a backup file.
Unarj: extract the. arj File
Uncompress: Decompress the. Z File
Unzip: Decompress the. ZIP file
Zcat: Decompress the file and send it to the standard output.
Zforce
Zip: compressed file
Zipinfo: displays details of zip files.
Znew: convert a. zw.gz file to a. GZ file.

Iii. Common commands in Linux: Text Processing
Cat: link the file and display it to standard output
Cksum: checks and computes file Cyclic Redundancy checksum.
Cmp: Compare the differences between two files
Col: filter control characters
Colrm: filters out the specified columns from the input.
Comm: Compare the differences between two ordered files
Csplit: Split files
Cut: display the specified content of each row in the file
Diff3: Compare the differences between the three files
Diff: Compare and display the differences between the two files
Diffstat: displays statistics based on the diff command results.
Ed: Line Text Editor
Emacs: full-screen text editor
Ex: Text Editor
Expand: convert a Tab to a blank Space)
Fmt: optimized text format
Fold: Set the row width displayed in the file.
Grep/egrep/fgrep: displays matching rows in the file.
Head: content starting with the output file
Ispell: Interactive spelling check program
Jed: Text Editor
Joe: edit a text file
Join: Merge the same fields of two files.
Less: view text files on a split screen
Look: displays the lines starting with a specific string in the file.
More: view text files on a split screen
Od: output file content in digital encoding
Paste: merged File Content
Pico: Text Editor
Sed: stream file editor
Sort: sort data files
Spell: spell check
Split: split files
Sum: calculates and displays the file verification code.
Tac: display file content in reverse order
Tail: content at the end of the output file
Tee: Copies the input content to the standard output and specified files.
Tr: Convert or delete characters in a file
Unexpand: Convert blank Space to Tab
Uniq: delete duplicate rows in the file.
Vi: full-screen text editor
Wc: number of bytes, number of words, and number of lines of computing files

4. Common commands in Linux: shell commands
Alias: defines the command alias
Bg: Put the job (or task) in the background for running
Bind: display or set keyboard Configuration
Declare: Declares shell Variables
Dirs: displays records in the shell directory stack.
Echo: print the string to the standard output.
Enable: activates and disables shell internal commands.
Eval: executes the specified command and returns the result.
Exec: log out after executing the given command
Exit: exit the current shell.
Export: Set and display environment variables
Fc: Edit and execute History commands
Fg: Switch the background task (or job) to the foreground for running.
Hash: displays and clears the hash table used for row query.
History: commands for displaying and manipulating history
Jobs: displays shell job information.
Kill: kill processes or jobs
Logout: log out of shell
Popd: delete records from the shell directory Stack
Pushd: Add a record to the shell directory Stack
Set: set the shell execution method.
Shopt: Set the switch value for controlling shell behavior Variables
Ulimit: Set shell resource limits
Umask: sets the permission mask for creating files.
Unalias: cancels the alias of a command defined by alias.
Unset: deletes a defined variable or function.

5. Common commands in Linux: printing related commands
Accept: accept the print request
Cancel: cancels the print task.
Disable: Stop the printer
Enable: Start the printer
Lp: print files
Lpadmin: Configure cups printers and Classes
Lpc: printer Control
Lpq: displays the current print queue
Lpr: print files
Lprm: delete jobs in the current print queue
Lpstat: displays the status information of CUPS.
Pr: convert text format before printing
Reject: reject the print request

6. Common commands in Linux: other basic commands
Bc: calculator for Accurate Calculation
Cal: Display calendar
Clear: clear screen command
Consoletype: displays the currently used terminal type
Ctrlaltdel: Set the shortcut key Ctrl + Alt + Del.
Date: displays and sets the system date and time.
Dircolors: Set the color of the ls command.
Eject: the media of the Removable device is displayed.
Halt: Disable the computer
Hostid: displays the digital ID of the current host.
Hwclock: Query and set the system hardware clock
Info: Read help document
Login: log on to the system
Man: displays the online help manual.
Md5sum: calculates and displays the md5 Summary of the file.
Mesg: Set the terminal write permission
Mtools: displays the commands of the mtools package.
Mtoolstest: Test and display mtools toolkit configurations
Poweroff: power off the computer
Reboot: restart the computer
Shutdown: shut down the computer
Sleep: sleep for a specified period of time
Stat: displays the status of a file or file system.
Talk: talk with other users
Wall: send messages to all terminals
Whatis: Query keywords in the database
Who: displays information about the currently logged-on user
Whoami: displays the current user name
Write: sends information to a specified user terminal.
Yes: the specified string is output continuously.

7. Common commands in Linux: User Management
Chfn: Change the user's finger information
Chsh: Change the default shell for user logon.
Finger: User Information Query Program
Gpasswd: Management group file/etc/group
Groupadd: Creates a group.
Groupdel: deletes a group.
Groupmod: Modify group information
Groups: displays the group to which the user belongs.
Grpck: verify the integrity of the group file/etc/group
Kgconv: Enable the shadow password file of the group.
Grpunconv: Disable the shadow password file of the group.
Logname: displays the logon User Name
Passwd: Set the User Password
Pwck: verify the integrity of the User File Password File
Pwconv: enable the user's shadow password file
Pwunconv: Disable the shadow password file.
Su: Switch users
Useradd: create a user
Userdel: delete a user
Usermod: Modify user configuration information
Users: displays the User Name of the current logon system.

8. Common commands in Linux: Process Management
Init: process initialization Control
Killall: end the process by name
Nice: Set process priority
Nohup: run the program by ignoring the suspended Signal
Pgrep: query by name and display the process number
Pidof: Find the process Number of the running program
Pkill: sends a signal to a specified process
Ps: displays the current process status of the system.
Pstree: displays the parent-child relationship of a process using a tree worker.
Renice: Adjust process priority
W: displays information about the current logon user.
Watch: Displays output information of a specified command in full screen mode.

9. Common commands in Linux: disk and file system management
Badblocks: Disk Bad block check tool
Blockdev: Call the ioctl function of the block device from the command line.
Chattr: modifies the 2nd extension file system attributes of a file.
Convertquota: Convert the quota File Format
Df: Report the remaining disk space
Dumpe2fs: displays ext2/ext3 File System Information
E2fsck: Check the ext2/ext3 File System
E2image: saves the ext2/ext3 source data to the file.
E2label: sets the ext2/ext3 file system label.
Edquota: edit a user's disk space quota
Fdisk: partition tool in Linux
Findfs: Find a File System
Fsck: checks and fixes Linux File Systems
Grub: Boot Loader in Linux
Hdparm: adjusts hard disk I/O performance
Lilo: Linux Loader
Lsattr: displays the ext2 file system attributes of a file.
Mkbootdisk: Creates a dedicated boot floppy disk for the current system.
Mke2fs: Create a 2nd extended File System
Mkfs: create various file systems
Mkinitrd: Create and initialize a ram disk image file
Mkisofs: Creates a CD image file.
Mknod: Creates a block device or character device file.
Mkswap: Creates a swap partition file system.
Mktemp: create a temporary file
Mount: load the File System
Parted: disk partition management tool
Quota: displays the user's Disk quota
Quotacheck: creates, checks, and fixes quota files.
Quotaoff: Disable the disk quota function of the file system.
Quotaon: Enable the disk quota function of the file system.
Quotastat: displays the disk quota status.
Repquota: displays the File System Disk Quota INFORMATION REPORT
Swapoff: Disable swap space
Swapon: Activate swap space
Sync: Write cached data to disk forcibly
Tune2fs: adjust the parameters of the ext2/ext3 File System
Umount: unmount the mounted file system

10. Common commands in Linux: kernel and Performance
Depmod: processes the dependency between modules that can be loaded in the kernel.
Dmesg: displays the output information of the kernel.
Free: displays memory usage
Insmod: Load modules to the kernel
Iostat: Report the CPU, I/O device, and partition status
Ipcs: displays the status information of inter-process communication.
Kernelversion: displays the main kernel version.
Lsmod: displays loaded modules.
Modinfo: displays kernel module information
Modprobe: load the kernel module and resolve Dependencies
Mpstat: displays process-related status information.
Rmmod: delete a module from the kernel
Sar: Collects, displays, and saves system activity information.
Slabtop: displays the slab cache information of the kernel in real time.
Sysctl: Modify Kernel Parameters during runtime
Tload: monitor the average system load
Top: Display and Manage System Processes
Uname: displays system information.
Uptime: displays the system running time and average load.
Vmstat: displays the virtual memory status.

11. Common commands in Linux: X-Window System
Startx: initializes an X-Window session.
Xauth: X system license file management tool
Xhost: displays and configures the access permissions of the X server.
Xinit: X-Window system initialization program
Xlsatoms: Displays X Server atomic data definitions
Xlsclients: displays the X program running on the specified display.
Xlsfonts: displays the font information used by the X server.
Xset: Set the user preference attribute of X System

12. Common commands in Linux: System Security
Chroot: run commands in the specified root directory
Nmap: network detection tools and Security Scanners
Scp: an encrypted remote replication tool
Sftp: Secure File Transfer Tool
Slogin: an encrypted remote logon Tool
Ssh: an encrypted remote logon Tool
Sudo: execute commands as another user

13. Common commands in Linux: programming commands
Awk/gawk: Mode Scanning and processing language
Expr: calculates the expression value.
Gcc: gnu c language compiler
Gdb: GNU Debugger
Ldd: displays shared library dependencies.
Make: An engineering compilation tool
Nm: displays the symbol table of the target file.
Perl: a command line tool in the perl language
Php: PHP script language command line interface
Test: conditional test

14. Common commands in Linux: management and maintenance commands for other systems
Arch: displays the hardware architecture of the current host.
At: scheduled task execution
Atq: query the tasks to be executed
Atrm: Delete the task to be executed
Batch: run the task at the specified time
Chkconfig: sets the services executed by the system under different running levels.
Crontab: Schedule Tasks by Time
Last: displays information about users who have logged on to the system before.
Lastb: displays information about users who failed to log on to the system.
Logrotate: A rotation tool for system logs.
Logsave: Save the output information of the command to the log file.
Logwatch: reporting and analyzing system logs
Lsusb: Display All USB devices
Patch: patch and update files
Rpm: Red Hat Software Package Manager
Runlevel: displays the running level of the current system.
Service: Linux service management and control tools
Telinit: switches the running level of the current system.
Yum: RPM Software Package automated management tool

15. Common commands in Linux: Network Configuration
Dnsdomainname: displays the system's DNS domain name
Domainname: displays and sets host domain names
Hostname: displays or sets the system Host Name.
Ifcfg: Configure Network Interfaces
Ifconfig: configure network parameters for network interfaces
Ifdown: Disable the specified network interface
Ifup: starts the specified network interface
Nisdomainname: displays and sets the host domain name
Route: displays and operates the IP route table of the local machine.
Ypdomainname: displays and sets the host domain name

16. Common commands in Linux: network testing and application
Arp: manages local arp buffer
Arping: sends arp request packets to neighboring hosts
Arpwatch: monitors ARP information on the network.
Dig: domain name query tool
Elinks: plain text Web Browser
Elm: email client program
Ftp: File Transfer Protocol Client
Host: DNS domain name query tool
Ipcalc: IP Address Calculator
Lynx: plain text Web Browser
Mail: email management program
Ncftp: enhanced FTP client Tool
Netstat: displays the network status.
Nslookup: DNS domain name query tool
Pine: email and newsgroup Handler
Ping: test whether the network reaches the target host.
Rsh: Remote shell
Telnet: Remote logon Tool
Tftp: simple File Transfer Protocol Client
Tracepath: route used to track data
Traceroute: route used to track data packets arriving at the target host
Wget: download an object from a specified URL

17. Common commands in Linux: Advanced Network commands
Arptables: ARP rule table for Kernel Management
Ip: Powerful Multi-Function Network Configuration Tool
Iptables: an IP packet filtering and NAT management tool
Iptables-save: save the iptables configuration in the kernel
Iptables-restore: restores the configuration information of iptables.
Tcpdump: listening for network traffic

 

Common commands in Linux: network server commands
AB: Web server performance test
Apachectl: Apache HTTP Server Control Interface
Exportfs: Manages file systems shared by NFS servers
Htdigest: manage user files used for digest Authentication
Htpasswd: manage user files for Basic Authentication
Httpd: Apache Hypertext Transfer Protocol server
Mailq: displays the message queue to be sent.
Mysql: client tool of the MySQL server
Mysqladmin: MySQL Server Management Tool
Msqldump: MySQL Server Backup Tool
Mysqlimport: MySQL Database Import Tool
Mysqlshow: displays MySQL database, table, and field information
Nfsstat: displays the Network File System Status
Sendmail: Email Delivery agent
Showmount: displays the loading information on the NFS server.
Smbclient: samba Server Client Tool
Smbmount: load the samba File System
Smbpasswd: Change samba User Password
Squid: HTTP Proxy server program
Sshd: OpenSSH daemon

 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.