apache server wont start!

sotiri

Verified User
Joined
Aug 12, 2010
Messages
7
Hi everyone im new to directadmin with errors i've got this Error 3 days back ago and im still fighting to fix this problem when i start the httpd procces in directadmin it gives this error.

An error has occurred

Details

/sbin/service httpd restart 2>&1

en when im starting the procces through ssh i've got this i dont know wat this is i think a directadmin error.


[root@srv1 custombuild]# /sbin/service httpd restart
Stopping httpd: [ OK ]
Starting httpd: Syntax error on line 30 of /usr/local/directadmin/data/users/admin/httpd.conf:
Invalid command 'php_admin_flag', perhaps misspelled or defined by a module not included in the server configuration


The http.conf is:

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

# Frontpage requires these parameters in every httpd.conf file or else
# it won't work.
ServerRoot /etc/httpd



<VirtualHost XXXXXXXXXX>


ServerName www.media-networks.be
ServerAlias www.media-networks.be media-networks.be
ServerAdmin [email protected]
DocumentRoot /home/admin/domains/media-networks.be/public_html
ScriptAlias /cgi-bin/ /home/admin/domains/media-networks.be/public_html/cgi-bin/

UseCanonicalName OFF

SuexecUserGroup admin admin
CustomLog /var/log/httpd/domains/media-networks.be.bytes bytes
CustomLog /var/log/httpd/domains/media-networks.be.log combined
ErrorLog /var/log/httpd/domains/media-networks.be.error.log

<Directory /home/admin/domains/media-networks.be/public_html>
Options +Includes -Indexes

php_admin_flag engine on
<IfModule !mod_php6.c>
php_admin_flag safe_mode on
</IfModule>
php_admin_value sendmail_path '/usr/sbin/sendmail -t -i -f [email protected]'


php_admin_value open_basedir /home/admin/:/tmp:/var/tmp:/usr/local/lib/php/


</Directory>



</VirtualHost>

my system information is:

Centos 5.0.2
Processor Name Intel(R) Pentium(R) Dual CPU E2200 @ 2.20GHz
Vendor ID GenuineIntel
Processor Speed (MHz) 2194.548
Total Memory 255436 kB
Free Memory 76928 kB
Total Swap Memory 524280 kB
Free Swap Memory 490328 kB
System Uptime 1 Days, 7 Hours and 6 Minutes
Apache 2.2.15 *** Stopped ***
DirectAdmin 1.35.1 Running
Exim 4.67 Running
MySQL 5.0.67 Running
Named 9.3.6 Running
ProFTPd 1.3.1 Running
sshd Running
dovecot 1.2.11 Running
Php 5.2.13

and the build options of costumbuild r


[root@srv1 custombuild]# ./build options
Apache: 2.2.16
Dovecot: 1.2.13
AWstats: no
exim.conf update: no
MySQL: no
MySQL backup: yes
PHP: 5.2.14 as CLI with mail() header patch
phpMyAdmin: 3.3.5-all-languages
ProFTPD: no
Atmail webmail: no
RoundCube webmail: 0.4
Auto updates/notifications: no
Run "clean" every time: yes
Run "clean_old_webapps" every time: yes
Run "clean_old_tarballs" every time: no
Show texts in bold: yes
SquirrelMail: 1.4.21
UebiMiau: no
Zend Optimizer: no



Can somebody help me please??

thank you
 
Last edited:
I guess you have tried to up/down-grade apache/php ??

Problem is that apache configuration was changed: probabilly he have re-compiled apache with suPHP support instead of php with cli.

Error is in the virtual host that have "php_admin_flag": he must remove them
 
The problem was solved by the directadmin support team

They said

Hello,

I renamed your options.conf to be options.conf.moved, ran:
./build update
./build rewrite_confs

and apache started up.
There may be differences in what you had set and what is currently set in the options.conf, but I'll let you re-adjust as needed.

Thank you directadmin support team!!!

Let this topic open for other people with this common error.
 
Last edited:
The problem was solved by the directadmin support team

They said

Hello,

I renamed your options.conf to be options.conf.moved, ran:
./build update
./build rewrite_confs

and apache started up.
There may be differences in what you had set and what is currently set in the options.conf, but I'll let you re-adjust as needed.

Thank you directadmin support team!!!

Let this topic open for other people with this common error.

I also had the same problem with Apache not restarting after it's nightly tally run. The only recent work that was done on the server was a custombuild './build all' vs. just './build update_versions' and ended up cancelling out of the './build all' and maybe that left something partially configured.

I did what DA Support did, only copied back the options.conf because of some custom configs, reran './build rewrite_confs' and Apache started up ok and everything appears to be working good now.

Thanks DA Folks!

-bdk
 
The problem was solved by the directadmin support team

They said

Hello,

I renamed your options.conf to be options.conf.moved, ran:
./build update
./build rewrite_confs

and apache started up.
There may be differences in what you had set and what is currently set in the options.conf, but I'll let you re-adjust as needed.

Thank you directadmin support team!!!

Let this topic open for other people with this common error.

Still have this output

Starting httpd: httpd: Syntax error on line 17 of /etc/httpd/conf/httpd.conf: Syntax error on line 1 of /etc/httpd/conf/extra/httpd-phpmodules.conf: Cannot load /usr/lib/apache/libphp5.so into server: /usr/lib/apache/libphp5.so: undefined symbol: OnUpdateLong
 
Still have this output

Starting httpd: httpd: Syntax error on line 17 of /etc/httpd/conf/httpd.conf: Syntax error on line 1 of /etc/httpd/conf/extra/httpd-phpmodules.conf: Cannot load /usr/lib/apache/libphp5.so into server: /usr/lib/apache/libphp5.so: undefined symbol: OnUpdateLong

I resolved recompiling!
 
Back
Top