In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-09-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/01 Report--
This article shows you how to use commands in three modes of the Linux system. The content is concise and easy to understand. It will definitely brighten your eyes. I hope you can get something through the detailed introduction of this article.
1. Three modes: bottom line mode, command mode, insert mode.
Command mode:
1. Switch the insert mode from the command:
I: enter I on the left side of the cursor and move the cursor to the leftmost line
O: the next line of cursor movement (new line) O: the previous line of cursor movement (new line)
A: if the cursor moves to the right of the line, enter A: the cursor moves to the right of the line
2. Copy: (n stands for number)
Line: nyy n > 0
Word: nyw n > 0
3. Paste: P
4. Undo to the previous step: U
5. Restore to the previous step: ctrl+r
6. Replace:
Replace one character: r
Continuous replacement: r
7. Locate the line:
Above: n-
Below: n +
8. Delete:
Delete characters: nx (right) nX (left) n > 0
Delete line: ndd ndiary N1 dd
9. Find the keyword: / key_value (look down for key:n and stop for key:N)
Bottom line mode:
1. Display line number: set nu
2 、
2. Read the contents of the text document: cat/more
3. The "permissions" of the file to a "user" operation:
Permissions: r readable read 4 w writable write 2 x executable excude 1
Users: create u group g other people o
Modify permissions:
Chmod user +,-permissions 1, user +,-permissions 2 files
-rw-r--r--. 1 LF LF 210 July 7 10:27 msg.data
(see figure 1)
Remove the creator's read permission
Chmod Umurr _ r _ gripr _ r _ r _ r file
Increase permissions:
Chmod uprir _ r _ file
Delete / add everyone
Chmod a Mustang + permissions file
Each user: 4 read 2 write 1 execute 4 "2" 1 "7 4" 0 "0" 4 (read-only) 4 "2" 0 "6 (read and write cannot be executed)
Chmod-File
4. User: (characteristics: 1 multitasking (process) multiuser operation)
1. Switch user name: su user name
2. Add users: useradd (root permission)
3. Modify password: passwd password (passworld)
Note: user home directory (/ home)
5. Assign the permission of root to the user's command:
Some of the permissions assigned to users by root are recorded in: / etc/sudoers
Note: every sudo will check the user's allocation policy in / etc/sudores.
1. Assign permission to a certain command to a user on a machine
1.1 assign all commands for all machines to the user
User name ALL= (ALL) ALL
1.2 assign a command for all machines to the user
User name ALL= (ALL) command
6. Compiler: translates a specified language into a machine language
The history of language development:
1. Machine language: an instruction consisting of 0ram 1 (which can be directly recognized by the computer)
2. Assembly instructions: use mnemonics instead of binary instructions
3. High-level language: communicate with machines in natural language
Compiler of Linux: gcc/g++/QT
Gcc compiler: it is an excellent compiler (1, many compiled languages, 2, high quality)
Source program: a file of a program written in a high-level language
C language: .c
C++ language: .cpp .C
Java: .java
OC: .oc
Compile:
1. Gcc source program. C Note: if no executable file name is specified, a.out is generated by default.
2. Specify the executable file name:
Gcc source program. C-o executable file name
Execute program: path / program name
[3. Compilation process: (function)]
What is Linux system Linux is a free-to-use and free-spread UNIX-like operating system, is a POSIX-based multi-user, multi-task, multi-threaded and multi-CPU operating system, using Linux can run major Unix tools, applications and network protocols.
The above is how to use commands in the three modes of the Linux system. Have you learned any knowledge or skills? If you want to learn more skills or enrich your knowledge reserve, you are welcome to follow the industry information channel.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
The market share of Chrome browser on the desktop has exceeded 70%, and users are complaining about
The world's first 2nm mobile chip: Samsung Exynos 2600 is ready for mass production.According to a r
A US federal judge has ruled that Google can keep its Chrome browser, but it will be prohibited from
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
About us Contact us Product review car news thenatureplanet
More Form oMedia: AutoTimes. Bestcoffee. SL News. Jarebook. Coffee Hunters. Sundaily. Modezone. NNB. Coffee. Game News. FrontStreet. GGAMEN
© 2024 shulou.com SLNews company. All rights reserved.