LxCenter HyperVM & Kloxo Support

Forum



Members   Search      Help    Register    Login    Home
Home » Kloxo Community Support » Technical Help » [URGENT] Apache dies because of incorrect configuration files
[URGENT] Apache dies because of incorrect configuration files [message #96478] Tue, 13 March 2012 05:58 Go to next message
Spacedust is currently offline Spacedust  Poland
Messages: 1233
Registered: October 2007
Location: Poland
Senior Master
Today I got this:

Starting httpd: Syntax error on line 30 of /home/apache/conf/domains/zino36
RUidGid takes two arguments, Minimal uid or gid file/dir, else set[ug]id to defr,Group)
[FAILED]

Apache is creating files in /home/apache/conf/domains/ without domains just without user name which is incorrect. This is not being done the same day after adding the customer, the file is created few hours later and you never know when it's going to be created.

This is causing Apache to stop right away !

I'm using Kloxo 6.1.12 Enterprise, CentOS 5.8 64-bit, httpd 2.2.22 from Lxrepo, mod_ruid2

This is happening on master, but slaves might be affected as well.

Example file with this error: http://project.lxcenter.org/attachments/180/apache.txt
Re: [URGENT] Apache dies because of incorrect configuration files [message #96493 is a reply to message #96478] Tue, 13 March 2012 10:48 Go to previous messageGo to next message
Spacedust is currently offline Spacedust  Poland
Messages: 1233
Registered: October 2007
Location: Poland
Senior Master
I wrote a script to fix this, but have taken me a few hours !!!
Re: [URGENT] Apache dies because of incorrect configuration files [message #96494 is a reply to message #96493] Tue, 13 March 2012 11:06 Go to previous messageGo to next message
shazar is currently offline shazar  United States
Messages: 1856
Registered: May 2011
Grandmaster
LxCenter Core Team Member
LxCenter Representative
Did you run any kind of fix script or something that caused this? Can you recreate this?

https://www.mercuryvps.com
HyperVM Xen VPS hosting
Re: [URGENT] Apache dies because of incorrect configuration files [message #96503 is a reply to message #96494] Tue, 13 March 2012 12:27 Go to previous messageGo to next message
Spacedust is currently offline Spacedust  Poland
Messages: 1233
Registered: October 2007
Location: Poland
Senior Master
shazar wrote on Tue, 13 March 2012 16:06
Did you run any kind of fix script or something that caused this? Can you recreate this?


No this just happens itself. It happens in early morning hours when I was sleeping. Then happend again during work time, so I was able to correct this (that was the same customer file).

[Updated on: Tue, 13 March 2012 12:27]

Report message to a moderator

Re: [URGENT] Apache dies because of incorrect configuration files [message #96507 is a reply to message #96503] Tue, 13 March 2012 12:54 Go to previous messageGo to next message
shazar is currently offline shazar  United States
Messages: 1856
Registered: May 2011
Grandmaster
LxCenter Core Team Member
LxCenter Representative
Try out the addon domains to see if it recreates this. I had commited code to fix this and I thought it made it to 6.1.11.

https://www.mercuryvps.com
HyperVM Xen VPS hosting
Re: [URGENT] Apache dies because of incorrect configuration files [message #96513 is a reply to message #96507] Tue, 13 March 2012 14:46 Go to previous messageGo to next message
lupetalo is currently offline lupetalo  
Messages: 252
Registered: April 2011
Senior Member
For how long Developers are going to ignore this. There is at least two other topics about this. Bit no it is not happening because devs cant reproduce it....
Re: [URGENT] Apache dies because of incorrect configuration files [message #96516 is a reply to message #96513] Tue, 13 March 2012 16:16 Go to previous messageGo to next message
shazar is currently offline shazar  United States
Messages: 1856
Registered: May 2011
Grandmaster
LxCenter Core Team Member
LxCenter Representative
I had reproduced it and I fixed a very similar issue as I stated in my previous post. This is why I am asking. If you don't have anything to add to the conversation that is helpful, please don't post.

https://www.mercuryvps.com
HyperVM Xen VPS hosting
Re: [URGENT] Apache dies because of incorrect configuration files [message #96524 is a reply to message #96516] Tue, 13 March 2012 17:39 Go to previous messageGo to next message
Spacedust is currently offline Spacedust  Poland
Messages: 1233
Registered: October 2007
Location: Poland
Senior Master
So please release 6.1.13 with this fix quickly. This is really a must have. Now with my autofix script I'm 100% safe that Apache won't go down, but this must be fixed for other users.

Please write here: http://project.lxcenter.org/issues/953#change-4294 or Danny will tell me again that I'm reporting non-existing bugs.

[Updated on: Tue, 13 March 2012 17:40]

Report message to a moderator

Re: [URGENT] Apache dies because of incorrect configuration files [message #96557 is a reply to message #96524] Wed, 14 March 2012 07:17 Go to previous messageGo to next message
shazar is currently offline shazar  United States
Messages: 1856
Registered: May 2011
Grandmaster
LxCenter Core Team Member
LxCenter Representative
You have to tell me how to reproduce it and just just tell me you wake up and it is broken.

https://www.mercuryvps.com
HyperVM Xen VPS hosting
Re: [URGENT] Apache dies because of incorrect configuration files [message #96565 is a reply to message #96557] Wed, 14 March 2012 07:51 Go to previous messageGo to next message
Spacedust is currently offline Spacedust  Poland
Messages: 1233
Registered: October 2007
Location: Poland
Senior Master
Use Apache driver. Create new customer, try to add some new domains, subdomains, delete them, add parked domains and delete them. Then the error should pop out.

[Updated on: Wed, 14 March 2012 07:51]

Report message to a moderator

Re: [URGENT] Apache dies because of incorrect configuration files [message #96576 is a reply to message #96565] Wed, 14 March 2012 09:00 Go to previous messageGo to next message
shazar is currently offline shazar  United States
Messages: 1856
Registered: May 2011
Grandmaster
LxCenter Core Team Member
LxCenter Representative
Can you try to narrow it down for me? For example if you create a new customer and add some new domains does it do it? Or do you have to add subdomains? Or parked domains. I don't think it it just all of them together. If you can do it it will help me. If you can't, then it will take longer for me to fix.

It seems this error would be caused by one specific action not a combination and I don't think adding domains does this.


https://www.mercuryvps.com
HyperVM Xen VPS hosting

[Updated on: Wed, 14 March 2012 09:01]

Report message to a moderator

Re: [URGENT] Apache dies because of incorrect configuration files [message #96581 is a reply to message #96576] Wed, 14 March 2012 10:02 Go to previous messageGo to next message
Spacedust is currently offline Spacedust  Poland
Messages: 1233
Registered: October 2007
Location: Poland
Senior Master
shazar wrote on Wed, 14 March 2012 14:00
Can you try to narrow it down for me? For example if you create a new customer and add some new domains does it do it? Or do you have to add subdomains? Or parked domains. I don't think it it just all of them together. If you can do it it will help me. If you can't, then it will take longer for me to fix.

It seems this error would be caused by one specific action not a combination and I don't think adding domains does this.


I can't really tell. I will check action logs of this affected customer Wink
Re: [URGENT] Apache dies because of incorrect configuration files [message #96583 is a reply to message #96581] Wed, 14 March 2012 10:08 Go to previous messageGo to next message
Spacedust is currently offline Spacedust  Poland
Messages: 1233
Registered: October 2007
Location: Poland
Senior Master
Here you are:

16:50 13 Mar 	xxx.xx.236.31 	mistrz_bi 		domain 	games.xxx.pl 	add 	
16:49 13 Mar 	xxx.xx.236.31 	mistrz_bi 		domain 	gry.xxx.pl 	delete 	
16:49 13 Mar 	xxx.xx.236.31 	mistrz_bi 		domain 	games.xxx.pl 	delete 	
16:47 13 Mar 	xxx.xx.236.31 	mistrz_bi 		domain 	games.xxx.pl 	add 
14:29 13 Mar 	xxx.xx.236.31 	mistrz_bi 		domain 	global.xxx.pl 	add 	
14:27 13 Mar 	xxx.xx.236.31 	mistrz_bi 		domain 	turysta.xxx.pl 	add 	
14:24 13 Mar 	xxx.xx.236.31 	mistrz_bi 		domain 	sport.xxx.pl 	add 	
14:24 13 Mar 	xxx.xx.236.31 	mistrz_bi 		domain 	praca.xxx.pl 	add 	
14:23 13 Mar 	xxx.xx.236.31 	mistrz_bi 		domain 	plotki.xxx.pl 	add 	
14:22 13 Mar 	xxx.xx.236.31 	mistrz_bi 		domain 	moto.xxx.pl 	add 	
14:21 13 Mar 	xxx.xx.236.31 	mistrz_bi 		domain 	komputery.xxx.pl 	add 	
14:20 13 Mar 	xxx.xx.236.31 	mistrz_bi 		domain 	kobieta.xxx.pl 	add 	
14:19 13 Mar 	xxx.xx.236.31 	mistrz_bi 		domain 	gry.xxx.pl 	add 	
14:19 13 Mar 	xxx.xx.236.31 	mistrz_bi 		domain 	gry.biznes.xxx.pl 	delete 	
14:18 13 Mar 	xxx.xx.236.31 	mistrz_bi 		domain 	gry.biznes.xxx.pl 	add 	
14:18 13 Mar 	xxx.xx.236.31 	mistrz_bi 		domain 	biznes.xxx.pl 	add 	
14:15 13 Mar 	xxx.xx.236.31 	mistrz_bi 		domain 	filmy.xxx.pl 	add 
< another server crash > 
11:27 13 Mar 	xxx.xx.236.31 	mistrz_bi 		domain 	filmy.mistrzbi.xxx.pl 	delete 
< server crash > 
18:02 12 Mar 	xx.xx.13.214 	mistrz_bi 		domain 	filmy.mistrzbi.xxx.pl 	add 	
17:58 12 Mar 	xx.xx.61.19 	admin 		client 	mistrz_bi 	update 	information 
16:13 12 Mar 	xx.xx.13.214 	mistrz_bi 	client 	mistrz_bi 	update 	password
15:49 12 Mar 	xx.xx.61.19 	admin 		client 	mistrz_bi 	add 	
Re: [URGENT] Apache dies because of incorrect configuration files [message #96584 is a reply to message #96583] Wed, 14 March 2012 10:14 Go to previous messageGo to next message
shazar is currently offline shazar  United States
Messages: 1856
Registered: May 2011
Grandmaster
LxCenter Core Team Member
LxCenter Representative
That doesn't tell me much...

I just need to know a single action that causes this.


https://www.mercuryvps.com
HyperVM Xen VPS hosting
Re: [URGENT] Apache dies because of incorrect configuration files [message #96585 is a reply to message #96584] Wed, 14 March 2012 10:33 Go to previous messageGo to next message
Spacedust is currently offline Spacedust  Poland
Messages: 1233
Registered: October 2007
Location: Poland
Senior Master
Seems to be just adding one domain.
Re: [URGENT] Apache dies because of incorrect configuration files [message #96595 is a reply to message #96585] Wed, 14 March 2012 15:52 Go to previous messageGo to next message
Spacedust is currently offline Spacedust  Poland
Messages: 1233
Registered: October 2007
Location: Poland
Senior Master
Got it right now, but my magic script saved my webserver from crashing:

The client just updated his php settings:

20:46 14 Mar 	89.70.2.xx 	zino36 		domain 	dobrexxx.com.pl 	update 	phpinfo 

[Updated on: Wed, 14 March 2012 15:53]

Report message to a moderator

Re: [URGENT] Apache dies because of incorrect configuration files [message #96596 is a reply to message #96595] Wed, 14 March 2012 15:56 Go to previous messageGo to next message
shazar is currently offline shazar  United States
Messages: 1856
Registered: May 2011
Grandmaster
LxCenter Core Team Member
LxCenter Representative
Can you test this yourself so if I do give you a fix, you can easily test it?

https://www.mercuryvps.com
HyperVM Xen VPS hosting
Re: [URGENT] Apache dies because of incorrect configuration files [message #96604 is a reply to message #96596] Wed, 14 March 2012 18:26 Go to previous messageGo to next message
Spacedust is currently offline Spacedust  Poland
Messages: 1233
Registered: October 2007
Location: Poland
Senior Master
Tested - nothing happens...
ao lot quan ao thoi trang cho be ban buon ban buon chup anh studio o ha noi

[Updated on: Fri, 03 May 2013 15:05]

Report message to a moderator

Re: [URGENT] Apache dies because of incorrect configuration files [message #96607 is a reply to message #96604] Wed, 14 March 2012 19:17 Go to previous messageGo to next message
shazar is currently offline shazar  United States
Messages: 1856
Registered: May 2011
Grandmaster
LxCenter Core Team Member
LxCenter Representative
Well keep trying. If you can do this, then it will make it easier for me to find the problem and fix it.

https://www.mercuryvps.com
HyperVM Xen VPS hosting
Re: [URGENT] Apache dies because of incorrect configuration files [message #96672 is a reply to message #96607] Fri, 16 March 2012 05:47 Go to previous messageGo to next message
Spacedust is currently offline Spacedust  Poland
Messages: 1233
Registered: October 2007
Location: Poland
Senior Master
Again today, my script fixes again !

Syntax error on line 30 of /home/apache/conf/domains/zino36.conf:
RUidGid takes two arguments, Minimal uid or gid file/dir, else set[ug]id to default (User,Group)


19:17 15 Mar 	89.70.2.xx 	zino36 		domain 	noclegi.xxx.pl 	update 	phpinfo
19:17 15 Mar 	89.70.2.xx 	zino36 		domain 	turystykaixxx.pl 	update 	phpinfo
19:17 15 Mar 	89.70.2.xx 	zino36 		domain 	noclegi.xxx.pl 	update 	phpinfo 

[Updated on: Fri, 16 March 2012 05:48]

Report message to a moderator

Re: [URGENT] Apache dies because of incorrect configuration files [message #96676 is a reply to message #96672] Fri, 16 March 2012 06:54 Go to previous messageGo to next message
shazar is currently offline shazar  United States
Messages: 1856
Registered: May 2011
Grandmaster
LxCenter Core Team Member
LxCenter Representative
You still don't seem to understand that I will not spend hours on this problem just to reproduce it myself. I need a very specific set of instructions on how to reproduce it.

https://www.mercuryvps.com
HyperVM Xen VPS hosting
Re: [URGENT] Apache dies because of incorrect configuration files [message #96693 is a reply to message #96676] Fri, 16 March 2012 10:38 Go to previous messageGo to next message
Spacedust is currently offline Spacedust  Poland
Messages: 1233
Registered: October 2007
Location: Poland
Senior Master
I'm still trying, but when I change myself PHP settings on this customer then it's all working ok.
do lot rbi quan lot nam goi cam xe day cho be vay lien cong so nu ban buon cho thue trang phuc bieu dien

[Updated on: Fri, 03 May 2013 15:05]

Report message to a moderator

Re: [URGENT] Apache dies because of incorrect configuration files [message #96757 is a reply to message #96693] Sun, 18 March 2012 10:04 Go to previous messageGo to next message
shazar is currently offline shazar  United States
Messages: 1856
Registered: May 2011
Grandmaster
LxCenter Core Team Member
LxCenter Representative
Spacedust - Hmm looks like my patch did not make it to 6.1.11 as I thought it did. Looking into that little more.

https://www.mercuryvps.com
HyperVM Xen VPS hosting
Re: [URGENT] Apache dies because of incorrect configuration files [message #96758 is a reply to message #96757] Sun, 18 March 2012 10:16 Go to previous messageGo to next message
shazar is currently offline shazar  United States
Messages: 1856
Registered: May 2011
Grandmaster
LxCenter Core Team Member
LxCenter Representative
Here is the file that shuld correct the issue that is in dev. It looks like it never made it to master.

https://github.com/lxcenter/kloxo/raw/dev/kloxo/httpdocs/lib /domain/addondomainlib.php


https://www.mercuryvps.com
HyperVM Xen VPS hosting
Re: [URGENT] Apache dies because of incorrect configuration files [message #96763 is a reply to message #96758] Sun, 18 March 2012 11:31 Go to previous messageGo to next message
lupetalo is currently offline lupetalo  
Messages: 252
Registered: April 2011
Senior Member
And just copu that over addondomainlib.php file?
Re: [URGENT] Apache dies because of incorrect configuration files [message #96764 is a reply to message #96763] Sun, 18 March 2012 11:33 Go to previous messageGo to next message
shazar is currently offline shazar  United States
Messages: 1856
Registered: May 2011
Grandmaster
LxCenter Core Team Member
LxCenter Representative
yes or you can look for

$web->setUpdateSubaction('full_update');

and replace it with

//Issue #863 removes problematic full_update
//$web->setUpdateSubaction('full_update');



https://www.mercuryvps.com
HyperVM Xen VPS hosting
Re: [URGENT] Apache dies because of incorrect configuration files [message #96767 is a reply to message #96764] Sun, 18 March 2012 13:27 Go to previous messageGo to next message
Spacedust is currently offline Spacedust  Poland
Messages: 1233
Registered: October 2007
Location: Poland
Senior Master
Thank you. I will report if this error pop out again.
do lot vera ao lot nam sieu mong tui ngu cho be thoi trang cong so nu ao so mi cong so chup anh cho be re dep

[Updated on: Fri, 03 May 2013 15:04]

Report message to a moderator

Re: [URGENT] Apache dies because of incorrect configuration files [message #96779 is a reply to message #96767] Sun, 18 March 2012 17:37 Go to previous messageGo to next message
shazar is currently offline shazar  United States
Messages: 1856
Registered: May 2011
Grandmaster
LxCenter Core Team Member
LxCenter Representative
Please also report if this works. It has already been tested and I have tested it quite a bit today and still works for me.

https://www.mercuryvps.com
HyperVM Xen VPS hosting
Re: [URGENT] Apache dies because of incorrect configuration files [message #96780 is a reply to message #96779] Sun, 18 March 2012 18:01 Go to previous messageGo to next message
Spacedust is currently offline Spacedust  Poland
Messages: 1233
Registered: October 2007
Location: Poland
Senior Master
No issues so far, I need more testing.
Re: [URGENT] Apache dies because of incorrect configuration files [message #97066 is a reply to message #96780] Sun, 25 March 2012 18:28 Go to previous messageGo to next message
Spacedust is currently offline Spacedust  Poland
Messages: 1233
Registered: October 2007
Location: Poland
Senior Master
It's causing Internal Server Error when adding domain...
Re: [URGENT] Apache dies because of incorrect configuration files [message #97067 is a reply to message #97066] Sun, 25 March 2012 18:31 Go to previous messageGo to next message
Spacedust is currently offline Spacedust  Poland
Messages: 1233
Registered: October 2007
Location: Poland
Senior Master
It's ok now. It was my 2 GB logs again....
Re: [URGENT] Apache dies because of incorrect configuration files [message #97388 is a reply to message #97067] Thu, 05 April 2012 02:29 Go to previous messageGo to next message
lupetalo is currently offline lupetalo  
Messages: 252
Registered: April 2011
Senior Member
And again it happened!
User added subdomain and deleted it and apache went down. When is this are going to be realy fixed!
Re: [URGENT] Apache dies because of incorrect configuration files [message #97391 is a reply to message #97388] Thu, 05 April 2012 03:25 Go to previous messageGo to next message
lupetalo is currently offline lupetalo  Serbia
Messages: 252
Registered: April 2011
Senior Member
http://project.lxcenter.org/issues/863
no use of this, still happening. Spacedust can you point me to your failsafe script?
Re: [URGENT] Apache dies because of incorrect configuration files [message #97403 is a reply to message #97391] Thu, 05 April 2012 10:38 Go to previous messageGo to next message
shazar is currently offline shazar  United States
Messages: 1856
Registered: May 2011
Grandmaster
LxCenter Core Team Member
LxCenter Representative
Are you sure it doesn't work? If you did what I wrote before the 6.1.12 update, then the update would have overwritten your changes.

https://www.mercuryvps.com
HyperVM Xen VPS hosting
Re: [URGENT] Apache dies because of incorrect configuration files [message #97405 is a reply to message #96478] Thu, 05 April 2012 11:55 Go to previous messageGo to next message
Spacedust is currently offline Spacedust  Poland
Messages: 1233
Registered: October 2007
Location: Poland
Senior Master
Is started to happen to me too !

Here's the code, replace mail@domain.com with your e-mail:

Save this as a webcheck.sh in /root and add to cron job:

* * * * * sh /root/webcheck.sh


#!/bin/bash
if /etc/init.d/httpd start 2> /tmp/webcheck.sh
cat /tmp/webcheck.sh | grep /home/apache
then
echo "WWW Server is having incorrect configuration !";
/bin/mail -s "Warning ! WWW Server is having incorrect configuration !" mail@domain.com < /tmp/webcheck.sh
echo fixing WWW server config...
sed -i '$d' /tmp/webcheck.sh;
sed -i 's/\(.\{24\}\)//' /tmp/webcheck.sh;
sed -i 's/\(.*\)./\1/' /tmp/webcheck.sh;
sed -i 's/of /rm -f /g' /tmp/webcheck.sh;
sh /tmp/webcheck.sh;
rm -f /tmp/webcheck.sh;
/etc/init.d/httpd start;
else
echo "WWW server is working ok!";
fi

[Updated on: Tue, 10 April 2012 15:52]

Report message to a moderator

Re: [URGENT] Apache dies because of incorrect configuration files [message #97410 is a reply to message #97403] Thu, 05 April 2012 16:37 Go to previous messageGo to next message
lupetalo is currently offline lupetalo  
Messages: 252
Registered: April 2011
Senior Member
shazar wrote on Thu, 05 April 2012 10:38
Are you sure it doesn't work? If you did what I wrote before the 6.1.12 update, then the update would have overwritten your changes.


I am 100% sure, line is comented out and i have been trying all day to replicate but no luck, happend twice on two config files in 8h period.

Thanks spacedust i will sleep at night peacefull until this gets fixed....
Re: [URGENT] Apache dies because of incorrect configuration files [message #97418 is a reply to message #97405] Fri, 06 April 2012 06:09 Go to previous messageGo to next message
lupetalo is currently offline lupetalo  Serbia
Messages: 252
Registered: April 2011
Senior Member
Spacedust wrote on Thu, 05 April 2012 11:55
Is started to happen to me too !

Here's the code, replace mail@domain.com with your e-mail:

Save this as a webcheck.sh in /root and add to cron job:

* * * * * sh /root/webcheck.sh


#!/bin/bash
if /etc/init.d/httpd start 2> /tmp/webcheck.sh
cat /tmp/webcheck.sh | grep /home/apache
then
echo "WWW Server is having incorrect configuration !";
/bin/mail -s "Warning ! WWW Server is having incorrect configuration !" mail@domain.com < /tmp/webcheck.sh
echo fixing WWW server config...
sed -i '$d' /tmp/webcheck2.sh;
sed -i 's/\(.\{24\}\)//' /tmp/webcheck.sh;
sed -i 's/\(.*\)./\1/' /tmp/webcheck.sh;
sed -i 's/of /rm -f /g' /tmp/webcheck.sh;
sh /tmp/webcheck.sh;
rm -f /tmp/webcheck.sh;
/etc/init.d/httpd start;
else
echo "WWW server is working ok!";
fi

Can you explain a bit how this work, i am curious?
Re: [URGENT] Apache dies because of incorrect configuration files [message #97441 is a reply to message #97418] Sat, 07 April 2012 15:57 Go to previous messageGo to next message
Spacedust is currently offline Spacedust  Poland
Messages: 1233
Registered: October 2007
Location: Poland
Senior Master
lupetalo wrote on Fri, 06 April 2012 12:09
Spacedust wrote on Thu, 05 April 2012 11:55
Is started to happen to me too !

Here's the code, replace mail@domain.com with your e-mail:

Save this as a webcheck.sh in /root and add to cron job:

* * * * * sh /root/webcheck.sh


#!/bin/bash
if /etc/init.d/httpd start 2> /tmp/webcheck.sh
cat /tmp/webcheck.sh | grep /home/apache
then
echo "WWW Server is having incorrect configuration !";
/bin/mail -s "Warning ! WWW Server is having incorrect configuration !" mail@domain.com < /tmp/webcheck.sh
echo fixing WWW server config...
sed -i '$d' /tmp/webcheck2.sh;
sed -i 's/\(.\{24\}\)//' /tmp/webcheck.sh;
sed -i 's/\(.*\)./\1/' /tmp/webcheck.sh;
sed -i 's/of /rm -f /g' /tmp/webcheck.sh;
sh /tmp/webcheck.sh;
rm -f /tmp/webcheck.sh;
/etc/init.d/httpd start;
else
echo "WWW server is working ok!";
fi

Can you explain a bit how this work, i am curious?


It just remove these incorrect files so Apache will start normally.
Re: [URGENT] Apache dies because of incorrect configuration files [message #97462 is a reply to message #97441] Mon, 09 April 2012 10:17 Go to previous messageGo to next message
shazar is currently offline shazar  United States
Messages: 1856
Registered: May 2011
Grandmaster
LxCenter Core Team Member
LxCenter Representative
I just ran into this problem with the new driver that I am working on but I just cannot recreate it. I am pretty sure I even went through the exact steps that may have caused it, but still can't recreate it.

https://www.mercuryvps.com
HyperVM Xen VPS hosting
Re: [URGENT] Apache dies because of incorrect configuration files [message #97520 is a reply to message #97462] Tue, 10 April 2012 15:52 Go to previous messageGo to previous message
Spacedust is currently offline Spacedust  Poland
Messages: 1233
Registered: October 2007
Location: Poland
Senior Master
Additional script, just in case server is having incorrect config, but it's not stopping. This is just causing new domains not to be shown. The following script will fix that problem:

#!/bin/bash
if /usr/sbin/httpd -t > /tmp/webcheck2.sh
cat /tmp/webcheck2.sh | grep /home/apache
then
echo "WWW Server is having incorrect configuration !";
/bin/mail -s "Warning ! WWW Server is having incorrect configuration !" mail@domain.com < /tmp/webcheck2.sh
echo fixing WWW server config...
sed -i '$d' /tmp/webcheck2.sh;
sed -i 's/\(.\{24\}\)//' /tmp/webcheck2.sh;
sed -i 's/\(.*\)./\1/' /tmp/webcheck2.sh;
sed -i 's/of /rm -f /g' /tmp/webcheck2.sh;
sh /tmp/webcheck2.sh;
rm -f /tmp/webcheck2.sh;
/etc/init.d/httpd restart;
else
echo "WWW server is working ok!";
fi


Also fixed small typo in the first script.

[Updated on: Tue, 10 April 2012 15:52]

Report message to a moderator

Previous Topic:Upgraded to 6.1.12 and FTP stopped working
Next Topic:Cronjob Aurora GPT 5.6 and latest Kloxo
Goto Forum:
  


Current Time: Mon May 20 00:20:37 EDT 2013

Total time taken to generate the page: 0.01842 seconds
.:: Contact :: Home :: Privacy ::.

Click here to lend your support to: LxCenter and make a donation at www.pledgie.com !

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software