Linux Help
guides forums blogs
Home Desktops Distributions ISO Images Logos Newbies Reviews Software Support & Resources Linuxhelp Wiki

Welcome Guest ( Log In | Register )



Advanced DNS Management
New ZoneEdit. New Managment.

FREE DNS Is Back

Sign Up Now
> Configuring Name Based Virtual Hosts, configuring apache
chrisss
post Nov 15 2002, 08:08 AM
Post #1


Whats this Lie-nix Thing?
*

Group: Members
Posts: 3
Joined: 15-November 02
Member No.: 154



Ive been trying to set up a namevirtualhost just as a project running on my own computer, ive altered my hosts file which
looks like this
127.0.0.1 localhost.localdomain localhost
127.0.0.1 www.peta.com.au

then i added to the httpd.conf

NameVirtualHost 127.0.0.1
<VirtualHost 127.0.0.1>
ServerName www.peta.com.au
DocumentRoot /home/peta/web
<Directory /home/peta/web>
Order allow, deny
Allow from all
</Directory>
</VirtualHost>

I have an index file in the above document root.

When i type in the address into the browser i get an error msg
saying i dont have permission to access /

it dont seem to matter where i define the document root for the virtual host
...i always get the same message.. plus defining a namevirtual host seems to
stop me accessing any file ...i get the same msg even for the localhost but
soon as i comment out the namevirtualhost directives the localhost works
fine.


thanks chris
Go to the top of the page
 
+Quote Post
 
Start new topic
Replies
bensode
post Nov 18 2002, 11:46 AM
Post #2


Whats this Lie-nix Thing?
*

Group: Members
Posts: 15
Joined: 18-November 02
Member No.: 164



Couple of flaws ...

<Quote>
Ive been trying to set up a namevirtualhost just as a project running on my own computer, ive altered my hosts file which
looks like this
127.0.0.1 localhost.localdomain localhost
127.0.0.1 www.peta.com.au
</QUOTE>

you shouldn't name like that to same IP in that manner to localhost. Try
127.0.0.1 localhost.localdomain localhost
127.0.0.2 www.peta.com.au


Second ... apache changed it's Vhost syntax in the httpd.conf with recent patches to exploits in vhosting. What is your version of apache? Check the latest docs on Vhosting on the apache site http://httpd.apache.org/

Hope that helps ...
Go to the top of the page
 
+Quote Post

Posts in this topic


Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



RSS Lo-Fi Version Time is now: 20th October 2017 - 07:38 AM