# Solved: IIS Webserver not working



## Synt4xError (Jan 23, 2009)

I have a windows server 2003 server at home for lab studies. I am having some issues with the webserver in IIS. I installed IIS with FTP and Webserver being used. I have the FTP site working perfectly. I just can't seem to figure out why my HTTP isn't working.

Every time I type in the URL (My IP) in the browser. I get "Bad Request (Invalid Hostname)".

Here is how I have my network setup:

NetGear Router hooked up to my cable modem, I have the server running through 1 of the 4 ports on the router. I assigned the server a static internal IP. I have had people test my FTP outside of my network, that's how I know that works. I forwarded the port 21 and also 80 to the IP of the server. I also have DHCP and DNS enabled on it.

I am a bit lost on why I can't view my site and get that error, I have followed instructions to a T!!!!

Could it be a DNS issue? Could it be a port forwarding issue? Could it be an IP issue, do I need a static IP for the server or can I use a private IP?

Thanks for taking your time to help me out!


----------



## Squashman (Apr 4, 2003)

When you are on the Server what happens if you type in localhost as the url?


----------



## Synt4xError (Jan 23, 2009)

Actually I fixed it, did some intense research and found out that if I leave the Host Header Value empty, it will work. Why is this though??? Can anyone explain that too me?

Edited:
If I do localhost, it brings up "The webpage cannot be found". But when I type in my public IP in the web browser, it takes me to my site with the test page showing. Any ideas why?


----------



## Squashman (Apr 4, 2003)

Synt4xError said:


> Edited:
> If I do localhost, it brings up "The webpage cannot be found". But when I type in my public IP in the web browser, it takes me to my site with the test page showing. Any ideas why?


Is this when you are on the server and you open up IE on the server?


----------



## Squashman (Apr 4, 2003)

Synt4xError said:


> Actually I fixed it, did some intense research and found out that if I leave the Host Header Value empty, it will work. Why is this though??? Can anyone explain that too me?


What did you have in the host header?
You only really need to use the host headers if you are hosting more than one website.


----------



## Synt4xError (Jan 23, 2009)

Localhost works on the server, sorry I tried my desktop haha!

The Webserver had the default site and the one I added, the header value was named the same name I gave the website. So now it works fine.

Squashman, thank you so much for your help, even though I fixed it, you gave me some great knwoledge. I really appreciate it.


----------

