对文件设置特殊的权限,FACL(File Access Control List)


ACL简介

基本ACL操作

getfacl  查看文件权限      setfacl  设定acl权限

设置file的ACL权限

[root@mvpbang tmp]# setfacl -m u:ftp:rwx 1.sh
[root@mvpbang tmp]#
[root@mvpbang tmp]# ll .sh
-rw-rwxr--+ ftp ftp Sep : .sh #文件详情多个+
[root@mvpbang tmp]# getfacl .sh
# file: .sh
# owner: ftp
# group: ftp
user::rw-
user:ftp:rwx #多个附属的ftp的权限
group::r--
mask::rwx
other::r--

setfacl命令参数

[root@mvp tmp]# setfacl -h
setfacl 2.2. -- set file access control lists
Usage: setfacl [-bkndRLP] { -m|-M|-x|-X ... } file ...
-m, --modify=acl modify the current ACL(s) of file(s)
-M, --modify-file=file read ACL entries to modify from file
-x, --remove=acl remove entries from the ACL(s) of file(s)
-X, --remove-file=file read ACL entries to remove from file
-b, --remove-all remove all extended ACL entries
-k, --remove-default remove the default ACL
--set=acl set the ACL of file(s), replacing the current ACL
--set-file=file read ACL entries to set from file
--mask do recalculate the effective rights mask
-n, --no-mask don't recalculate the effective rights mask
-d, --default operations apply to the default ACL
-R, --recursive recurse into subdirectories
-L, --logical logical walk, follow symbolic links
-P, --physical physical walk, do not follow symbolic links
--restore=file restore ACLs (inverse of `getfacl -R')
--test test mode (ACLs are not modified)
-v, --version print version and exit
-h, --help this help text

Linux特殊的文件控制权限FACL的更多相关文章

  1. Linux(三)__文件权限、系统的查找、文本编辑器

    一.文件权限 1.理解文件权限及其分配 2.掌握查看文件和目录的权限 3.掌握权限文字表示法和数值表示法 4.学会使用chmod命令设置权限 5.学会使用chown命令修改属主和组 linux文件能不 ...

  2. Linux文件和目录权限详细讲解

    转载请标明出处: http://www.cnblogs.com/why168888/p/5965180.html 本文出自:[Edwin博客园] Linux文件和目录权限解读 如何设置Linxu文件和 ...

  3. linux 中更改用户权限和用户组的命令chmod,chgrp实例

    linux 中更改用户权限和用户组的命令实例; 增加权限给当前用户 chmod +wx filename chmod -R 777 /upload 用户组 chgrp -R foldname zdz ...

  4. Linux文件及目录权限解析

    Linux系统9位基础权限体系 文件权限   * r权限 可读          对文件具有读取及查看文件内容的全新啊   * w权限 可写        对文件具有新增.修改文件内容的权限     ...

  5. Linux命令:修改文件权限命令chmod、chgrp、chown详解

    Linux系统中的每个文件和目录都有访问许可权限,用它来确定谁可以通过何种方式对文件和目录进行访问和操作. 文件或目录的访问权 限分为只读,只写和可执行三种.以文件为例,只读权限表示只允许读其内容,而 ...

  6. Linux用户配置sudo权限

    Linux用户配置sudo权限 创建sudo权限用户 #useradd supope #passwd supope #visudo #supope         ALL=(ALL)       AL ...

  7. 【Linux】文件特殊权限 SUID/SGID/Sticky Bit

    linux中除了常见的读(r).写(w).执行(x)权限以外,还有3个特殊的权限,分别是setuid.setgid和stick bit 1.setuid.setgid 先看个实例,查看你的/usr/b ...

  8. linux中执行命令权限不够怎样处理

    在linux中执行命令权限不够就要增加权限,先看遇到的情况 查看权限情况 那就赋予权限 执行命令

  9. Linux中的特殊权限粘滞位(sticky bit)详解

    Linux下的文件权限 在linux下每一个文件和目录都有自己的访问权限,访问权限确定了用户能否访问文件或者目录和怎样进行访问.最为我们熟知的一个文件或目录可能拥有三种权限,分别是读.写.和执行操作, ...

随机推荐

  1. .Net-using-Class:MemoryCache 类

    ylbtech-.Net-using-Class:MemoryCache 类 初始化 System.Runtime.Caching.MemoryCache 类的新实例. 1. 程序集 System.R ...

  2. 【deep learning学习笔记】注释yusugomori的DA代码 --- dA.cpp -- 训练

    说实话,具体的训练公式,我没有自己推导,姑且认为他写的代码是对的.总体上看,用bp的方法.特殊之处,在于输入层和输出层是完完全全的“同一层”. void dA::get_corrupted_input ...

  3. boost并发编程boost::atomic

    三个用于并发编程的组件: atomic,thread,asio(用于同步和异步io操作)   atomic atomic,封装了不同计算机硬件的底层操作原语,提供了跨平台的原子操作功能,解决并发竞争读 ...

  4. FPC and Qt

    Introduction There are a number of Qt bindings available: Qt3 A QtC based binding by Theo Another Qt ...

  5. go语言之进阶篇json解析到结构体

    1.json解析到结构体 示例: package main import ( "encoding/json" "fmt" ) type IT struct { ...

  6. iview,用render函数渲染

    <Table border :columns="discountColumns" :data="discountData.rows"></Ta ...

  7. checkbox反复调用attr('checked', true/false)只有第一次生效

    /** * 全选 */ function checkAll() { $("input[name=ids]").attr("checked", true); } ...

  8. 【google面试题】求1到n的正数中1出现的次数的两种思路及其复杂度分析

    问题描写叙述: 输入一个整数n,求从1到n这n个整数的十进制表示中1出现的次数.比如输入12,从1到12这些整数中包括1 的数字有1.10.11和12.1一共出现了5次. 这是一道广为流传的googl ...

  9. Android -- Camera2(Android5.0)

    Camera2 Camera2是Android5.0中的其中一个新的特性,新的API.与原来的camera API相比,不同之处在于: 原生支持RAW照片输出 突发拍摄模式 制约拍照速度的不再是软件而 ...

  10. 一文读懂「Attention is All You Need」| 附代码实现

    https://mp.weixin.qq.com/s?__biz=MzIwMTc4ODE0Mw==&mid=2247486960&idx=1&sn=1b4b9d7ec7a9f4 ...