I have the following structure (property is in the form user:group, user A belongs to both groups A and B, user B is just in the B group) :
+ dir1 rwxrwxr-x A:A
+ dir2 rwxrwxr-x A:B
- file1 rw-rw-r-- B:B
+ dir3 rwxrwxr-x B:B
-file2 rw-rw-r-- B:B
I (as user A) want to move file2 to dir1. When I do so, I get a "Permisson denied" error (while moving file1 to dir1 is working fine). As a result file2 is copied in dir1 but still remains in dir3 as if the group write permission was ignored for the suppression.
What is the problem here?
EDIT:
Maybe there's a problem with the group assignation, here's the result of a few commands:
$ whoami
A
$ groups
A <-- ??? why
$ groups A
A : A B
Moreover, the mv I'm trying to do is in a script called by a crontab job, and it's working frmo there. Is there something to do to "refresh" groups assignments?