Basic Linux commands and basic linux commands
The following are my notes on linux.
First, let's get familiar with it: DNS is used to resolve domain names; the default url port is 80, which can be left blank; localhost is 127.0.0.1. If it is root, the prompt is :#, for normal users: $;
Common commands in Linux:
1. when viewing the users logged on to the current system, you can enter the whoami command. If you want to view the total number of users in the system, you can view them in the/home path;
2. view the current system ip address. You can enter ip address,
3. Modify the temporary IP address. You can enter ifconfig eth0 169. 254. *. *, but it becomes invalid after restart;
4. netstat-nlpt | grep 80: Check whether the port number is occupied;
5. ps-ef | grep mysql ps-ef searches for matching rows in the grep display file of the process; ps-ef | grep httpd | grep-v "grep"-v is used to exclude grep processes. ps is instantaneous and top is dynamic.
6. When modifying environment variables, remember to write $ PATH:. When I installed tomcat in linux, I forgot to write $ PATH:. As a result, an error is reported during system startup,
7. cd .. back to the upper-level directory, cd .. /.. /.. go back to the upper-level directory, cd-Go back to the directory of the last operation, knowing that these commands are much easier to switch back and forth directories.
8. scp command is to copy the transfer file between two machines, Here reference a big blog to introduce, http://www.cnblogs.com/peida/archive/2013/03/15/2960802.html personal feeling write very good!
9. file Permission Description: dr-xr-x --- d indicates a directory. If this location is-, it indicates a file 'r-x' indicates the user's permission, the second 'r-x' indicates the permissions of this group, and the third group '---' indicates the permissions of other users. You can use the chmod command to grant permissions. [N] [n] [n] r = 4 w = 2 x = 1, for example, rwx = 4 + 2 + 1;
10. The linux learning method is to practice more, practice more, and familiarize yourself with Common commands, so that you can improve your understanding!
11. As a beginner in linux, remember to back up the configuration file when modifying it. Remember to remember it!