Forum Moderators: phranque
I don't know the first thig about Apache except that it is a server and when I make php web pages in Dreamweaver, I can test them on my own computer without having to upload them (I hope this assumption is right).
I don't need to use the server for hosting web pages for anyone else. It's purely for my own web page testing before uploading.
So I installed the server and gave it my pc name (lentrica).
When I type [lentrica...] or [lentrica:8080...] in IE browser, it doesn't work.
Naturally, I reckon I have to configure a few files before it works.
When I checked the httpd.conf file, it already has this written in there:
#
# ServerName gives the name and port that the server uses to identify itself.
# This can often be determined automatically, but we recommend you specify
# it explicitly to prevent problems during startup.
#
# If this is not set to valid DNS name for your host, server-generated
# redirections will not work. See also the UseCanonicalName directive.
#
# If your host doesn't have a registered DNS name, enter its IP address here.
# You will have to access it by its address anyway, and this will make
# redirections work in a sensible way.
#
ServerName lentrica:8080
What should I do to make it work?
Thanks
JH
[quote]127.0.0.1 lentrica[\quote]
or be cute and add in a top level domain to it (tld) thusly:
[quote]127.0.0.1 lentrica.org[\quote]
The one caveat to remember is that this is not DNS and just because you can access lentrica.org in this manner, your friends or co-workers cannot.
-ben
Anyway, I did what you said and added 2 lines to the file which read:
127.0.0.1 www.example2.com
127.0.0.1 www.example3.com
127.0.0.1 www.example4.com
127.0.0.1 localhost
127.0.0.1 lentrica
After saving it, I went to my browser and typed [lentrica...] and [localhost...] and [127.0.0.1...] and yet nothing!
Any more ideas?
[edited by: jdMorgan at 2:39 pm (utc) on Jan. 27, 2005]
[edit reason] Removed specifics per TOS. [/edit]
C:\Program Files\Apache Group\Apache2\bin>apache -k start
[Thu Jan 27 11:12:07 2005] [error] (OS 2)The system cannot find the file specifi
ed. : No installed service named "Apache2".
C:\Program Files\Apache Group\Apache2\bin>apache -k install
(OS 10048)Only one usage of each socket address (protocol/network address/port)
is normally permitted. : make_sock: could not bind to address 0.0.0.0:8080
no listening sockets available, shutting down
Unable to open logs
______________________________________
What do I do now?
I typed [lentrica...] and that wouldn't work but when I typed [lentrica:8080...] that worked.
How do I make it work so that I don't have to type 8080 everytime?
What would I type if I wanted to test my index.php page on my computer?
Any solutions?
Thanks
JH
# Listen: Allows you to bind Apache to specific IP addresses and/or
# ports, instead of the default. See also the <VirtualHost>
# directive.
#
# Change this to Listen on specific IP addresses as shown below to
# prevent Apache from glomming onto all bound IP addresses (0.0.0.0)
#
#Listen 12.34.56.78:80
Listen 8080
So I changed the last line to:
Listen 8080, 80
and that didn't work.
I also tried adding a separate line which read,
Listen 80
and that didn't work either.
What do I try now?
if you are only using it for testing locally, i'd use an all in one installer that will install php,apache,perl and mysql for you - not in the most secure way but if it isn't a live site it doesn't matter.
... i have used webserv to great effect and can say that the install on win xp is very easy - up and running in minutes.
Anyway, I also installed Uniform Server and it works good.
But how do I make it so the root folder is known as [localhost...] coz right now, it only works with my PC name?