file Permission denied

Latest response

Hello all,

On a RHEL 6.6, I've got some files in read-only.
The file system is good, but somes files cannot be modified :

ll /etc/passwd /etc/group

-rw-r--r--. 1 root root 931 Mar 19 2015 /etc/group
-rw-r--r--. 1 root root 2033 Nov 9 16:30 /etc/passwd

touch /etc/passwd /etc/group

touch: cannot touch `/etc/group': Permission denied

/etc/passwd is writable, but not /etc/group....

we've got at least 3 files that cannot be modified :
/etc/group
/etc/shadow
/etc/gshadow

Our system has been reboot, and the issue is still here

Any ideas ?

Sorry,
I've found the solution ...
lsattr /etc/group
----i--------e- /etc/group
then :
chattr -i /etc/group

Responses

Hello Cedric

It would be great if you could post the solution as a comment, rather than edit the question, and then mark it as the best answer.

Thank you

I've found the solution ...
~~
lsattr /etc/group
~~
----i--------e- /etc/group
then :
~~
chattr -i /etc/group
~~

Thank you

Close

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.