zoukankan      html  css  js  c++  java
  • Linux-day2-pdf课件

    1、Linux文件属性和权限

    2、Linux重定向

     

    3、Linux文件查找

    4、Linux压缩打包

     5、课堂作业

    权限相关作业:

    题目
    创建用户carol,ivy,jenny,kevin,alice
    创建/test目录,并在目录下创建testfile1,testfile2,testfile3

    要求:

    1) 所有用户能够查看testfile1的内容。

    usermod -aG testgroup carol
    usermod -aG testgroup ivy
    usermod -aG testgroup jenny
    usermod -aG testgroup jenny
    usermod -aG testgroup alice
    chown :testgroup /test/testfiel1
    chmod g+r /test/testfiel1


    2) carol、ivy、jenny能够修改testfile1

    setfacl -m u:carol:rw /test/testfiel1
    setfacl -m u:ivy:rw /test/testfiel1
    setfacl -m u:jenny:rw /test/testfiel1


    3) kevin、alice能够修改testfile2

    setfacl -m u:kevin:rw /test/testfiel2
    setfacl -m u:alice:rw /test/testfiel2

    4) kevin、alice能够管理目录下的创建、删除文件操作

    setfacl -m u:kevin:rw /test
    setfacl -m u:alice:rw /test

    5) carol、ivy、jenny不能够删除、也不能创建文件

    setfacl -x u:carol /test
    setfacl -x u:ivy /test
    setfacl -x u:jenny /test

    6) testfile3 仅允许追加内容,不允许修改

    chattr +a /test/testfiel3

  • 相关阅读:
    P2351 [SDOI2012]吊灯
    洛谷P1450 [HAOI2008]硬币购物 背包+容斥
    P5110 块速递推-光速幂、斐波那契数列通项
    AT2304 Cleaning
    CSP-S 2020
    CF487E Tourists
    P4334 [COI2007] Policija
    动态逆序对专练
    CF437D The Child and Zoo
    CF1032G Chattering
  • 原文地址:https://www.cnblogs.com/lz-tester/p/10756791.html
Copyright © 2011-2022 走看看