Author Topic: Errors arround httpd.conf || sharedip.conf || system-redirects.conf  (Read 5458 times)

0 Members and 1 Guest are viewing this topic.

Offline
*
Hi guys,
And hello everyone.
Well, I have been experiencing problems with my CWP, in which my httpd service does not start!
Initially problem show's me that:
Code: [Select]
May 14 12:58:01 webserverhousingdata.dynu.net systemd[1]: Starting Web server Apache...
May 14 12:58:01 webserverhousingdata.dynu.net apachectl[15924]: httpd: Syntax error on line 511 of /usr/local/apache/conf/httpd.conf: Syntax error on line 4 of /usr/local/apache/conf/sharedip.conf: Expected 500> but saw
May 14 12:58:01 webserverhousingdata.dynu.net systemd[1]: httpd.service: control process exited, code=exited status=1
May 14 12:58:01 webserverhousingdata.dynu.net systemd[1]: Failed to start Web server Apache.
May 14 12:58:01 webserverhousingdata.dynu.net systemd[1]: Unit httpd.service entered failed state.
May 14 12:58:01 webserverhousingdata.dynu.net systemd[1]: httpd.service failed.
a my full config  its in /usr/local/apache/conf/sharedip.conf
Code: [Select]
<VirtualHost  XXx.XXX.XX.XX:8181>
<html><head>
<title>500 Internal Server Error</title>
</head><body>
<h1>Internal Server Error</h1>
<p>The server encountered an internal error or
misconfiguration and was unable to complete
your request.</p>
<p>Please contact the server administrator,
 webmaster@centos-webpanel.com and inform them of the time the error occurred,
and anything you might have done that may have
caused the error.</p>
<p>More information about this error may be available
in the server error log.</p>
<p>Additionally, a 500 Internal Server Error
error was encountered while trying to use an ErrorDocument to handle the request.</p>
</body></html> XXx.XXX.XX.XX:8181>
    ServerName  XXx.XXX.XX.XX
<html><head>
<title>500 Internal Server Error</title>
</head><body>
<h1>Internal Server Error</h1>
<p>The server encountered an internal error or
misconfiguration and was unable to complete
your request.</p>
<p>Please contact the server administrator,
 webmaster@centos-webpanel.com and inform them of the time the error occurred,
and anything you might have done that may have
caused the error.</p>
<p>More information about this error may be available
in the server error log.</p>
<p>Additionally, a 500 Internal Server Error
error was encountered while trying to use an ErrorDocument to handle the request.</p>
</body></html>
    DocumentRoot /usr/local/apache/htdocs
    ServerAdmin info@centos-webpanel.com
    <IfModule mod_suphp.c>
        suPHP_UserGroup nobody nobody
    </IfModule>
    <Proxy "*">
        <IfModule mod_security2.c>
            SecRuleEngine Off
        </IfModule>
    </Proxy>
    RewriteEngine On
    RewriteCond %{HTTP_HOST} !^<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>500 Internal Server Error</title>
</head><body>
<h1>Internal Server Error</h1>
<p>The server encountered an internal error or
misconfiguration and was unable to complete
your request.</p>
<p>Please contact the server administrator,
 webmaster@centos-webpanel.com and inform them of the time the error occurred,
and anything you might have done that may have
caused the error.</p>
<p>More information about this error may be available
in the server error log.</p>
<p>Additionally, a 500 Internal Server Error
error was encountered while trying to use an ErrorDocument to handle the request.</p>
</body></html>$
    RewriteCond %{HTTP_HOST} ^webmail.
    RewriteRule ^/(.*) http://%{HTTP_HOST}:2095/$1 [P]
</VirtualHost>
<Directory "/">
        AllowOverride All
        Require all granted
</Directory>
that was giving me problems. So, I searched and replaced the configs in my file with this --> "https://forum.centos-webpanel.com/apache/apache-error-after-rebuild/"
like this
Code: [Select]
# NameVirtualHost  XXx.XXX.XX.XX:8181 # Deprecated
<VirtualHost  XXx.XXX.XX.XX:8181>
    ServerName  XXx.XXX.XX.XX
    DocumentRoot /usr/local/apache/htdocs
    ServerAdmin infoooooas@centos-webpanel.com
    <IfModule mod_suphp.c>
        suPHP_UserGroup nobody nobody
    </IfModule>
</VirtualHost>
<Directory "/">
        AllowOverride All
        Require all granted
</Directory>

After that, I rebooted the machine, the problem seemed partially solved, appeared to me another error, this time anything half bizarre ...
Code: [Select]
May 14 13:04:35 webserverhousingdata.dynu.net systemd[1]: Starting Web server Apache...
May 14 13:04:35 webserverhousingdata.dynu.net apachectl[17705]: httpd: Syntax error on line 512 of /usr/local/apache/conf/httpd.conf: Syntax error on line 4 of /usr/local/apache/conf.d/system-redirects.conf: Expected 500> but saw
May 14 13:04:35 webserverhousingdata.dynu.net systemd[1]: httpd.service: control process exited, code=exited status=1
May 14 13:04:35 webserverhousingdata.dynu.net systemd[1]: Failed to start Web server Apache.
May 14 13:04:35 webserverhousingdata.dynu.net systemd[1]: Unit httpd.service entered failed state.
May 14 13:04:35 webserverhousingdata.dynu.net systemd[1]: httpd.service failed.
First I'll show you the image of my "system-redirects.conf"


And now I show my setup of /usr/local/apache/conf.d/system-redirects.conf
Code: [Select]
Redirect permanent /myadmin http://<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>500 Internal Server Error</title>
</head><body>
<h1>Internal Server Error</h1>
<p>The server encountered an internal error or
misconfiguration and was unable to complete
your request.</p>
<p>Please contact the server administrator,
 webmaster@centos-webpanel.com and inform them of the time the error occurred,
and anything you might have done that may have
caused the error.</p>
<p>More information about this error may be available
in the server error log.</p>
<p>Additionally, a 500 Internal Server Error
error was encountered while trying to use an ErrorDocument to handle the request.</p>
</body></html>:2030/pma
Redirect permanent /MyAdmin http://<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>500 Internal Server Error</title>
</head><body>
<h1>Internal Server Error</h1>
<p>The server encountered an internal error or
misconfiguration and was unable to complete
your request.</p>
<p>Please contact the server administrator,
 webmaster@centos-webpanel.com and inform them of the time the error occurred,
and anything you might have done that may have
caused the error.</p>
<p>More information about this error may be available
in the server error log.</p>
<p>Additionally, a 500 Internal Server Error
error was encountered while trying to use an ErrorDocument to handle the request.</p>
</body></html>:2030/pma
Redirect permanent /phpmyadmin http://<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>500 Internal Server Error</title>
</head><body>
<h1>Internal Server Error</h1>
<p>The server encountered an internal error or
misconfiguration and was unable to complete
your request.</p>
<p>Please contact the server administrator,
 webmaster@centos-webpanel.com and inform them of the time the error occurred,
and anything you might have done that may have
caused the error.</p>
<p>More information about this error may be available
in the server error log.</p>
<p>Additionally, a 500 Internal Server Error
error was encountered while trying to use an ErrorDocument to handle the request.</p>
</body></html>:2030/pma
Redirect permanent /phpMyAdmin http://<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>500 Internal Server Error</title>
</head><body>
<h1>Internal Server Error</h1>
<p>The server encountered an internal error or
misconfiguration and was unable to complete
your request.</p>
<p>Please contact the server administrator,
 webmaster@centos-webpanel.com and inform them of the time the error occurred,
and anything you might have done that may have
caused the error.</p>
<p>More information about this error may be available
in the server error log.</p>
<p>Additionally, a 500 Internal Server Error
error was encountered while trying to use an ErrorDocument to handle the request.</p>
</body></html>:2030/pma
Redirect permanent /kpanel http://<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>500 Internal Server Error</title>
</head><body>
<h1>Internal Server Error</h1>
<p>The server encountered an internal error or
misconfiguration and was unable to complete
your request.</p>
<p>Please contact the server administrator,
 webmaster@centos-webpanel.com and inform them of the time the error occurred,
and anything you might have done that may have
caused the error.</p>
<p>More information about this error may be available
in the server error log.</p>
<p>Additionally, a 500 Internal Server Error
error was encountered while trying to use an ErrorDocument to handle the request.</p>
</body></html>:2030/
Redirect permanent /cwp http://<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>500 Internal Server Error</title>
</head><body>
<h1>Internal Server Error</h1>
<p>The server encountered an internal error or
misconfiguration and was unable to complete
your request.</p>
<p>Please contact the server administrator,
 webmaster@centos-webpanel.com and inform them of the time the error occurred,
and anything you might have done that may have
caused the error.</p>
<p>More information about this error may be available
in the server error log.</p>
<p>Additionally, a 500 Internal Server Error
error was encountered while trying to use an ErrorDocument to handle the request.</p>
</body></html>:2082/
Redirect permanent /isp http://<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>500 Internal Server Error</title>
</head><body>
<h1>Internal Server Error</h1>
<p>The server encountered an internal error or
misconfiguration and was unable to complete
your request.</p>
<p>Please contact the server administrator,
 webmaster@centos-webpanel.com and inform them of the time the error occurred,
and anything you might have done that may have
caused the error.</p>
<p>More information about this error may be available
in the server error log.</p>
<p>Additionally, a 500 Internal Server Error
error was encountered while trying to use an ErrorDocument to handle the request.</p>
</body></html>:2030/
Redirect permanent /cpanel http://<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>500 Internal Server Error</title>
</head><body>
<h1>Internal Server Error</h1>
<p>The server encountered an internal error or
misconfiguration and was unable to complete
your request.</p>
<p>Please contact the server administrator,
 webmaster@centos-webpanel.com and inform them of the time the error occurred,
and anything you might have done that may have
caused the error.</p>
<p>More information about this error may be available
in the server error log.</p>
<p>Additionally, a 500 Internal Server Error
error was encountered while trying to use an ErrorDocument to handle the request.</p>
</body></html>:2082/
Redirect permanent /scwp https://<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>500 Internal Server Error</title>
</head><body>
<h1>Internal Server Error</h1>
<p>The server encountered an internal error or
misconfiguration and was unable to complete
your request.</p>
<p>Please contact the server administrator,
 webmaster@centos-webpanel.com and inform them of the time the error occurred,
and anything you might have done that may have
caused the error.</p>
<p>More information about this error may be available
in the server error log.</p>
<p>Additionally, a 500 Internal Server Error
error was encountered while trying to use an ErrorDocument to handle the request.</p>
</body></html>:2083/
Redirect permanent /controlpanel http://<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>500 Internal Server Error</title>
</head><body>
<h1>Internal Server Error</h1>
<p>The server encountered an internal error or
misconfiguration and was unable to complete
your request.</p>
<p>Please contact the server administrator,
 webmaster@centos-webpanel.com and inform them of the time the error occurred,
and anything you might have done that may have
caused the error.</p>
<p>More information about this error may be available
in the server error log.</p>
<p>Additionally, a 500 Internal Server Error
error was encountered while trying to use an ErrorDocument to handle the request.</p>
</body></html>:2082/
Redirect permanent /securecontrolpanel https://<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>500 Internal Server Error</title>
</head><body>
<h1>Internal Server Error</h1>
<p>The server encountered an internal error or
misconfiguration and was unable to complete
your request.</p>
<p>Please contact the server administrator,
 webmaster@centos-webpanel.com and inform them of the time the error occurred,
and anything you might have done that may have
caused the error.</p>
<p>More information about this error may be available
in the server error log.</p>
<p>Additionally, a 500 Internal Server Error
error was encountered while trying to use an ErrorDocument to handle the request.</p>
</body></html>:2083/
Redirect permanent /securewhm https://<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>500 Internal Server Error</title>
</head><body>
<h1>Internal Server Error</h1>
<p>The server encountered an internal error or
misconfiguration and was unable to complete
your request.</p>
<p>Please contact the server administrator,
 webmaster@centos-webpanel.com and inform them of the time the error occurred,
and anything you might have done that may have
caused the error.</p>
<p>More information about this error may be available
in the server error log.</p>
<p>Additionally, a 500 Internal Server Error
error was encountered while trying to use an ErrorDocument to handle the request.</p>
</body></html>:2031/
Redirect permanent /whm http://<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>500 Internal Server Error</title>
</head><body>
<h1>Internal Server Error</h1>
<p>The server encountered an internal error or
misconfiguration and was unable to complete
your request.</p>
<p>Please contact the server administrator,
 webmaster@centos-webpanel.com and inform them of the time the error occurred,
and anything you might have done that may have
caused the error.</p>
<p>More information about this error may be available
in the server error log.</p>
<p>Additionally, a 500 Internal Server Error
error was encountered while trying to use an ErrorDocument to handle the request.</p>
</body></html>:2030/
I was looking for it, after all I had an option to "restore" -> to default values, and that's what I did.
At the bottom of this section you have this option
Like in image below:


And voila! What is the status of my "httpd" service?
Its working for now:

« Last Edit: May 14, 2019, 12:35:14 PM by OnlyHard »

Offline
*
how did you got this config files to have html content in it ?
VPS & Dedicated server provider with included FREE Managed support for CWP.
http://www.studio4host.com/

*** Don't allow that your server or website is down, choose hosting provider with included expert managed support for your CWP.

Offline
*
how did you got this config files to have html content in it ?

I do not know! The truth is this !!
But I managed to solve my problem!