Click to See Complete Forum and Search --> : getting apache started


RandomLinuxUser
12-01-2002, 04:09 PM
I am new to linux as well as new to apache. When i type ./apachectl start i get an error saying "HTTPD : Could not determine the servers fully qualified domain name, using 127.0.0.1 for servername. Then it starts. but the only way i can veiw it is by using the local host ip (127.0.0.1). How do i fix it so it it can be viewed by all?

untoldone
12-01-2002, 04:30 PM
well, it probably can be viewed by all as of right now unless you have a firewall or somethin.. just type the ip your isp asigned you into a browser on another computer, otherwise if you wanted somethin like a domain (ex. yahoo.com) to point to it, youd have to find a DNS service that would in most cases cost moneys per year or you could just goto http://www.no-ip.com and get a free subdomain that will point to your ip for you.

RandomLinuxUser
12-01-2002, 04:57 PM
yeah i tried that. the address i type is http://12.225.20.178 which is the ip and it doesnt work.

RandomLinuxUser
12-01-2002, 05:28 PM
i went to no-ip.com and got a host shn.no-ip.com but it doesnt work like before. i am very confused now.

RandomLinuxUser
12-02-2002, 12:08 AM
i think the problem is my dns server stuff how should that look?

RandomLinuxUser
12-02-2002, 12:26 AM
is there anyone who can even answer this?

untoldone
12-02-2002, 06:37 PM
well .. one thing you can do is add your host name to your hosts file - /etc/hosts - and add the line

127.0.0.1 shn.no-ip.com

i donno what could have caused that apache message .. ive never had that problem .. but then again .. ive never writen the config file by hand

this should make going to http://shn.no-ip.com in your browser work if going to localhost works, but i dont know if other comps on the net could c it ......... tho if your behind a router and want other comps on the network to view the site, ull have to either make an addition to there hosts file, or set up a local DNS

EricD
12-03-2002, 12:24 PM
What system are you using?
Is your server the only machine?
Can you see the web from that machine? (Can you surf)
Did you configure your /etc/resolf.conf file?

Setting up a http server on Linux is usualy an easy task.

Answer theses few questions above and then I (or someone else) might be able to help you! ;)

RobSmul
12-03-2002, 02:24 PM
Have you defined your servername?? According to your first post in this thread, you haven't done this yet.

check your httpd.conf at:
/etc/httpd/conf/httpd.conf

In the very first part of this file are some general settings.

You can add:

ServerName ..........

Where the dots represent your servername. Try to put here your IP-address and then restart the apache server (using: 'apachectl restart'). Can you connect to your webserver now?

Besides the questions EricD asked, could you also tell us if you are in a LAN, and from where you try to access the webserver besides the server itself?

Good luck,

Rob

RandomLinuxUser
12-03-2002, 03:17 PM
What system are you using? red hat 7.2
Is your server the only machine? no its not the only one
Can you see the web from that machine? (Can you surf) yes
Did you configure your /etc/resolf.conf file? no how should i edit it?

i cant see it from anyother computers on the lan and its not behind a fire wall

RobSmul
12-03-2002, 03:43 PM
If you try to access it what kind of error do you get?

404 - Page not found
or
403 - Access forbidden
??

Can you ping the pc?

On the pc itself, the RH7.2, if you open that browser and go to http://localhost

Do you see the page?

Hope your answers to these questions brings us closer to solve the problem.

RandomLinuxUser
12-03-2002, 06:25 PM
i get 404 - Page not found
Can you ping the pc?
yes i can

if im on the server and i goto http://localhost i do see the page

RobSmul
12-04-2002, 06:28 AM
Are you using the default document root (/var/www/html) for now?

Like I said before:

----------------------------------------------------------------
Have you defined your servername?? According to your first post in this thread, you haven't done this yet.

check your httpd.conf at:
/etc/httpd/conf/httpd.conf

In the very first part of this file are some general settings.

You can add:

ServerName ..........
-----------------------------------------------------------------

Have you done that? If not, make the ServerName the name of your RH7.2 machine. Then restart apache and try again. Now, on your LAN goto http://servername

Can you look into your apache log-files....

/var/log/httpd/

the files 'error_log' and 'access_log'. Are there some part(s) of these logs that can explain your problem. Do you see rules containing the IP's of the LAN-pc from where you are trying to access the webserver?

If this all doesn't work out, I think it has something to do with your network-configuration.