Answer the question
In order to leave comments, you need to log in
[[+content_image]]
Chown, chgrp - how to fix the problem?
Good afternoon, such a problem, I can not understand why this is happening?
first terminal
[[email protected] ~]$ touch file1
[[email protected] ~]$ ls -l
total 0
-rw-rw-r--. 1 user2 user2 0 Nov 25 02:14 file1
[[email protected] ~]$ chgrp user3 file1
chgrp: changing group of `file1': Operation not permitted
[[email protected] ~]$ chown user3 file1
chown: changing ownership of `file1': Operation not permitted
[[email protected] ~]$ ls -l file1
-rw-rw-r--. 1 user2 user2 0 Nov 25 02:14 file1
[[email protected] ~]$
and on the second terminal:
[[email protected] ~]$ touch file2
[[email protected] ~]$ ls -l file2
-rw-rw-r--. 1 user3 user3 0 Nov 25 02:15 file2
[[email protected] ~]$ chgrp user2 file2
[[email protected] ~]$ chown user2 file2
chown: changing ownership of `file2': Operation not permitted
[[email protected] ~]$ ls -l file2
-rw-rw-r--. 1 user3 user2 0 Nov 25 02:15 file2
1. I can't understand why one can change the group of a file and the other does not?
2. for some reason, chown stopped working, being the owner cannot give the file to another
Answer the question
In order to leave comments, you need to log in
I can’t understand why one gets to change the group of a file and the other doesn’t?
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question