“6.5. 创建目录树”为什么使用install命令而不是mkdir呢?
时间:2006-08-06
来源:互联网
代码:
install -dv /{bin,boot,dev,etc/opt,home,lib,mnt} install -dv /{sbin,srv,usr/local,var,opt} install -dv /root -m 0750 install -dv /tmp /var/tmp -m 1777 install -dv /media/{floppy,cdrom} install -dv /usr/{bin,include,lib,sbin,share,src} ln -sv share/{man,doc,info} /usr install -dv /usr/share/{doc,info,locale,man} install -dv /usr/share/{misc,terminfo,zoneinfo} install -dv /usr/share/man/man{1,2,3,4,5,6,7,8} install -dv /usr/local/{bin,etc,include,lib,sbin,share,src} ln -sv share/{man,doc,info} /usr/local install -dv /usr/local/share/{doc,info,locale,man} install -dv /usr/local/share/{misc,terminfo,zoneinfo} install -dv /usr/local/share/man/man{1,2,3,4,5,6,7,8} install -dv /var/{lock,log,mail,run,spool} install -dv /var/{opt,cache,lib/{misc,locate},local} install -dv /opt/{bin,doc,include,info} install -dv /opt/{lib,man/man{1,2,3,4,5,6,7,8}}
不就是创建目录吗?
为什么不使用mkdir而要使用install呢?
mkdir 跟 install 两个命令有什么区别吗?
在两个命令的使用说明上实在是看不出有什么区别!请高手指教!
作者: pingpz 发布时间: 2006-08-06
早期的 Book 是用 mkdir 的,估计是用 install 可以用一条命令把目录创建及设置权限吧
作者: d00m3d 发布时间: 2006-08-06
我试过了,install和mkdir创建的目录权限完全相同啊
作者: hougollen 发布时间: 2009-04-29
From diy-linux:
Current LFS inefficiently uses a raft of `install -d' commands for directory creation here. There is no need for this when `mkdir' is perfectly suited to the task. Only when custom permissions are required do we use `install -d'.
Current LFS inefficiently uses a raft of `install -d' commands for directory creation here. There is no need for this when `mkdir' is perfectly suited to the task. Only when custom permissions are required do we use `install -d'.
作者: newper 发布时间: 2009-04-30
相关阅读 更多
热门阅读
-
office 2019专业增强版最新2021版激活秘钥/序列号/激活码推荐 附激活工具
阅读:74
-
如何安装mysql8.0
阅读:31
-
Word快速设置标题样式步骤详解
阅读:28
-
20+道必知必会的Vue面试题(附答案解析)
阅读:37
-
HTML如何制作表单
阅读:22
-
百词斩可以改天数吗?当然可以,4个步骤轻松修改天数!
阅读:31
-
ET文件格式和XLS格式文件之间如何转化?
阅读:24
-
react和vue的区别及优缺点是什么
阅读:121
-
支付宝人脸识别如何关闭?
阅读:21
-
腾讯微云怎么修改照片或视频备份路径?
阅读:28