debian etch, apache 2.2.8 start problem

27 posts / 0 new
Last post
#1 Tue, 05/06/2008 - 17:39
hobbes006

debian etch, apache 2.2.8 start problem

Hi guys,

Having some problem with start apache 2.2.8 from webmin's "Apache Webserver" Interface.

If I click on the "start apache" link at the top right corner, I will always get an error message stating "Failed to start apache : Apache does not appear to be running :

Starting web server: apache2"

This does not happen if I log in via ssh and restart my apache using /etc/init.d/apache2 restart or /etc/init.d/apache2 start or /etc/init.d/apache2 stop

Any idea why this might be so?

Regards, Calvin

Tue, 05/06/2008 - 17:41
hobbes006

This additional information might be helpful to whoever is kind enough to give me a hint... In /etc/webmin/apache/config file, it reads:-

k_dir=/etc/apache2/sites-enabled
test_manual=0
show_list=0
mime_types=/etc/apache2/mime.types
access_conf=/etc/apache2/access.conf
auto_mods=1
stop_cmd=/etc/init.d/apache2 stop
virt_file=/etc/apache2/sites-available
test_apachectl=1
max_servers=100
srm_conf=/etc/apache2/srm.conf
httpd_dir=/etc/apache2
start_cmd=/etc/init.d/apache2 start
show_order=0
test_always=0
httpd_conf=/etc/apache2/apache2.conf
test_config=1
httpd_path=/usr/sbin/apache2

Something wrong with one of the configuration variables???

Thanks for any advice.
Calvin

Tue, 05/06/2008 - 18:06 (Reply to #2)
Joe
Joe's picture

Yes, there is no such configuration directive as "k_dir". It should be link_dir

But I'm not sure that would prevent things from working. Are the configuration paths actually correct? Is the Apache pid file in the normal location for Debian?

--

Check out the forum guidelines!

Tue, 05/06/2008 - 18:13 (Reply to #3)
hobbes006

Hi Joe,

Super fast reply. Thank you. :)
Sorry. typo on my part. It's link_dir in my config file.

Yes. /var/run/apache2.pid exists and is where it should be on debian.

Is there any other issues I need to check? Permissions issue?

Regards,
Calvin

Tue, 05/06/2008 - 18:16 (Reply to #4)
hobbes006

Something to note is that it was the webmin "Start Apache" and "Restart Apache" links were working perfectly fine before I upgraded Apache to 2.2.8. It was working well when I was running Apache 2.2.6.

Could that be an indicator of some issue with webmin running Apache 2.2.8?

Thu, 05/08/2008 - 12:35 (Reply to #5)
hobbes006

Anyone? Any idea on what could be preventing webmin from reading Apache 2.2.8's status while on the other hand, when I manually run /etc/init.d/apache2 restart or start or force-reload or stop commands, everything works perfectly at command line?

Thu, 05/08/2008 - 12:45 (Reply to #6)
Joe
Joe's picture

It's gotta be the pid file. That's how Webmin knows whether Apache is running or not. Make sure it points to the right place. Presumably it moved in the more recent version of Apache.

--

Check out the forum guidelines!

Thu, 05/08/2008 - 12:49 (Reply to #7)
hobbes006

Hi Joe,

Thanks for your support again. I ran
"find / -name apache2.pid" and it is revealed that the apache2.pid file exists in
"/var/run/apache2.pid"

How can I instruct webmin to know that apache2.pid exists in that location? The /etc/webmin/apache/config file does not seem to have such a setting.

Thu, 05/08/2008 - 12:50 (Reply to #8)
Joe
Joe's picture

Click "Module Config" in the Apache module.

--

Check out the forum guidelines!

Thu, 05/08/2008 - 12:52 (Reply to #9)
hobbes006

Got it! :)

Thanks for your help! Webmin reads the pid file now and all is good.

Sun, 06/07/2009 - 07:22 (Reply to #10)
hobbes006

Hi Joe,

If you are still around. It seems like it's too early for me to be happy.

When I click on "Apply Changes", I get this error message
apache2: bad user name ${APACHE_RUN_USER}

Any idea?

Sun, 06/07/2009 - 07:22 (Reply to #11)
hobbes006

Hi Joe,

If you are still around. It seems like it's too early for me to be happy.

When I click on "Apply Changes", I get this error message
apache2: bad user name ${APACHE_RUN_USER}

Any idea?

Sun, 06/07/2009 - 07:22 (Reply to #12)
hobbes006

Hi Joe,

If you are still around. It seems like it's too early for me to be happy.

When I click on "Apply Changes", I get this error message
apache2: bad user name ${APACHE_RUN_USER}

Any idea?

Tue, 08/12/2008 - 08:13 (Reply to #13)
ata0311

<b>hobbes006 wrote:</b>
<div class='quote'>This additional information might be helpful to whoever is kind enough to give me a hint... In /etc/webmin/apache/config file, it reads:-

k_dir=/etc/apache2/sites-enabled
test_manual=0
show_list=0
mime_types=/etc/apache2/mime.types
access_conf=/etc/apache2/access.conf
auto_mods=1
stop_cmd=/etc/init.d/apache2 stop
virt_file=/etc/apache2/sites-available
test_apachectl=1
max_servers=100
srm_conf=/etc/apache2/srm.conf
httpd_dir=/etc/apache2
start_cmd=/etc/init.d/apache2 start
show_order=0
test_always=0
httpd_conf=/etc/apache2/apache2.conf
test_config=1
httpd_path=/usr/sbin/apache2

Something wrong with one of the configuration variables???

Thanks for any advice.
Calvin</div>

Click &quot;Module Config&quot; in the Apache module.

I am looking at this statement and it doesn't make sense. How do you configure &quot;Module Config&quot; or what do you change?

Thu, 05/08/2008 - 13:52
Joe
Joe's picture

Holy crap, you're running the Ubuntu Abomination! Run for the hills! (Putting invalid syntax into a configuration file for the convenience of a couple of lazy developers is a great wrongness in the force, and shame and scorn be upon them for their evil ways.)

Upgrade to Webmin 1.411, which knows how to deal with this abomination. (Because they were too damned lazy to parse the Apache configuration file, every other administrative tool that knows how to parse the Apache file has to be updated to deal with the garbage they're putting in the file.)

I feel strongly about this issue, can you tell? ;-)

--

Check out the forum guidelines!

Thu, 05/08/2008 - 13:53
hobbes006

In particular, if I check my envvars file, I see

export APACHE_RUN_USER=www-data
export APACHE_RUN_GROUP=www-data
export APACHE_PID_FILE=/var/run/apache2.pid

Is this supposed to be correct? And is it the cause of the bad user name I see in webmin?

Sun, 06/07/2009 - 07:22 (Reply to #16)
hobbes006

Hi Joe... I am pretty sure I am running Debian Etchm not Ubuntu, because running this:
cat /etc/issue

Shows:
Debian GNU/Linux 4.0 \n \l

Sun, 06/07/2009 - 07:22 (Reply to #17)
hobbes006

Hi Joe... I am pretty sure I am running Debian Etchm not Ubuntu, because running this:
cat /etc/issue

Shows:
Debian GNU/Linux 4.0 \n \l

Thu, 05/08/2008 - 13:58
Joe
Joe's picture

So, the Debian folks have adopted the same horrible practice. Makes a fellow unhappy to know it...as this was one of the reasons I like Debian better than Ubuntu for servers--it's a really bad direction to go in, and if they do it for all of their services, it will become a wholly unusable mess.

--

Check out the forum guidelines!

Thu, 05/08/2008 - 14:00 (Reply to #19)
hobbes006

Maybe it's not debian's fault... I could have accidentally chown on the wrong directory, preventing webmin from running the /etc/init.d/apache2 start/restart/stop/force-reload commands.

Is there anyway I can check that the file or folder permissions are correct? If so, which folder should I look into?

Thu, 05/08/2008 - 14:04 (Reply to #20)
Joe
Joe's picture

No, it's definitely not Webmin's fault--this is evil committed by the Debian and Ubuntu folks.

But you'll still need to upgrade to 1.411 if you're going to use that configuration file. No version before 1.411 knows about those variables (which are post-processed by the rc scripts that start Apache).

--

Check out the forum guidelines!

Thu, 05/08/2008 - 14:06 (Reply to #21)
Joe
Joe's picture

And it's not your fault, either, in case I wasn't clear. These variables in an Apache configuration file are not normal or valid httpd.conf syntax, but they are a default part of the Ubuntu Apache package (and apparently now the Debian package).

--

Check out the forum guidelines!

Thu, 05/08/2008 - 14:08 (Reply to #22)
hobbes006

Ok... so if i do a

wget http://prdownloads.sourceforge.net/webadmin/webmin_1.410_all.deb
and then run
dpkg -i webmin_1.410_all.deb

It should work out...
I am also running Version 3.49.gpl Virtualmin. Will this cause problems with webmin 1.410 after I upgrade my current webmin 1.380?

Thank you for being patient with your answers.

Thu, 05/08/2008 - 14:10 (Reply to #23)
Joe
Joe's picture

No. I said 1.411. 1.410 does not support these variables. 1.411 is a development version.

Older versions of Virtualmin will be fine...but you really should be running the latest version at all times. We don't build new versions for our healt. We build them because they're better--fewer bugs, more features, better usability, etc.

--

Check out the forum guidelines!

Thu, 05/08/2008 - 14:16 (Reply to #24)
hobbes006

Alright :)
I will check for 1.411... looking at http://sourceforge.net/project/showfiles.php?group_id=17457 it seems 1.411 is not yet available... Do you have an SVN repository for it or something?

Thu, 05/08/2008 - 14:46 (Reply to #25)
Joe
Joe's picture

Dude, look at the Webmin website. There's a Development Versions link right on the front page! ;-)

--

Check out the forum guidelines!

Thu, 05/08/2008 - 14:59 (Reply to #26)
hobbes006

OOOOO.... this -&gt; http://download.webmin.com/devel/deb/

lol... sorry. Totally missed that out.

Topic locked