当前位置:网站首页>Rhcsa 03 - Basic permissions for documents
Rhcsa 03 - Basic permissions for documents
2022-07-04 04:29:00 【Wangwanlin Ben】
Preface
Linux Of UGO The permissions model , It can meet daily permission requirements .
What is? UGO The permissions model ?
practice
step 1: Create user , And add users to the newly created group
[[email protected] ~]# groupadd students
[[email protected] ~]# groupadd profs
[[email protected] ~]# useradd linda -G students
useradd lisa -G students
[[email protected] ~]# useradd lisa -G students
useradd anouk -G profs
[[email protected] ~]# useradd anouk -G profs
useradd anna -G profs
[[email protected] ~]# useradd anna -G profs
[[email protected] ~]# step 2: Create two folders /data/students And /data/profs
[[email protected] ~]# mkdir -p /data/students /data/profs
[[email protected] ~]# ls -l /data
total 0
drwxr-xr-x. 2 root root 6 Jul 2 01:47 profs
drwxr-xr-x. 2 root root 6 Jul 2 01:47 studentsstep 3: The folder just created , Change the group to students, profs, Permission is 770
[[email protected] ~]# chgrp students /data/students
[[email protected] ~]# chgrp profs /data/profs
[[email protected] ~]# chmod 770 /data/{students,profs}
[[email protected] ~]# ls -l /data
total 0
drwxrwx---. 2 root profs 6 Jul 2 01:47 profs
drwxrwx---. 2 root students 6 Jul 2 01:47 studentsstep 4: verification :anna Success to /data/profs create a file ,anouk Cannot write owner as anna Permission is 644 The file of .
[[email protected] ~]# id anna
uid=1004(anna) gid=1006(anna) groups=1006(anna),1002(profs)
[[email protected] ~]# su anna -c "touch /data/profs/anna"
[[email protected] ~]# ls -l /data/profs/anna
-rw-r--r--. 1 anna anna 0 Jul 2 01:58 /data/profs/anna
[[email protected]92f238ca5 ~]# su anouk -c "echo anouk > /data/profs/anna"
bash: /data/profs/anna: Permission denied边栏推荐
- Programmers' telecommuting is mixed | community essay solicitation
- [csrf-01] basic principle and attack and defense of Cross Site Request Forgery vulnerability
- NFT新的契机,多媒体NFT聚合平台OKALEIDO即将上线
- 透过JVM-SANDBOX源码,了解字节码增强技术原理
- 架构训练毕业设计+总结
- Wechat official account infinite callback authorization system source code
- R语言dplyr中的Select函数变量列名
- 一位毕业生的自我分享
- 【微信小程序】好看的轮播图组件
- 2020 Bioinformatics | TransformerCPI
猜你喜欢

Application scheme of Puyuan ds1000z series digital oscilloscope in communication principle experiment

软件测试是干什么的 发现缺陷错误,提高软件的质量

UnicodeDecodeError: ‘gbk‘ codec can‘t decode byte 0x98 in position 1093: illegal multibyte sequence

统计遗传学:第三章,群体遗传

Understand the principle of bytecode enhancement technology through the jvm-sandbox source code

FT2000+下LPC中断绑核使用说明

多位科技公司创始人向Entrepreneur First提供高达1.58亿美元的C轮融资,协助其投资下一代全球创新者

深入解析结构化异常处理(SEH) - by Matt Pietrek

Redis:有序集合zset类型数据操作命令

毕业设计:设计秒杀电商系统
随机推荐
Architecture practice camp - graduation project of module 9 of phase 6
Krypton saikr daily question - CTF
新手找陪驾要注意什么
R语言dplyr中的Select函数变量列名
Idea modify body color
沃博联结束战略评估,决定保留表现优异的博姿业务
VIM add interval annotation correctly
Flink learning 6: programming model
Unity Resource path
leetcode 121 Best Time to Buy and Sell Stock 买卖股票的最佳时机(简单)
2021 RSC | Drug–target affinity prediction using graph neural network and contact maps
架构训练毕业设计+总结
dried food! Generation of rare samples based on GaN
VIM mapping command
Leetcode 121 best time to buy and sell stock (simple)
Talking about what a high-quality little red book copy needs to have
【安全攻防】序列化与反序列,你了解多少?
RHCSA 07 - 用户与群组管理
Small record of thinking
Ppt tutorial, how to save a presentation as a PDF file in PowerPoint?