Linux command 20,191,110

Linux command :

/bin Binary is the abbreviation This directory is the most frequently used commands
/sbin s is the Super User hypervisor mean, here storage system administrators
/home Store home directories ordinary users, each user has their own directory in Linux, the directory is usually the user's account name
/root The catalog for the system administrator, who is also known as super user's home directory permissions
/lib Power systems need the most basic dynamic link shared libraries, its role is similar to Windows DLL files inside. Almost all applications need to use these shared libraries
/etc All of the systems management needs of configuration files and subdirectories
/usr This is a very important directory, many applications and user files are placed in this directory, similar to the program files directory under Windows
/boot Here are some of the core stored in files that are used when you start Linux, including some connection files and image files, do not put your installation here
/proc This directory is a virtual directory, which is the system memory map, we can get system information directly access this directory by
/sys Servic abbreviation of the directory to store some of the data to be extracted after the service starts
/has This directory is used to store temporary files
/dev Similar to the Windows Device Manager, all the hardware in the form of file storage
/media Linux system will automatically identify some devices, such as U disk, CD-ROM, etc., after the identification, the identification device Linux will mount this directory
/ mnt Linux system will automatically identify some devices, such as U disk, CD-ROM, etc., after the identification, the identification device Linux will mount this directory
/opt This is for the host to install additional software placed in the directory. For example, you install a MySQL data you can put this directory. The default is empty.
/where This directory contains a constantly expanding with something we were used to modify those directories are often placed in this directory. Including log files
/selinux Selinux is a safe from the system, it can control the program only access to specific files
/lost+found Empty this directory Normally, when the system is shut down illegal, some files stored here

VI / VIM editor
VI is the Unix operating system and Unix operating system is the most common text editor.
VIM editor is developed from a more powerful VI text editor.
You can take the initiative to identify the grammatical correctness font color for easy programming.
VIM is fully compatible with the VI editor.
General pattern to open a vi file directly into the general pattern of the (this is the default mode).
In this mode, you can use the "up and down" button to move the cursor, you can use the "Delete character" or "delete the entire line" to handle the contents of the file, you can use "Copy, Paste" to handle your data file .

grammar Functional Description
yy Copy the current cursor line
Digital y y Copy the period (from a few lines to a few lines)
p Paste line arrow to the object
in Undo the last step
dd Delete current line cursor
Digital d d How many lines after the cursor is deleted (including)
x To delete a letter, equivalent to del, delete backwards
X To delete a letter, equivalent to Backspace, delete forward
is Copy a word
dw To delete a word
shift+ ^ To move the line head
shift+$ Move to the end of the line
gg or 1 + G Move to header
G Move to footer
Digital + G (first input number, press G) Move to the goal line

Edit mode
operation can be carried out in normal mode to delete, copy, paste, etc., but you can not edit the contents of the file! To enter edit mode will wait until you press any letter "i, I, o, O, a, A, r, R " and so on. Attention! Usually in Linux, when you press these buttons will appear the words "INSERT or REPLACE" in the lower left of the screen, then it can be edited. And if you want to return to normal mode, you must press the "Esc" button to exit the edit mode.
1, enter the edit mode

button Features
i Before the current cursor
a The current cursor
O The next line of the current cursor row
I Cursor line foremost
A The last line where the cursor
O On the current line of the cursor line

2. exit edit mode
press the "Esc" key

指令模式
在一般模式当中,输入『 : / ?』3个中的任何一个按钮,就可以将光标移动到最底下那一行。在这个模式当中, 可以提供你『搜寻资料』的动作,而读取、存盘、大量取代字符、离开 vi 、显示行号等动作是在此模式中达成的!
1.基本语法

命令 功能
:w 保存
:q 退出
:! 强制执行
/要查找的词 n 查找下一个,N 往上查找
? 要查找的词 n是查找上一个,N是往下查找
:set nu 显示行号
:set nonu -关闭行号
ZZ(shift+zz) 没有修改文件直接退出,如果修改了文件保存后退出

2.案例实操
(1)强制保存退出:wq!

发布了18 篇原创文章 · 获赞 2 · 访问量 391

Guess you like

Origin blog.csdn.net/CH_Axiaobai/article/details/103001216