1

I have developed an ASP.NET website and deployed into my IIS server. Now to see that my IIS is installed fine, I type local host in my address bar, and I get the welcome screen of IIS and its documentation in a separate window.

Now I gave the url of my website http://localhost/mysites/site2/Default.aspx I access my site. Also giving my IP address instead of local host like: http://192.168.1.46/mysites/site2/Default.aspx also works.

Just out of curiosity I wanted to see what happens when I give my IP address in addressbar. It asks me a user name and password saying:The server 192.168.1.46:80 requires a user name and password.

I donot know what user name and password it is asking, and as of my knowledge I thought localhost points to my own IP address internally. But what is the difference and also what username and password do I need for it?

Update: On chrome and IE just giving localhost displays the welcome screen, but on mozilla, localhost is also asking for a username and password.

2 Answers 2

1

From your description it doesn't look like an issue with setting up webserver websites by name or ip, which is the two main setups for hosting multiple sites on one web server. The urls you tried at the start have a much longer path and most likely running a separate website to the default website served from the implicit root when you don't specify any path. In other words, you're accessing different websites on your webserver. On a separate note, localhost resolves to 127.0.0.1 a.k.a. loopback address; not 192.168.1.46.

1
  • running a separate website to the default website served from the implicit root sorry I dint get you. And why is the behaviour different in different browsers?
    – Cdeez
    Aug 27, 2012 at 4:44
0

Most likely, it is a browser configuration problem. Are you using IE? then look at: http://support.microsoft.com/kb/304655. Othrwise try different browser.

Or

Make sure that you have anonymous access configured correctly in your IIS.

Edit: I strongly suggest you to upgrade to the latest version of IIS. I'm pretty sure that these problems will go away. If you're stuck with 5.1 try the following:
Open IIS -> Right click on your website in the left tree -> properties -> Directory security -> Anonymous access and authentication control -> Tick "Allow IIS to control password".

5
  • There's an update in my question. Mozilla doesn't allow me access localhost too.. And what is anonymous access?
    – Cdeez
    Aug 27, 2012 at 4:39
  • @Cdeez, What version of IIS are you using?
    – user1626711
    Aug 27, 2012 at 4:47
  • its IIS 5.1 version
    – Cdeez
    Aug 27, 2012 at 4:50
  • @Cdeez, see my edit.
    – user1626711
    Aug 27, 2012 at 4:55
  • I cannot upgrade IIS since I am using XP and it only comes with 5.1 version of IIS. There are no ways that I found on net to update it too. And as you said the Allow IIS to control password to check was already checked. Unchecking it also makes no difference
    – Cdeez
    Aug 27, 2012 at 6:02

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .