We have a problem with httpd

Niels90

Verified User
Joined
Apr 22, 2016
Messages
13
Dear Sir / Madam,

We have a problem with httpd
AH00526: Syntax error on line 43 of /usr/local/directadmin/data/users/admin/httpd.conf:
<VirtualHost> cannot occur within <VirtualHost> section

A ./build rewrite_confs from admin/httpd.conf does not yet receive the error

AH00526: Syntax error on line 43 of /usr/local/directadmin/data/users/admin/httpd.conf:
<VirtualHost> cannot occur within <VirtualHost> section


Apache 2.4.20
DirectAdmin 1.50.0
Exim 4.87
MySQL 5.5.31
Named 9.8.2rc1
dovecot 2.2.23 (806d709)
pure-ftpd 1.0.42
Php 5.5.34

you know a solution?

I hope to have informed you sufficiently.

Sincerely,
Niels90
 
AH00526: Syntax error on line 43 of /usr/local/directadmin/data/users/admin/httpd.conf:
Since line 43 is giving the error, what does line 43 say?
It normally should point to a Customlog statement.

Did you make any manual changes on virtualhost or made an entry or addition via the DA control panel?
 
Since line 43 is giving the error, what does line 43 say?
It normally should point to a Customlog statement.

Did you make any manual changes on virtualhost or made an entry or addition via the DA control panel?

AH00526: Syntax error on line 43 of /usr/local/directadmin/data/users/admin/httpd.conf:
<VirtualHost> cannot occur within <VirtualHost> section
 
Post what your line 43 of /usr/local/directadmin/data/users/admin/httpd.conf, posting the error you are getting again doesn't help. Perhaps even better, post your /usr/local/directadmin/data/users/admin/httpd.conf file and we should be able to see the problem.
 
Hello,

It seems you have inserted a custom code for a domain in Directadmin. Go to admin level and check it.
I don't see any reason on why you have <VirtualHost> within <VirtualHost> section.

AH00526: Syntax error on line 43 of /usr/local/directadmin/data/users/admin/httpd.conf:
<VirtualHost> cannot occur within <VirtualHost> section
 
Post what your line 43 of /usr/local/directadmin/data/users/admin/httpd.conf, posting the error you are getting again doesn't help. Perhaps even better, post your /usr/local/directadmin/data/users/admin/httpd.conf file and we should be able to see the problem.

<VirtualHost ****:80 >
ServerName www.powerweb4you.nl
ServerAlias www.powerweb4you.nl powerweb4you.nl
ServerAdmin [email protected]
DocumentRoot /home/admin/domains/powerweb4you.nl/public_html
ScriptAlias /cgi-bin/ /home/admin/domains/powerweb4you.nl/public_html/cgi-bin/
UseCanonicalName OFF
<IfModule !mod_ruid2.c>
SuexecUserGroup admin admin
</IfModule>
<IfModule mod_ruid2.c>
RMode config
RUidGid admin admin
#RGroups apache access
RGroups @none
</IfModule>
CustomLog /var/log/httpd/domains/powerweb4you.nl.bytes bytes
CustomLog /var/log/httpd/domains/powerweb4you.nl.log combined
ErrorLog /var/log/httpd/domains/powerweb4you.nl.error.log
<Directory /home/admin/domains/powerweb4you.nl/public_html>
php_admin_flag engine ON
php_admin_value sendmail_path '/usr/sbin/sendmail -t -i -f [email protected]'
php_admin_value mail.log /home/admin/.php/php-mail.log
php_admin_value open_basedir /home/admin/:/tmp:/var/tmp:/usr/local/lib/php/:/usr/local/php55/lib/php/
</Directory>
</VirtualHost>
<VirtualHost ****:443 >
SSLEngine on
SSLCertificateFile /etc/httpd/conf/ssl.crt/server.crt
SSLCertificateKeyFile /etc/httpd/conf/ssl.key/server.key
SSLCACertificateFile /etc/httpd/conf/ssl.crt/server.ca
ServerName www.powerweb4you.nl
ServerAlias www.powerweb4you.nl powerweb4you.nl
ServerAdmin [email protected]
DocumentRoot /home/admin/domains/powerweb4you.nl/private_html
ScriptAlias /cgi-bin/ /home/admin/domains/powerweb4you.nl/public_html/cgi-bin/
UseCanonicalName OFF
<IfModule !mod_ruid2.c>
SuexecUserGroup admin admin
</IfModule>
<IfModule mod_ruid2.c>
RMode config
RUidGid admin admin
#RGroups apache access
RGroups @none
</IfModule>
CustomLog /var/log/httpd/domains/powerweb4you.nl.bytes bytes
CustomLog /var/log/httpd/domains/powerweb4you.nl.log combined
ErrorLog /var/log/httpd/domains/powerweb4you.nl.error.log
<Directory /home/admin/domains/powerweb4you.nl/private_html>
php_admin_flag engine ON
php_admin_value sendmail_path '/usr/sbin/sendmail -t -i -f [email protected]'
php_admin_value mail.log /home/admin/.php/php-mail.log
php_admin_value open_basedir /home/admin/:/tmp:/var/tmp:/usr/local/lib/php/:/usr/local/php55/lib/php/
</Directory>
</VirtualHost>
 
Hello,

It seems you have inserted a custom code for a domain in Directadmin. Go to admin level and check it.
I don't see any reason on why you have <VirtualHost> within <VirtualHost> section.

stand twice, in httpd.conf
it should only be DirectAdmin version 1.50.0

but there is DirectAdmin version 1.50.0 and DirectAdmin version 1.48.3 httpd.conf



# Auto generated apache config file by DirectAdmin version 1.50.0
# Modifying this file is not recommended as any changes you make will be
# overwritten when the user makes any changes to their website

# For global config changes that affect all Users, see this guide:
# http://help.directadmin.com/item.php?id=2
# For local config changes that only affect one User, see this guide:
# http://help.directadmin.com/item.php?id=3


<Directory "/home/admin/public_html">
<IfModule mod_ruid2.c>
RMode config
RUidGid admin admin
#RGroups apache access
RGroups @none
</IfModule>
<IfModule mod_fcgid.c>
SuexecUserGroup admin admin
</IfModule>
php_admin_flag engine ON
php_admin_value sendmail_path '/usr/sbin/sendmail -t -i -f [email protected]'
php_admin_value mail.log /home/admin/.php/php-mail.log
php_admin_value open_basedir /home/admin/:/tmp:/var/tmp:/usr/local/lib/php/:/usr/local/php55/lib/php/
</Directory>

# Auto generated apache config file by DirectAdmin version 1.48.3
# Modifying this file is not recommended as any changes you make will be
# overwritten when the user makes any changes to his/her website
# For global config changes that affect all Users, see this guide:
# http://help.directadmin.com/item.php?id=2
# For local config changes that only affect one User, see this guide:
# http://help.directadmin.com/item.php?id=3
<Directory "/home/admin/public_html">
<IfModule mod_ruid2.c>
RMode config
RUidGid admin admin
#RGroups apache access
RGroups @none
</IfModule>
<IfModule mod_fcgid.c>
SuexecUserGroup admin admin
</IfModule>
</Directory>
 
Your line 43 of the httpd.conf you posted doesn't even have a VirtualHost tag, did you include the whole httpd.conf including comments? If so, post the real file, since we can all do an nslookup of your serveralias/servername, hiding your IP address does nothing.
 
Back
Top