Thursday, July 21, 2011

Alternate local DNS and Disable Loop Back check configuration

A few days ago, i got SharePoint 2010 training (Course 10175 A, SharePoint 2010 Application Development), with Mr. Agus Suhanto. For the beginning, he start with create new Web Application at existing Application Pool, in this case we will use port 80 (default SharePoint web application).

Here are the quick step..

1. Navigate to : SharePoint Central Administration > Manage Web Applications
2. Create New Web Application (the detail as follow..) :
  • specify port number to 80
  • Use existing pool, which is pool with port number 80 

  • Don't forget to modify database name to friendly name for convenience use.
  • Click OK to create your web application and exit wizard
3. Create your Site Collection for new web application
after site collection successfully created, i'll bet you will face error 404 : webpage-not-found, if you hadn't configure alternate local DNS. So here comes the trick..

4. Run command prompt as Administrator
navigate to this folder  C:\Windows\System32\drivers\etc>
and if you look all files at that folder, you will find file named "hosts" that don't have extension file, yet we will edit this through notepad..
execute this command at that folder : notepad hosts
and it will look like this at window 7 :
add new line and specified with your host header when you input at new web application wizard, in my case it is

5. if you still cannot access that url, it must be because of loopback authentication, and it will denied your access even you are the server farm administrator.
Here comes another trick.. (or if you prefer, you can googling with keyword "DisableLoopbackCheck")

  • run regedit at your machine
  • navigate to HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa
  • right click, and choose New > DWORD (32bit)
  • name it DisableLoopbackCheck
  • modify its hexadecimal value to 1
6. Access your web

note :
i have tried both at windows 7 (my laptop) and windows server 2008 R2, and it is work for both of it as long as you have administrator right.

No comments:

Post a Comment