Rename SharePoint Host Headers and Change Database Server Name

I currently have a SharePoint 2007 demonstration setup on a development environment. The SharePoint 2007 installation was originally setup for a specific client. So the host headers, computer name and farm credentials contained the client name. This all had to be changed. Carrying out another installation of SharePoint was something I did not want to do since I wanted to retain all the dummy data and sites.

You might be thinking: Why don’t I just change the host headers with the new client name? Well that’s because I am a bit OCD and I like everything to be consistent. Tongue out

To rename, carry out the following. But remember to carry out these steps exactly because you might come across the problem I did where I couldn’t get to Central Admin or view my Intranet:

  1. Go to Central Admin > Operations > Alternate Access Mappings.

  2. Change the host headers as required.

  3. If you changed the name of the server carry out the following command:
    stsadm -o renameserver -oldservername <oldname> -newservername <newname>

  4. Rename the server to a new server name by going to My Computer > Properties > Computer Name and restart.

  5. After restart you will need to update the farm login credentials since the computer name has been changed from Steps 3 and 4. If you do not update the farm credentials, you will get the dreaded “Cannot connect to database” message when trying to view your Intranet.
    stsadm -o updatefarmcredentials -userlogin <domain\user> -password <password>

  6. Change the site names in IIS. This site names will need to reflect the changes you made in Step 1.

  7. Change the host headers in the host file (C:\Windows\System32\drivers\etc\hosts).
blog comments powered by Disqus

About

Surinder Bhomra is a Web Developer.

He has achieved a BSc in Information Systems in 2006 and since then has been working in the IT industry.

Prior to working in the Web Development industry I have spent 1.5 years working as an IT Systems Analyst providing support for internal company systems.

Working in the Web Development industry has given me the opportunity to expand my current skills and allowing me to work on website projects using ASP, ASP.NET, CSS, HTML and SQL.

StackOverflow Flair

Disclaimer

The opinions expressed herein are my own personal opinions and do not represent my employer’s view in any way.

>