当前位置:   article > 正文

linux第三天作业-RHCSA_黑马程序员linux命令基础第三天作业

黑马程序员linux命令基础第三天作业

一.实验要求

在这里插入图片描述二.实验操作
1.[root@localhost ~]# mkdir /ceshi
[root@localhost ~]# cd /ceshi
[root@localhost ceshi]# mkdir /ceshi/user
[root@localhost ceshi]# cp -r /etc/passwd /etc/shadow /ceshi/user/
[root@localhost ceshi]# ll -d /ceshi/user/passwd
-rw-r–r--. 1 root root 2534 Mar 24 09:35 /ceshi/user/passwd
[root@localhost ceshi]# ln /ceshi/user/passwd /passwd.bak
[root@localhost ceshi]# mkdir /user/shadow
[root@localhost ceshi]# ln -s /ceshi/user/shadow /sh.link
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
2. [root@localhost ceshi]# cp -r /etc/ssh/sshd_config .
[root@localhost ceshi]# cp -r . /sshd
在这里插入图片描述
3. [root@localhost /]# find / -name passwd | tee passwd.txt
在这里插入图片描述
4. [root@localhost ~]# vim /ceshi/sshd
[root@localhost ~]# vim /ceshi/user/passwd.bak
[root@localhost ~]# mv /ceshi/user/passwd.bak /ceshi/sshd /root/test
5.[root@localhost ~]# mkdir /ceshi
[root@localhost ~]# cd /ceshi
[root@localhost ceshi]# mkdir /ceshi/user/
[root@localhost ~]# tar zcvf text.tar.gz ceshi/user/ root/test/sshd
[root@localhost ~]# ll
total 4
drwxr-xr-x. 2 root root 17 Mar 22 09:24 text
-rw-r–r--. 1 root root 45 Mar 22 09:29 text.tar.gz
在这里插入图片描述

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/正经夜光杯/article/detail/879001
推荐阅读
相关标签
  

闽ICP备14008679号