当前位置:网站首页>Rhcsa day 3

Rhcsa day 3

2022-07-04 07:11:00 Where are the peaches

1、 Sum up vim Of the three modes, the commands you think are practical

Command mode
gg Jump to the beginning of the line at the beginning of the document
Insertion mode
u Undo to the left
Last row mode
:%s / Configure character information / Replaced characters /g
2、 File management command exercise :

 

3、vi practice : Complete the following steps

1) application vi Command in /tmp Create files under folders , file name newfile. stay newfile Enter the date and time on the first line

2) take /boot/grub2/grub.cfg The contents of the document are read into newfile In the document ( On the next line of the date, i.e 2 That's ok )

3) Find documents that contain # The line of the sign character , Delete entire line

4) Turn on VI Line number prompt function

5) Move the cursor to 5 That's ok , And in the first place 5 A new blank line is generated after the line 6 That's ok

6) Modify the content . Will all timeout=5, Change to time=30

7) All... In the entire document root The character is changed to admin character

8) Copy No 1 The date and time content of the line to the end of the document

9) Save the document , Save the document again as /boot/newfile2, sign out VI Editor

 

 

 

 

 

 

 

 

 

 4、 The file to view

Copy user profile to /opt Under the table of contents ;

see /opt/mima File first 6 That's ok ;

 

 

5. Statistics show user profiles nologin Number of occurrences

 

6. Displays the total number of users in the system

 

7. Set the system time ( Minutes and seconds ) write in time file

 

8.history The system command history can be displayed , Count the top three with the highest command frequency of the current system .( The command repeats three more commands )

原网站

版权声明
本文为[Where are the peaches]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/02/202202141543296151.html