课上复制。。。。


文件权限的管理。
(1)创建目录 test ,进入 test 目录,创建普通文件 test . txt 。
 root @ localhost # mkdir / Test 
[ root @ localhost ]# touch / Test / test . txt 
(2)为 test . txt 设置权限,使得任何人对这个文件不能删除、重命名,不能写入、添加数据,不能创建硬链接。查看设
[ root @ localhost ]# cd / Test 
[ root @ localhost Test ]# chattr + i test . txt 
(3)查看隐藏权限后,取消隐藏权限。
[ root @ localhost Test ]#1sattr test . txt 
- i 
 test . txt 
[ root @ localhost Test ]# chattr - i test . txt 
(4)为 test . txt 设置权限,使得任何人对这个文件只能增加数据,不能删除、修改数据。查看设置结果。
[ root @ localhost Test ]# chattr + ta test . txt 
(5)为/ root 目录设置权限,使得user02有 rwx 的权限,查看设置结果。
[ root @ localhost Test 」# useradd user02
 root @ localhost Test ]# cd / root 
[ root @ localhost ]# touch / root /user02
[ root @ localhost ]# chmod 666/ root /uesr02
[ root @ localhost ]# getfacl ,/ root 
 getfacl : Removing leading '/ from absolute path names 
# file : root 
# owner : root 
# group : root 
 user :: rwx 
user02:rwx
 group :: rwx 
 other :: rwx 

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
要配置一个MongoDB复制集环境,你可以按照以下步骤进行操作: 1. 创建并编辑三个不同的配置文件,例如`mongod.conf`,分别指定不同的端口、数据目录和日志文件路径。你可以使用命令`mongod --config /path/to/config/file`来指定配置文件启动MongoDB实例。 MongoDB官方文档-启动实例的配置文件:https://docs.mongodb.com/manual/tutorial/manage-mongodb-processes/#start-instances-with-configuration-files SegmentFault-《MongoDB高手课》学习记录(第七天): https://segmentfault.com/a/1190000021402232?utm_source=sf-similar-article<span class="em">1</span><span class="em">2</span><span class="em">3</span> #### 引用[.reference_title] - *1* [MongoDB 复制集环境搭建](https://blog.csdn.net/qq_21344887/article/details/124381980)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v92^chatsearchT0_1"}}] [.reference_item style="max-width: 50%"] - *2* *3* [MongoDB复制集原理和配置](https://blog.csdn.net/SongD1114/article/details/124230661)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v92^chatsearchT0_1"}}] [.reference_item style="max-width: 50%"] [ .reference_list ]

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值