Full-stack Python development-Linux Command learning and pythonlinux command
- Linux-everything is a file
- Pwd: view the current directory
- '/': Root directory
- Cd: Switch the directory eg. cd/to the root directory
- Ls: Check that the current root directory contains several disks and files.
- Ls-l: View Details (the first character is d --> directory)
- Ls-lh: user-friendly display file list
- Cd...: return to the previous directory
- Vim file name --> press enter --> I enter the insert mode input content --> Press ESC to exit --> press and hold 'shift '+': '--> enter wq and press enter to save the file and exit
- Vim. File Name: Create a hidden file
- Ls-a: Show Hidden Files
- Cat file name: view the File Content
- More file name: view the file content slowly
- Mkdir Directory: Create a new directory
- Mv file name directory name: Move the file to another directory
- Mkdir-p directory 1/directory 2/directory 3/.../: recursively create directory
- Tree directory 1: displays the tree structure of directory 1
- Man command: Query help
- Command -- help: simple help
- Help cd: view some linux built-in commands
- Cp file/directory: copy the file to the directory
- Find path-name "file name": find a file (* file name * -- fuzzy query) [query by file name]
- Find path-size + 90 M | xargs ls-lh [query by size]
- Touch path/File Name: create a file
- Rm file: delete the file (Dangerous !)
- Tar zcvf name .tar.gz file 1 file 2...: Package the file
- Free-m: View server memory usage
- Ip a: view the current ip Address
- Useradd Username: create a user
- Chown owner. group file name: Modify the owner and group of the file
- R -- read permission (4) w -- write permission (2) x -- execution permission (1) --- no permission (0)
- Chmod permission (eg.777) File Name: Modify File Permission
- Df: View linux disk usage
- Df-h: Displays disk usage in a user-friendly manner
- Top: view system performance (enter q to Exit)
- Kill process ID (PID): ends a process.
- CPU: user -- CPU occupied by user processes system -- CPU occupied by the operating system itself idle -- CPU idle rate iowait -- CPU wait io time ratio