logo
Apache Lounge
Webmasters

 

About Forum Index Downloads Search Register Log in RSS X


Keep Server Online

If you find the Apache Lounge, the downloads and overall help useful, please express your satisfaction with a donation.

or

Bitcoin

A donation makes a contribution towards the costs, the time and effort that's going in this site and building.

Thank You! Steffen

Your donations will help to keep this site alive and well, and continuing building binaries. Apache Lounge is not sponsored.
Post new topic   Forum Index -> Apache View previous topic :: View next topic
Reply to topic   Topic: Vhosting problems
Author
TheCapulet



Joined: 12 Oct 2007
Posts: 8
Location: United States

PostPosted: Tue 16 Oct '07 22:00    Post subject: Vhosting problems Reply with quote

NameVirtualHost *:80

<VirtualHost *:80>
DocumentRoot C:/www/IHIO
ServerName IHIOPC.com
ServerAlias www.IHIOPC.com
</VirtualHost>

I've entered this into my config file, but it doesnt seem to be picking it up.

Is this correct, or have I missed something?

Thanks so much for the help.
Back to top
glsmith
Moderator


Joined: 16 Oct 2007
Posts: 2268
Location: Sun Diego, USA

PostPosted: Tue 16 Oct '07 22:49    Post subject: Reply with quote

What is it NOT doing?
Giving you a Forbidden? (as I saw when I went to the domain)

Other than that the <VirtualHost> part looks fine, minimal, but fine

You need to give C:/www/IHIO access using the <Directory> directives
<Directory "C:/www/IHIO">
Options ~whatever options you choose~
AllowOverRide ~whatever overrides you choose~
Order Allow, Deny
Allow from all
</Directory>
Back to top
TheCapulet



Joined: 12 Oct 2007
Posts: 8
Location: United States

PostPosted: Tue 16 Oct '07 23:42    Post subject: Reply with quote

Ok. I'll try that in a few, and post back if it works. Thanks. Smile
Back to top
TheCapulet



Joined: 12 Oct 2007
Posts: 8
Location: United States

PostPosted: Wed 17 Oct '07 0:27    Post subject: Reply with quote

Nope. Still giving me the forbidden messege.
Back to top
glsmith
Moderator


Joined: 16 Oct 2007
Posts: 2268
Location: Sun Diego, USA

PostPosted: Wed 17 Oct '07 1:24    Post subject: Reply with quote

post your httpd.conf file.
    ADMIN NOTE: do not post your entire httpd.conf (per the Forum Rules), just post the relevant portion.
What version Apache
Windoze XP?

Are there any files in C:/www/IHIO, specifically index.html?

Sorry ...

Actually, one more question ... did you restart the server after you made changes?
Back to top
TheCapulet



Joined: 12 Oct 2007
Posts: 8
Location: United States

PostPosted: Thu 18 Oct '07 3:14    Post subject: Reply with quote

Using windows 2k3 web edition.
Apache 2

And it did start to work, with just my www.ihiopc.com set up as a Vhost. But when I tried to expand and put in a subdomain, and another domain, nothing would work. Heh.

Question for the admin: Is it against forum rules for me to PM my config?
Back to top
tdonovan
Moderator


Joined: 17 Dec 2005
Posts: 611
Location: Milford, MA, USA

PostPosted: Thu 18 Oct '07 5:05    Post subject: Reply with quote

re: "Is it against forum rules for me to PM my config?"

No problem posting relevant portions of your config, like in your first post. This is fine.

A recurring problem in this forum is people who post their whole 500-line httpd.conf file, comments and all.

I didn't mean to suggest you had done anything wrong.
Please post your <VirtualHost> and <Directory> sections.

FYI - the Forum rules are here. There should be a link in the upper-left panel when you are logged into Apache Lounge. They are really not too onerous.

-tom-
Back to top
TheCapulet



Joined: 12 Oct 2007
Posts: 8
Location: United States

PostPosted: Sun 25 Nov '07 2:03    Post subject: Reply with quote

Ok. I've just headed back to fixing this, and I'm still having a little trouble.

Here's the stuff from my httpd.conf:
Code:

## Directory
<Directory />
    Options FollowSymLinks
    AllowOverride None
    Order deny,allow
    Deny from all
    Satisfy all
</Directory>

<Directory "C:/www"
    Options Indexes FollowSymLinks
    AllowOverride None
    Order allow,deny
    Allow from all
</Directory>

<Directory "C:/www/">
    Options Indexes FollowSymLinks
    AllowOverride None
    Order allow,deny
    Allow from all
</Directory>

## Vhost stuff

NameVirtualHost *:80

<VirtualHost *:80>
  ServerName www.IHIOPC.com
  DocumentRoot "C:/www/IHIO"
</VirtualHost>

<VirtualHost *:80>
  ServerName ftp.heartlanddogcare.com
  DocumentRoot "C:/www/heartlanddogcare"
</VirtualHost>

<VirtualHost *:80>
    ServerName www.heartlanddogcare.com
    DocumentRoot "C:/www/Heartlanddogcare"
</VirtualHost>

<VirtualHost *:88>
    ServerName WoT.IHIOPC.com
    DocumentRoot "C:/www/WoT"
</VirtualHost>


I was reading some support pages on the appache site, and it also says that the DNS server has to be properly configured for name-based virtual servers as well. Not exactly sure how to do this, or what I have to do at all.
Back to top
tdonovan
Moderator


Joined: 17 Dec 2005
Posts: 611
Location: Milford, MA, USA

PostPosted: Sun 25 Nov '07 17:19    Post subject: Reply with quote

re: "DNS server has to be properly configured"

This means that the names must be publicly registered so users can get your IP address from the name.

Two of your names seem to be properly registered:
    www.IHIOPC.com is registered at Dynadot as 74.38.44.166

    www.heartlanddogcare.com is also registered at Dynadot as 74.38.44.166
These two names should work as virtual hosts. Your httpd.conf appears correct (...to me...).

The other two names: ftp.heartlanddogcare.com and WoT.IHIOPC.com; don't seem to be publicly registered.

Also - the name ftp.heartlanddogcare.com sounds like an FTP name, not an HTTP name. Apache doesn't provide an FTP server, so you will need a separate FTP server if you expect to connect via FTP using this name.

When I try your two correctly registered names, they show an IIS 6.0 "Under Construction" page.
IIS must, of course, be stopped before Apache can run.

-tom-
Back to top
TheCapulet



Joined: 12 Oct 2007
Posts: 8
Location: United States

PostPosted: Sun 25 Nov '07 19:18    Post subject: Reply with quote

Quote:
Two of your names seem to be properly registered:
www.IHIOPC.com is registered at Dynadot as 74.38.44.166

www.heartlanddogcare.com is also registered at Dynadot as 74.38.44.166
These two names should work as virtual hosts. Your httpd.conf appears correct (...to me...).


Atm, these are the only two that I have registered. The others will be later. Just trying to get these to work first.

Quote:

Also - the name ftp.heartlanddogcare.com sounds like an FTP name, not an HTTP name. Apache doesn't provide an FTP server, so you will need a separate FTP server if you expect to connect via FTP using this name.

I'm using an ftp server called warftp. Honestly I'm not liking it very much, so if you have any suggestions it would really help.

Quote:

When I try your two correctly registered names, they show an IIS 6.0 "Under Construction" page.


This is the only thing left that I can see blocking my way. Everything else seems configured right. But I dont recall ever using IIS. And honestly, I dont know how to turn it off if it is on. And when I dont have the virtual hosting coded, and just have it pointing directly to the files I want, then 1 website works. So I'm a bit confused.

Thanks so much for the help btw. You've been amazing.
Back to top
TheCapulet



Joined: 12 Oct 2007
Posts: 8
Location: United States

PostPosted: Mon 26 Nov '07 4:14    Post subject: Reply with quote

Meh, ok. Turns out there was a syntax error in the directory info. Woops. Razz All seems to be working now. Thanks so much.
Back to top


Reply to topic   Topic: Vhosting problems View previous topic :: View next topic
Post new topic   Forum Index -> Apache