You will learn the frequently used commands in this article for EC2 instances running the Linux/CentOS operating system.
Sl | Command | Description |
---|---|---|
1 | ls | This command helps in listing out the files and directories in the directory. |
2 | mv | This command moves the files or directories from one to another location. |
3 | cp | This command helps in copying a file. |
4 | sudo | This command is used to utilize admin privileges. |
5 | chmod | This command changes the permissions of a file |
6 | chown | This command changes the ownership of a file |
7 | rm | This command is used to remove files/directories |
8 | cat | This command is used to display the content of a file |
9 | tail | This is used to display the last part of a file. Useful on log files |
10 | find | This is used to search the given directory for name string and display it |
11 | pwd | present working directory |
12 | adduser | To create a new user |
13 | mkdir | To create a directory |
14 | nano | To bring the file in read and write mode |
15 | vi | To bring the file in read and write mode |
16 | who | Displays the currently logged on user |
17 | ps | Displays the list of currently running processes and process identifiers (PID) |
18 | uname | Displays the Installed operating system |
19 | hostname | Displays the host information. IP address and zone |
20 | kill | It terminate a running process |