liunx-系统配置及服务管理 用户的权限-基本权限UGO
Posted
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了liunx-系统配置及服务管理 用户的权限-基本权限UGO相关的知识,希望对你有一定的参考价值。
1.权限对象:属主:u ; 属组: g : 其他人: o ;所有人:a(u
+g+o)
2.权限类型 :读: r=4 ; 写: w=2 ; 执行: x=1
3.查看权限记录
[root@localhost ~]#ls -l /root/1.txt
-rw-r--r--. 1 root root 179 5月 25 14:27 /root/1.txt
-文件类型
rw-主人的权限,属主
r--属组的权限,
r--其他人的权限
. 权限的扩展
1文件链接(第七章文件链接)
root文件的属主
root文件的属组
179大小
5月 25 14:27文件最后的修改时间
/root/1.txt 文件的名和路径
4.语法: 使用符号:u用户 g组 o其他 r读 w写 x执行
语法: chmod 对象(u/g/o/a)赋值符(+/-/=)权限类型(r/w/x) 文 件/目录
5 [root@localhost ~]# touch 123.txt
[root@localhost tmp]# ll 123.txt
-rw-r--r--. 1 root root 0 4月 13 20:49 file1
权限 属主 属组 文件
6.[root@localhost tmp]#vim 123.txt
echo "hello 2020"
read -p "请输入您的姓名:" name
echo "哈哈 $name 是大笨蛋"
可查看,可编写 不可执行
7.使用数字; 4读 2写 1执行 chmod 改写文件权限; chmod 744 123.txt root账户已能执行程序
程序已可以执行:
以上是关于liunx-系统配置及服务管理 用户的权限-基本权限UGO的主要内容,如果未能解决你的问题,请参考以下文章