当前位置:网站首页>Rhcsa Road
Rhcsa Road
2022-07-06 20:17:00 【Omniscient magical conch】
Homework the next day
Job requirements
7. Delete /tmp/sys/a file .
8. Catalog /tmp Create 4 A catalog , And create one under each of these four directories test Catalog
9. Create a test Catalog , Create a file in this directory , Content writing nano
10. stay /dir Create directory under dir2 And documents file1, Moving files file1 To create test Directory , Put the table of contents dir2 Copied to the test Directory
Symbolic links are also called soft links , And the original file is not a file . for example Windows Shortcut to ,
Characteristics of action : Find a file in the specified path and access it quickly and easily , Delete source file shortcut cannot be accessed
Hard links :
Multiple filenames point to the same Inode
Characteristics of action : Prevent users from deleting by mistake , Backup ( Backup only for file names ), Deleting the source file will not affect the hard link
2
establish aaa
[[email protected] ~]# cd /home
[[email protected] home]# touch aaa
[[email protected] home]# ll
total 4
-rw-r--r--. 1 root root 0 Feb 11 06:45 aaa
drwx------. 15 redhat redhat 4096 Feb 10 06:50 redhat
establish a.txt
[[email protected] ~]# cd /
[[email protected] /]# ln -s / a.txt
[[email protected] /]# ll
total 28
lrwxrwxrwx. 1 root root 1 Feb 11 06:59 a.txt -> /
establish A
[[email protected] /]# cd /root
[[email protected] ~]# touch A
[[email protected] ~]# link A A.txt
[[email protected] ~]# ll
total 8
-rw-r--r--. 2 root root 0 Feb 11 07:00 A
3
[[email protected] ~]# cd
[[email protected] ~]# pwd
/root
[[email protected] ~]# touch abc{1..100}
[[email protected] ~]# ll
total 8
-rw-r--r--. 2 root root 0 Feb 11 07:00 A
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc1
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc10
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc100
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc11
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc12
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc13
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc14
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc15
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc16
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc17
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc18
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc19
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc2
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc20
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc21
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc22
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc23
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc24
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc25
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc26
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc27
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc28
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc29
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc3
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc30
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc31
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc32
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc33
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc34
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc35
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc36
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc37
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc38
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc39
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc4
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc40
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc41
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc42
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc43
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc44
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc45
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc46
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc47
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc48
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc49
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc5
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc50
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc51
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc52
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc53
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc54
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc55
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc56
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc57
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc58
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc59
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc6
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc60
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc61
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc62
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc63
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc64
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc65
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc66
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc67
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc68
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc69
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc7
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc70
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc71
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc72
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc73
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc74
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc75
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc76
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc77
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc78
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc79
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc8
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc80
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc81
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc82
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc83
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc84
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc85
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc86
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc87
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc88
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc89
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc9
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc90
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc91
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc92
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc93
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc94
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc95
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc96
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc97
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc98
-rw-r--r--. 1 root root 0 Feb 11 07:02 abc99
-rw-------. 1 root root 1036 Feb 10 14:33 anaconda-ks.cfg
-rw-r--r--. 2 root root 0 Feb 11 07:00 A.txt
drwxr-xr-x. 2 root root 6 Feb 10 07:42 Desktop
drwxr-xr-x. 2 root root 6 Feb 10 07:42 Documents
drwxr-xr-x. 2 root root 6 Feb 10 07:42 Downloads
-rw-r--r--. 1 root root 1308 Feb 10 14:39 initial-setup-ks.cfg
drwxr-xr-x. 2 root root 6 Feb 10 07:42 Music
drwxr-xr-x. 2 root root 6 Feb 10 07:42 Pictures
drwxr-xr-x. 2 root root 6 Feb 10 07:42 Public
drwxr-xr-x. 2 root root 6 Feb 10 07:42 Templates
drwxr-xr-x. 2 root root 6 Feb 10 07:42 Videos
4
[[email protected] ~]# touch n.txt
[[email protected] ~]# nano n.txt
[[email protected] ~]# cat n.txt
He love his lover
He love his liker
He like his lover
He like his liker
5

The first column is the file type
6
[[email protected] ~]# mkdir /test/sysroot -p
[[email protected] ~]# ll
total 8
-rw-------. 1 root root 1036 Feb 10 14:33 anaconda-ks.cfg
drwxr-xr-x. 2 root root 6 Feb 10 07:42 Desktop
drwxr-xr-x. 2 root root 6 Feb 10 07:42 Documents
drwxr-xr-x. 2 root root 6 Feb 10 07:42 Downloads
-rw-r--r--. 1 root root 1308 Feb 10 14:39 initial-setup-ks.cfg
drwxr-xr-x. 2 root root 6 Feb 10 07:42 Music
drwxr-xr-x. 2 root root 6 Feb 10 07:42 Pictures
drwxr-xr-x. 2 root root 6 Feb 10 07:42 Public
drwxr-xr-x. 2 root root 6 Feb 10 07:42 Templates
drwxr-xr-x. 2 root root 6 Feb 10 07:42 Videos
[[email protected] ~]# mkdir /tmp -p
[[email protected] ~]# cd /test/sysroot
[[email protected] sysroot]# ll
total 0
[[email protected] sysroot]# touch a b c
[[email protected] sysroot]# ll
total 0
-rw-r--r--. 1 root root 0 Feb 12 21:16 a
-rw-r--r--. 1 root root 0 Feb 12 21:16 b
-rw-r--r--. 1 root root 0 Feb 12 21:16 c
[[email protected] sysroot]# cd
[[email protected] ~]# mv /test/sysroot /tmp/sys
[[email protected] ~]# ll /tmp
total 20
drwxr-xr-x. 2 root root 33 Feb 12 21:16 sys
[[email protected] ~]# ll /tmp/sys
total 0
-rw-r--r--. 1 root root 0 Feb 12 21:16 a
-rw-r--r--. 1 root root 0 Feb 12 21:16 b
-rw-r--r--. 1 root root 0 Feb 12 21:16 c
7
[[email protected] ~]# cd /tmp/sys
[[email protected] sys]# rm a
rm: remove regular empty file 'a'? y
[[email protected] sys]# ll
total 0
-rw-r--r--. 1 root root 0 Feb 12 21:16 b
-rw-r--r--. 1 root root 0 Feb 12 21:16 c
8
[[email protected] tmp]# mkdir /tmp/b/test -p
[[email protected] tmp]# mkdir /tmp/b/test -p
[[email protected] tmp]# mkdir /tmp/c/test -p
[[email protected] tmp]# mkdir /tmp/d/test -p
[[email protected] tmp]# ll
total 20
drwxr-xr-x. 3 root root 18 Feb 12 21:24 a
drwxr-xr-x. 3 root root 18 Feb 12 21:24 b
drwxr-xr-x. 3 root root 18 Feb 12 21:24 c
drwxr-xr-x. 3 root root 18 Feb 12 21:24 d
9
[[email protected] ~]# mkdir -p /test
[[email protected] ~]# cd /test
[[email protected] test]# touch a.txt
[[email protected] test]# nano a.txt
[[email protected] test]# cat a.txt
nano
10
[[email protected] ~]# mkdir -p /dir
[[email protected] ~]# cd /dir
[[email protected] dir]# mkdir -p /dir2
[[email protected] dir]# touch file1
[[email protected] dir]# ll
total 0
-rw-r--r--. 1 root root 0 Feb 12 21:29 file1
[[email protected] dir]# cd
[[email protected] ~]# mkdir -p /dir/dir2
[[email protected] ~]# cd /dir
[[email protected] dir]# ll
total 0
drwxr-xr-x. 2 root root 6 Feb 12 21:29 dir2
-rw-r--r--. 1 root root 0 Feb 12 21:29 file1
[[email protected] dir]# cp -p file1 /test
[[email protected] dir]# cd /test
[[email protected] test]# ll
total 4
-rw-r--r--. 1 root root 5 Feb 12 21:27 a.txt
-rw-r--r--. 1 root root 0 Feb 12 21:29 file1
[[email protected] test]# cd /dir
[[email protected] dir]# cp -r dir2 /test
[[email protected] dir]# cd /test
[[email protected] test]# ll
total 4
-rw-r--r--. 1 root root 5 Feb 12 21:27 a.txt
drwxr-xr-x. 2 root root 6 Feb 12 21:31 dir2
-rw-r--r--. 1 root root 0 Feb 12 21:29 file1
边栏推荐
- Groovy basic syntax collation
- Standardized QCI characteristics
- Tencent T2 Daniel explained in person and doubled his job hopping salary
- AddressSanitizer 技术初体验
- Node.js: express + MySQL实现注册登录,身份认证
- JVM_ Common [interview questions]
- 02 basic introduction - data package expansion
- 腾讯T4架构师,android面试基础
- [cloud lesson] EI lesson 47 Mrs offline data analysis - processing OBS data through Flink
- Crawler (14) - scrape redis distributed crawler (1) | detailed explanation
猜你喜欢

B-jiege's tree (pressed tree DP)

【每周一坑】信息加密 +【解答】正整数分解质因数

案例 ①|主机安全建设:3个层级,11大能力的最佳实践

某东短信登录复活 安装部署教程

报错分析~csdn反弹shell报错
![[Yann Lecun likes the red stone neural network made by minecraft]](/img/95/c3af40c7ecbd371dd674aea19b272a.png)
[Yann Lecun likes the red stone neural network made by minecraft]

Selenium advanced operations

【云原生与5G】微服务加持5G核心网

Continuous test (CT) practical experience sharing

New generation garbage collector ZGC
随机推荐
腾讯架构师首发,2022Android面试笔试总结
Example of applying fonts to flutter
【GET-4】
Linear distance between two points of cesium
01 basic introduction - concept nouns
BeagleBoneBlack 上手记
使用ssh连接被拒
夏志刚介绍
Error analysis ~csdn rebound shell error
2022年6月语音合成(TTS)和语音识别(ASR)论文月报
02 基础入门-数据包拓展
Wechat applet common collection
Poj3617 best cow line
POJ3617 Best Cow Line 馋
某东短信登录复活 安装部署教程
5. 無線體內納米網:十大“可行嗎?”問題
Crawler (14) - scrape redis distributed crawler (1) | detailed explanation
范式的数据库具体解释
Node. Js: express + MySQL realizes registration, login and identity authentication
Is it difficult for small and micro enterprises to make accounts? Smart accounting gadget quick to use