Miscellaneous > Programming & Networking
Setting up an Apache web server
Laukev7:
As the title implies, I am trying to set up an Apache web server on FreeBSD. Apache seems to be installed correctly, as it displays the default page with my IP address.
The problem is that my address doesn't seem to work outside of my local network. When I type [edited] in my browser, it shows the default Apache page, while it does not when I type the same thing on another computer in my network. Ping does not detect anything on the other computer, while it returns 127.0.0.1 on mine.
My browser displays the Apache page when I type my local IP address or 127.0.0.1, but does not work with localhost. It works on the other computers on the network when I type my local IP address (192.168.0.102).
My hosts config is:
::1 localhost localhost.my.domain
127.0.0.1 laukev7 [edited]
192.168.0.102 [edited] laukev7
I am behind a router, and have configured my virtual server HTTP with:
Private IP: 192.168.0.102
Protocol: TCP 80/80
Is there something I am missing here? I am just starting to learn about web servers. Any help will be appreciated.
Baikonur:
You have to put something in your Webserver folder . . .
Library > Web Server
Type
/var/log/httpd in the "Go To" menu for error and access logs.
Also, NOT WISE to broadcast your IP. As Macs do not have dynamic IPs . . .
[ August 31, 2003: Message edited by: Xenix God ]
Laukev7:
This is not my actual IP, only my LAN IP.
And thanks for your advice, but as I said, I use FreeBSD, not Mac OS X (Yet).
Edit: I checked both the access and error logs, where you told me. It appears that my server has indeed been accessed by the other computer, but only when I typed my IP number, not the address, which, unfortunately, does not solve my problem.
[ September 01, 2003: Message edited by: Laukev7: Defender of Canada ]
Stryker:
what does your lan use for name resolution? do you have a dns server? in which case you may want to forward (if ur dns server supports it) *.apacheserver to apacheserver.
some dns servers wont resolve subdomains unless they are added manually.
once you can ping the subdomain, it's time to configure apache for it. virtual hosts can do that for you.
Laukev7:
quote:Originally posted by Stryker:
what does your lan use for name resolution? do you have a dns server? in which case you may want to forward (if ur dns server supports it) *.apacheserver to apacheserver.
some dns servers wont resolve subdomains unless they are added manually.
once you can ping the subdomain, it's time to configure apache for it. virtual hosts can do that for you.
--- End quote ---
OK, this is where my knowledge of networks falters. I tried to give as much info as possible, but I don't understand everything. As I said, I'm starting to learn.
I think my D-link router is my DNS server. I tried to ping [edited], and it says "ping: cannot resolve [edited]: No address associated with name". This does indeed look related to the DNS, but I don't know what to do about it, or even how to forward *.apacheserver to apacheserver (if such applies).
And what are virtual hosts? Can you explain about that?
Navigation
[0] Message Index
[#] Next page
Go to full version