LinuxQuestions.org
Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 03-25-2005, 09:56 PM   #1
The_Messiah
Member
 
Registered: Jan 2004
Distribution: Slackware 10.1
Posts: 119

Rep: Reputation: 15
Help with apache 2.0


Well, I've recently decide to completly leave windows behind, so now I'm doing things to help expand my knowledge with linux, amongst other things.

I've just downloaded apache 2.0 and did the following commands.

#./configre
#make
#make install

That got it ready to go (I think so anyway)

The apache docs say to alter the httpd.conf file but I don't know anything about it, so if someone could help me out with things like, what to change...things like that.

Another thing, I tried the next step in the apache docs which is to run this command

#./apachectl start

And got this error in return...

Address already in use: make_sock: could not bind to address 0.0.0.0:80
no listening sockets available, shutting down
Unable to open logs


If anyone could help me out with what I'm doing wrong, things I should do, things I should know, any advise really, It'd be greatly appreciated.

By the way, if anyone is wondering I'm using slackware 9.1 and 2.4.22 kernel.

Regards,
The_Messiah
 
Old 03-26-2005, 12:29 AM   #2
JordanH
Member
 
Registered: Oct 2003
Location: Toronto, Canada
Distribution: Ubuntu, FC3, RHEL 3-4 AS Retired: SuSE 9.1 Pro, RedHat 6-9, FC1-2
Posts: 360

Rep: Reputation: 30
Not being an Apache expert, I'd suggest you take a look in the config file and make sure the ip address is specified. That error message makes me think it is trying to bind to an incorrect ip address (0.0.0.0). I think the config line is something like
Listen 192.168.0.5:80 (assuming your IP address is 192.168.0.5)
 
Old 03-26-2005, 12:40 AM   #3
WhatsHisName
Senior Member
 
Registered: Oct 2003
Location: /earth/usa/nj (UTC-5)
Distribution: RHL9;F1-10; CentOS4-5; DebianSarge-Squeeze
Posts: 1,151

Rep: Reputation: 46
httpd.conf is full of helpful comments which are remarkably clear. Just print it out (all 19 pages) and read through it. Also reference the Apache documentation for any details that are not clear (httpd.apache.org/docs-2.0/).

Regarding your problem, it sounds like a problem with a “Listen” directives. If you added any ports for Apache to monitor, you may have added a conflict. In general, you will usually only find one defined Listen Directive (“Listen 80") out of the box. Look at httpd.apache.org/docs-2.0/mod/mpm_common.html#listen for info about Listen directives.
 
Old 03-26-2005, 01:43 AM   #4
The_Messiah
Member
 
Registered: Jan 2004
Distribution: Slackware 10.1
Posts: 119

Original Poster
Rep: Reputation: 15
I took Jordan's advise and changed the ip's, I made them 127.0.0.1.

Then I ran that "./apachectl start"

I got no feedback so I went to http://localhost/ and found that I was successful.

The page said this--
If you can see this, it means that the installation of the Apache web server software on this system was successful. You may now add content to this directory and replace this page.

So what I'm asking is where should I go from here, I think running a SSL server would be handy. I'd also like to play around with php.

I was also wondering, when I go to http://localhost/ and it shows that test page, where is it getting that from? I can't find it in my apache folder (I might not be looking hard enough)
 
Old 03-26-2005, 09:40 AM   #5
WhatsHisName
Senior Member
 
Registered: Oct 2003
Location: /earth/usa/nj (UTC-5)
Distribution: RHL9;F1-10; CentOS4-5; DebianSarge-Squeeze
Posts: 1,151

Rep: Reputation: 46
Quote:
I took Jordan's advise and changed the ip's, I made them 127.0.0.1.
If you entered “Listen 127.0.0.1:80", then only the local host can access the pages. Change it to “Listen 80".

Quote:
I was also wondering, when I go to http://localhost/ and it shows that test page, where is it getting that from? I can't find it in my apache folder (I might not be looking hard enough)
Look under /var/www. If you have html files you want to display, put them in /var/www/http, but you can define any location as the source by making changes in httpd.conf.

Again, if you want to know more about configuring Apache, start reading through httpd.conf or get detailed help from http://httpd.apache.org/docs-2.0/.
 
Old 03-26-2005, 12:40 PM   #6
JordanH
Member
 
Registered: Oct 2003
Location: Toronto, Canada
Distribution: Ubuntu, FC3, RHEL 3-4 AS Retired: SuSE 9.1 Pro, RedHat 6-9, FC1-2
Posts: 360

Rep: Reputation: 30
Quote:
Originally posted by The_Messiah
So what I'm asking is where should I go from here, I think running a SSL server would be handy. I'd also like to play around with php.
Wow... that's a big question. The answer is, the world's your oyster. Only you can set the direction you want to take your site.

If you have specific questions, I'll be glad to help to the best of my limited ability.

WhatsHisName is correct, you must look in your apache config file to find out where the root of your web server is. It's likely under /var/www or I think SuSE might put it under /srv/www ... You can specify this whereever you like but I'd leave it as the default until you know what you are doing thoroughly.

I'm glad all is well, good luck.
J.
 
Old 03-27-2005, 01:19 AM   #7
The_Messiah
Member
 
Registered: Jan 2004
Distribution: Slackware 10.1
Posts: 119

Original Poster
Rep: Reputation: 15
Quote:
Originally posted by WhatsHisName
Look under /var/www. If you have html files you want to display, put them in /var/www/http, but you can define any location as the source by making changes in httpd.conf.
I don't have a /var/www...is there somewhere else it would be located...or is it a problem that I don't have it?
 
Old 03-27-2005, 11:30 AM   #8
JordanH
Member
 
Registered: Oct 2003
Location: Toronto, Canada
Distribution: Ubuntu, FC3, RHEL 3-4 AS Retired: SuSE 9.1 Pro, RedHat 6-9, FC1-2
Posts: 360

Rep: Reputation: 30
If you got the test page, then you have it somewhere. You'll have to look around to find it.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Mail from Apache being rejected - Cannot route to sender apache@localhost.localdomain jimwillsher Linux - Networking 2 01-19-2006 01:41 AM
Apache 1.3.33 (debian built) and Apache SSL does not respond to the proper ports lqorg_user Linux - Networking 0 11-06-2005 05:11 PM
Strange apache trailing / problem - Slack-current, apache 1.3.33 vamp Linux - Networking 1 01-30-2005 08:28 PM
Apache Webserver 403 Forbidden Errors (User not in apache group?) Mankind75 Mandriva 4 07-08-2004 06:30 AM
apache benchmarks (apache v13 / apache v20) ; large differences between benchmarking markus1982 Linux - Software 0 02-08-2003 11:53 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 03:46 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration