Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
apache startup question
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
mogosjoh
Tux's lil' helper
Tux's lil' helper


Joined: 24 Apr 2002
Posts: 79
Location: Plymouth, MI

PostPosted: Wed Oct 09, 2002 2:37 am    Post subject: apache startup question Reply with quote

alright, so I am working on getting apache up and running on my system and I have 2 questions. I have already emerged and configured, and did rc-update add apache default, but upon boot I see:
starting apache... [!!]
with no error message
then, once booted, it appears that apache is not started (can't access web pages), so I then (as root) type 'apache' and it works ok. However, I will not leave it running this way because that is fundamentally dumb (running apache as root). Also, I have 2 NICs in my system, both getting IP's from DHCP, and I saw an earlier error with resolving the hostname (used to be defined in /etc/hostname, but now is not). How can I make apache happy with 2 NICs or set it up to only use 1 of them instead??

thanks,

-John
Back to top
View user's profile Send private message
mihochan
Apprentice
Apprentice


Joined: 16 Apr 2002
Posts: 296
Location: Melbourne again

PostPosted: Wed Oct 09, 2002 5:08 am    Post subject: Reply with quote

I can't help with the second query but possibly the reason for the first is
that apache can't create or write to its log files when not run as root.

In my experience, this is often the problem behind the sort of symptoms you are describing.

Tom
_________________
In the long run we are all dead - Keynes
Back to top
View user's profile Send private message
mogosjoh
Tux's lil' helper
Tux's lil' helper


Joined: 24 Apr 2002
Posts: 79
Location: Plymouth, MI

PostPosted: Wed Oct 09, 2002 12:52 pm    Post subject: Reply with quote

ok, what's the solution?
Back to top
View user's profile Send private message
rizzo
Retired Dev
Retired Dev


Joined: 30 Apr 2002
Posts: 1067
Location: Manitowoc, WI, USA

PostPosted: Wed Oct 09, 2002 1:00 pm    Post subject: Reply with quote

Note that apache doesn't RUN as root. It runs as "apache". It needs to be started as root though.

So:
Code:
su -
Password: (enter root password)
/etc/init.d/apache stop
/etc/init.d/apache start

Make sure your user is in the "wheel" group, otherwise you don't be able to "su".
Back to top
View user's profile Send private message
rac
Bodhisattva
Bodhisattva


Joined: 30 May 2002
Posts: 6553
Location: Japanifornia

PostPosted: Wed Oct 09, 2002 6:23 pm    Post subject: Reply with quote

Can you try running the start-stop-daemon command that /etc/init.d/apache is running by hand, substituting out the '--quiet' option with "--verbose"? That should tell you in some more detail what's happening.
_________________
For every higher wall, there is a taller ladder
Back to top
View user's profile Send private message
mogosjoh
Tux's lil' helper
Tux's lil' helper


Joined: 24 Apr 2002
Posts: 79
Location: Plymouth, MI

PostPosted: Wed Oct 09, 2002 7:51 pm    Post subject: Reply with quote

fixed it, had to chown /home/httpd to apache.. duh
Back to top
View user's profile Send private message
mihochan
Apprentice
Apprentice


Joined: 16 Apr 2002
Posts: 296
Location: Melbourne again

PostPosted: Wed Oct 09, 2002 10:48 pm    Post subject: Reply with quote

That is pretty much the sort of problem I had expected.

Apache didn't have access to the directories it needed to run.

Looks like you worked it out for yourself.
_________________
In the long run we are all dead - Keynes
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum