Could not lock Apache configuration
I can't add a new domain or subdomain in my host with Cpanel and that error is:
And also I was problem in chmod command then I fixed it (with reinstalled coreutiles ) but I have this problem in cpanel again. Regards
exit level [die] [pid=8465] (Could not lock Apache configuration: Cpanel::Exception::IO::ChmodError/(XID bww8ch) The system failed to set the permissions on one or more immutable (+i) filesystem nodes to "0600" (as EUID: 0, EGID: 0) because of the following error: Operation not permitted at /usr/local/cpanel/Cpanel/Exception/CORE.pm line 330, <$socket> line 1. Cpanel::Exception::create("IO::ChmodError", ARRAY(0x3163148)) called at /usr/local/cpanel/Cpanel/Exception.pm line 46 Cpanel::Exception::__ANON__(__CPANEL_HIDDEN__, ARRAY(0x3163148)) called at /usr/local/cpanel/Cpanel/Autodie/Perms.pm line 38 Cpanel::Autodie::Perms::chmod(384, GLOB(0x3166340)) called at /usr/local/cpanel/Cpanel/Transaction/File/Base.pm line 167 Cpanel::Transaction::File::Base::_set_permissions(GLOB(0x3166340), 384, undef) called at /usr/local/cpanel/Cpanel/Transaction/File/Base.pm line 110 Cpanel::Transaction::File::Base::new("Cpanel::Transaction::File::Raw", "path", "/etc/apache2/conf/httpd.conf") called at /usr/local/cpanel/Cpanel/Transaction.pm line 19 eval {...} called at /usr/local/cpanel/Cpanel/Transaction.pm line 19 Cpanel::Transaction::get_httpd_conf() called at /usr/local/cpanel/Cpanel/ApacheConf.pm line 610 Cpanel::ApacheConf::_loadhttpdconf_and_transaction(undef) called at /usr/local/cpanel/Cpanel/ApacheConf.pm line 532 Cpanel::ApacheConf::loadhttpdconf() called at /usr/local/cpanel/Cpanel/HttpUtils/Domain.pm line 96 Cpanel::HttpUtils::Domain::domainExistsInConf_vhost_name("sub.mydomain.com") called at /usr/local/cpanel/Cpanel/Validate/Component/Domain/HasApacheConfEntry.pm line 44 Cpanel::Validate::Component::Domain::HasApacheConfEntry::validate(Cpanel::Validate::Component::Domain::HasApacheConfEntry=HASH(0x3078c78)) called at /usr/local/cpanel/Cpanel/Validate/Validator.pm line 45 Cpanel::Validate::Validator::validate(Cpanel::Validate::DomainCreation::Sub=HASH(0x3165f08)) called at /usr/local/cpanel/Cpanel/Sub.pm line 121 Cpanel::Sub::__ANON__() called at /usr/local/cpanel/3rdparty/perl/524/lib64/perl5/cpanel_lib/Try/Tiny.pm line 98 eval {...} called at /usr/local/cpanel/3rdparty/perl/524/lib64/perl5/cpanel_lib/Try/Tiny.pm line 89 Try::Tiny::try(CODE(0x313e000), Try::Tiny::Catch=REF(0x313de68)) called at /usr/local/cpanel/Cpanel/Sub.pm line 125 Cpanel::Sub::addsubdomain(__CPANEL_HIDDEN__, 0, __CPANEL_HIDDEN__, 1, __CPANEL_HIDDEN__, __CPANEL_HIDDEN__, __CPANEL_HIDDEN__, __CPANEL_HIDDEN__, ...) called at bin/admin/Cpanel/domain.pl line 199 main::__ANON__() called at /usr/local/cpanel/3rdparty/perl/524/lib64/perl5/cpanel_lib/Try/Tiny.pm line 94 eval {...} called at /usr/local/cpanel/3rdparty/perl/524/lib64/perl5/cpanel_lib/Try/Tiny.pm line 89 Try::Tiny::try(CODE(0x3123458), Try::Tiny::Catch=REF(0x164a038)) called at bin/admin/Cpanel/domain.pl line 212 )And also I was problem in chmod command then I fixed it (with reinstalled coreutiles ) but I have this problem in cpanel again. Regards
-
Hi, Have you locked the apache configuration manually? 0 -
Hi, Have you locked the apache configuration manually?
Thanks for your answer. If I rebuild it, I will lose my any info or configs?0 -
Hi, Take backup of the Apache configuration first and then check.. Because if you lock the Apache configuration, no virtual host entry would be creating and creating account will fail.. 0 -
Hi, Take backup of the Apache configuration first and then check.. Because if you lock the Apache configuration, no virtual host entry would be creating and creating account will fail..
Thank you:) So how I can do this job? And if I do it then Will cpanel response?0 -
Hello, Check to see if the immutable attribute is applied to the httpd.conf file with a command like this: lsattr /etc/apache2/conf/httpd.conf
If so, you can remove that immutable attribute with the following command:chattr -i /etc/apache2/conf/httpd.conf
Once you do this, you can rebuild the Apache configuration file with the following command:/scripts/rebuildhttpdconf
You will need to follow the instructions on the following document if you want to make custom changes to the Apache configuration: Advanced Apache Configuration - EasyApache 4 - cPanel Documentation Thank you.0
Please sign in to leave a comment.
Comments
5 comments