




已阅读5页,还剩1页未读, 继续免费阅读
版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领
文档简介
第一题:1、rootB2 # useradd zhlrootB2 # passwd zhlChanging password for user zhl.New UNIX password: BAD PASSWORD: it does not contain enough DIFFERENT charactersRetype new UNIX password: passwd: all authentication tokens updated successfully.rootB2 # useradd 20092002rootB2 # passwd 20092002Changing password for user 20092002.New UNIX password: BAD PASSWORD: it is too simplistic/systematicRetype new UNIX password: Sorry, passwords do not match.New UNIX password: BAD PASSWORD: it is too simplistic/systematicRetype new UNIX password: passwd: all authentication tokens updated successfully.rootB2 #2在用户的主目录下创建目录sub1,sub2;文件file1,file2。rootB2 # cd /homerootB2 home# cd zhlrootB2 zhl# mkdir sub1rootB2 zhl# mkdir sub2rootB2 zhl# touch file1rootB2 zhl# touch file2rootB2 zhl# lsfile1 file2 sub1 sub2如图所示:在目录sub1中创建目录sub11,sub12.命令是:rootB2 zhl# cd sub1rootB2 sub1# mkdir sub11rootB2 sub1# mkdir sub12rootB2 sub1# lssub11 sub12结果如下图所示在sub2中创建sub21命令:rootB2 sub1# cd /homerootB2 home# cd zhlrootB2 zhl# cd sub2rootB2 sub2# mkdir sub21rootB2 sub2# lssub21如图所示:3.(1)将/etc/passwd文件复制到用户主目录下,命名为passwd.bak命令是:rootB2 sub2# cd /homerootB2 home# cd zhlrootB2 zhl# cp /etc/passwd ./passwd.bak(2)将file1和file2文件合并为file3,并保存在用户主目录下。命令:rootB2 zhl# cat file1 file2 file33)将file1和file2文件复制到sub1目录下命令:rootB2 zhl# cd /homerootB2 home# cd zhlrootB2 zhl# cp file1 ./sub1/sub11rootB2 zhl# cp file2 ./sub1/sub11结果如图所示:4)在sub2目录中建立/home/用户主目录/file1文件的硬链接,命名为file1.hard。命令:rootB2 zhl# cd sub2rootB2 sub2# ln ./file1 file1-hard5)在sub2目录中建立/home/用户主目录/file1文件的符号链接文件,命名为file1.soft。命令:rootB2 sub2# ln -s ./file1 file1-soft如图所示:6)将所有file1文件重命名为file4.rootB2 zhl# mv file1 file4rootB2 zhl# mv ./sub1/sub11/file1 ./sub1/sub11/file48)在/home目录及其子目录中查找并显示所有以f开头的文件。命令:find: f: 没有那个文件或目录rootB2 home# find /home -name f*/home/zhl/file2/home/zhl/sub2/file1-soft/home/zhl/sub2/file1-hard/home/zhl/sub1/sub11/file2/home/zhl/sub1/sub11/file4/home/zhl/file3/home/zhl/file4rootB2 home#(9)在/home目录及其子目录中查找所有file2文件并将其删除。命令:rootB2 home# find /home -name file2/home/zhl/file2/home/zhl/sub1/sub11/file2删除命令:rootB2 home# rm /home/zhl/file2;rm /home/zhl/sub1/sub11/file2rm:是否删除 一般空文件 “/home/zhl/file2”? rm:是否删除 一般空文件 “/home/zhl/sub1/sub11/file2”? rootB2 home#(10)删除用户主目录中所有新建的子目录和文件。rootB2 home# cd /homerootB2 home# cd zhlrootB2 zhl# lsfile2 file3 file4 passwd.bak sub1 sub2rootB2 zhl# rm -rf file1rootB2 zhl# rm -rf file2rootB2 zhl# rm -rf file4rootB
温馨提示
- 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
- 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
- 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
- 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
- 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
- 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
- 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。
最新文档
- 工程施工的重点和难点及保证措施
- 【中考模拟】2025年江苏省镇江市第三中学数学中考练习卷(含解析)
- 断桥铝窗安装现场监督质量保证措施
- 十四五规划房地产调控心得体会
- 危重患者转运及交接操作流程他
- 小学合唱社团艺术交流计划
- 民用建筑施工进度计划
- 成人教育教育信息化能力提升培训心得体会
- 以延吉市XX中学为例剖析高中化学习题课教学现状与提升路径
- 以市场为导向:中国美术学院艺术设计职业技术学院专业设置变革与实践
- T∕HGJ 12402-2021 石油化工装置火灾紧急隔离控制阀设计标准
- 办公用纸项目建设实施方案
- 2024版《53天天练单元归类复习》3年级语文下册(统编RJ)附参考答案
- 辣椒购销合同范本
- 13J927-3 机械式停车库设计图册
- 装卸工安全培训课件
- 高位截瘫护理查房
- 2024图书约稿合同范本
- 肥料代理合作协议书
- 检修作业培训
- 山东省烟台市2024-2025学年高二化学下学期期末考试试题
评论
0/150
提交评论