when i try to edit exim.conf i have this error
[ Error writing /etc/exim.conf: Operation not permitted ]
when i try to edit exim.conf i have this error
[ Error writing /etc/exim.conf: Operation not permitted ]
What is the username being used to access and attempt editing the Exim configuration file?
Where exactly is the message being displayed at?
Via root SSH access, please run the following commands and post the resulting output:
Code:# stat /etc/exim.conf # lsattr /etc/exim.conf
cPResources: Submit a Support Request - Submit a Bug Report - Review existing Tickets-- Donald cPanelDon Holl - Analyst, cPanel Quality Assurance
I have this error when i try to edit the file from the shell with root access
and i have the message when i try to save the file
stat /etc/exim.conf
lsattr /etc/exim.confFile: `/etc/exim.conf'
Size: 43596 Blocks: 88 IO Block: 4096 regular file
Device: 811h/2065d Inode: 98403945 Links: 1
Access: (0644/-rw-r--r--) Uid: ( 0/ root) Gid: ( 0/ root)
Access: 2009-11-20 22:35:04.000000000 +0200
Modify: 2009-11-18 12:42:40.000000000 +0200
Change: 2009-11-19 01:13:51.000000000 +0200
-u---a------- /etc/exim.conf
Please note that it is not recommended to manually edit the Exim configuration file ("exim.conf") directly via command-line; custom changes will not be fully saved unless the configuration file is edited properly using the available features at the following menu paths in WHM:
WHM: Main >> Service Configuration >> Exim Configuration Editor
Documentation: EximConfig < AllDocumentation/WHMDocs < TWiki
WHM: Main >> Service Configuration >> Exim Configuration Editor >> Advanced Editor
Documentation: AdvancedExim < AllDocumentation/WHMDocs < TWiki
As seen via the output from "lsattr" (to list attributes) the file has two special attributes set, they are "a" and "u" and are described below as quoted from the Linux manual "man" page for "chattr":
- A file with the ‘a’ attribute set can only be open in append mode for writing. Only the superuser or a process possessing the CAP_LINUX_IMMUTABLE capability can set or clear this attribute.
- When a file with the ‘u’ attribute set is deleted, its contents are saved. This allows the user to ask for its undeletion. Note: please make sure to read the bugs and limitations section at the end of this document. ... BUGS AND LIMITATIONS: The ‘c’, ’s’, and ‘u’ attributes are not honored by the ext2 and ext3 filesystems as implemented in the current mainline Linux kernels. These attributes may be implemented in future versions of the ext2 and ext3 filesystems.
To read the manual or "man" page for "chattr" in full detail, please use the following command:
To fix the issue and proceed with editing via WHM it will be necessary to remove the special attributes using the utility "chattr" (to change attributes) in a command like the following example:Code:# man chattr
Code:# chattr -V -au /etc/exim.conf
cPResources: Submit a Support Request - Submit a Bug Report - Review existing Tickets-- Donald cPanelDon Holl - Analyst, cPanel Quality Assurance
Thanks for help![]()