Finley Ave

Active Member
Feb 28, 2004
37
0
156
San Ramon, CA
When I try to edit, rename, or change permissions for root .bash_profile, I get permission denied. The permissions showing are 644, owner and group is root. I have this problem only recently on both my cpanel boxes, but not on a non-cpanel box. Any help is appreciated.
 

chirpy

Well-Known Member
Verifed Vendor
Jun 15, 2002
13,437
31
473
Go on, have a guess
You've probably chattr'd the file (or installed a script that did so). You can check with:

lsattr .bash_profile

If it's not all dashes then you need to remove the attribute. It's probably immutable (i), so to remove that you would:

chattr -i .bash_profile