
chgrp
ユーザー「2」のホームフォルダにある「share」というフォルダで使用しようとしています。フォルダls -l
は次のとおりです。
drwxr-xr-x 2 2 bin 4096 Sep 29 13:09 share
chgrp
上記の「share」フォルダで「34」というグループを使用すると、「bin」パラメータは34に変更されますが、グループパラメータ(現在2)は同じままです。
なぜこれが起こるのですか?
答え1
2
最初の項目とユーザーを混同しているようです2
。最初のものは2
ハードリンクの総数を表し、2番目は2
ユーザーを表し、グループ名はbinまたは34
変更されたグループ名です。見ている内容の説明は次のとおりです。
+-permissions that apply to the owner
|
| +-permissions that apply to all other users
| |
| | +-number of hard links
| | |
| | | +-size +-last modification date and time
_|_ _|_ | __|__ _____|_______
drwxr-xr-x 2 2 bin 4096 Sep 29 13:09 share
___ _ ___ _____
| | | |
| | | +-name of file or directory
| | |
| | +-the group that the group permissions applies to
| |
| +-owner
|
+-permissions that apply to users who are members of the group