in

SharePoint Blogs

The Best Place for SharePoint-related Blogs

Mirjam's blog

Blogging about SharePoint related stuff

Renaming a MOSS Server

Renaming a MOSS server is meticulous job. If anything goes wrong along the way chances are that you need to reconfigure your whole MOSS environment.

Here are the steps to take, and the order in which to take them if you want to rename a server that has MOSS already installed and configured on it:

*** NOTE: Use only letters, digits and minus for the machine name (so no underscores), max 15 characters.

  • Change each alternate access mapping for your MOSS/WSS deployment in Central Administration:
    • Open Central Administration, "Operations" Tab, "Alternate access mappings" link
    • Modify each mapping item to reflect your newly chosen server name
  • Use stsadm.exe to invoke the "renameserver" command option:
    • Open a command prompt window
    • cd "C:\Program Files\Common Files\Microsoft Shared\web server extensions\12\BIN"
    • stsadm -o renameserver -newservername <newname> -oldservername <oldname>
  • Rename your Server via Change Name Operation in Windows Server 2003:
    • Start Menu | Control Panel | System, "Computer Name" tab, "Change" button.
    • Input your new server name
  • Reboot the server NOW.
  • After reboot, open command prompt
    • cd C:\Program Files\Common Files\Microsoft Shared\web server extensions\12\BIN
    • stsadm -o updatefarmcredentials -userlogin <domainuser> -password <password>
    • iisreset /noforce
  • Check all application pool identities in IIS, update where the old machine name is still there.
  • If you already have a search index drop this, and rebuild it

Your server is now renamed.

Comments

 

28 Links Today (2007-08-06) said:

Pingback from  28 Links Today (2007-08-06)

August 6, 2007 10:27 AM
 

Marcel said:

Great post!

That's what I've been searching for.

August 7, 2007 2:33 AM
 

Links (8/7/2007) « Steve Pietrek’s SharePoint Stuff said:

Pingback from  Links (8/7/2007) &laquo; Steve Pietrek&#8217;s SharePoint Stuff

August 7, 2007 7:30 PM
 

HIcham said:

Goede post Mirjam.. dit had ik nodig! :)

August 9, 2007 10:00 AM
 

Tom said:

Can this be used for WSS 3.0??

It certainly seems like it, these appear to be standard SharePoint Stsadm commands.

Please amend your blog entry to include WSS 3.0 servers.

Thank you, tom

August 14, 2007 7:58 AM
 

Martijn Zoomers said:

Indeed Tom, the same goes for Windows SharePoint Services 3.

August 15, 2007 4:57 AM
 

SharePoint, SharePoint and stuff said:

Anwender revoltieren, wenn man ihnen ihr SharePoint wegnehmen will - nachzulesen bei RTodd . Tiffany

August 16, 2007 12:29 PM
 

/* comment */ said:

Thank you so much - your help on this saved so much time!

August 21, 2007 6:16 AM
 

Stefan Goßner said:

WSS 2.0 Best Practices: Using Disposable Windows SharePoint Services Objects Creating a link-enabled

August 21, 2007 11:11 AM
 

Juan Larios said:

thanks I was stuck using a servername that really was less than desirable, thanks for the post

August 21, 2007 5:41 PM
 

Chris said:

What about SQL 2005?  Do I need to change it.  We are using one single machine to host both Sharepoint 2007 and MSSQL 2005.

*** MSSQL 2005 is the DB engine for Sharepoint 2007.

August 23, 2007 4:12 AM
 

Mirjam said:

Hi Chris,

The steps described above are also sufficient for renaming a server with both SharePoint 2007 and SQL 2005 on it.

Regards,

Mirjam

August 24, 2007 1:21 AM
 

Chris said:

Thanks, Mirjam.

Just to confirm, I will need to change anything for the MSSQL 2005 server.

August 24, 2007 1:59 AM
 

Mirjam said:

That's correct Chris, you don't need to perform any additional actions on the MSSQL 2005 server for renaming your MOSS environment.

August 24, 2007 8:27 AM
 

chris said:

Thank you very much!

August 26, 2007 9:27 PM
 

Alejandro said:

Thanks!

August 28, 2007 6:44 PM
 

Markus said:

Didn't believe it - but it worked :-)

Thanks

September 4, 2007 9:15 AM
 

Varsha said:

Wish i had found this solution before...

September 10, 2007 10:58 PM
 

Mick Casper said:

Awesome! This worked like a charm!!!!

YOU ROCK, thanks!!!

=)

September 13, 2007 5:00 PM
 

Bart Wessels' Blog said:

Mirjam van Olst van Macaw heeft een interessante post over renaming: Renaming a MOSS server is meticulous...

September 22, 2007 2:11 AM
 

SharePoint 2007 link love 09-22-2007 at Virtual Generations said:

Pingback from  SharePoint 2007 link love 09-22-2007 at  Virtual Generations

September 22, 2007 5:20 AM
 

bspead said:

regarding the last point:

"If you already have a search index drop this, and rebuild it"

Is this necessary only for the indexes of content stored on the MOSS server itself (which contain the old name in the URL)?  Or do external content sources need to be recrawled as well?  I am asking because I have a complicated set of external sources, some of which need to have crawls kicked off manually with Crawl Rules changed between crawls and this takes several days.  If I can get away with just recrawling the MOSS server it would be great, but I want to be prepared in case I need to drop the entire index.

September 27, 2007 4:57 AM
 

Mirjam said:

Hi bspead,

In MOSS 2007 there is only one index.

Unfortunately this means that if you drop it you drop everything including the external content sources that were crawled.

The only way to create more than one index is by using more than one Shared Service Provider. If this would be the case I don't think you would need to drop the index with the external content in it.

From TechNet:

Office SharePoint Server 2007 supports one content index per SSP. Given that we recommend a maximum of 20 SSPs per farm, a maximum of 20 content indexes is supported.

Note that an SSP can be associated with only one index server and one content index. However, an index server can be associated with multiple SSPs and have a content index for each SSP.

More info can be found here:

technet2.microsoft.com/.../6a13cd9f-4b44-40d6-85aa-c70a8e5c34fe1033.mspx

September 28, 2007 5:54 AM
 

Ben said:

Thank you - let me clarify the question.  

Is it necessary to actually drop the index?  Or would it be sufficient for me to do a full crawl of the MOSS content, which should overwrite those URLs pointing to pages on the MOSS server?

I didn't know if there was information other than the individual rows of the index table containing pointers to the MOSS server which needs to be reinitialized.

Thank you in advance :)

Ben

September 28, 2007 9:23 AM
 

Mirjam said:

Hi Ben,

Yep, you need to actually drop the index. Doing a full crawl isn't sufficient in this case. I'm sorry.. :-(

I must admit that I don't know exactly why, but I know it causes problems if you don't.

Mirjam

September 28, 2007 9:37 AM
 

Ben said:

Thank you - this is good to know in advance :)  I'll plan time in for rebuilding all my external content source indices.

Thanks again for your great writeup!

- Ben

September 28, 2007 2:12 PM
 

Ben said:

One of the things that I didn't notice in the list - changing the URLs of the SharePoint sites in the Content Sources.  Do I need to change from http://oldMOSSServerName/ to http://newMOSSServerName/ in the "start addressed" box?  Or does it still recognize http://newMOSSServerName/ due to how the content sources are registered?

Also, there is an sps3://newMOSSServerName/ starting address in there - what is that for?

Thanks all for the help,

Ben

October 1, 2007 7:29 PM
 

DM said:

Good thing I ran into this when I did.. I got a little too trigger happy and decided to just rename the server.. In case any one renamed the server before doing the steps above, just rename it back and then follow the steps; it'll work.

Thanks for putting this together!

DM

October 3, 2007 6:28 PM
 

Raji A said:

Hi

What would you do if you have to move the server into a DMZ and rename it. There is no domain credentials carried over.

Cheers

October 15, 2007 10:20 PM
 

Bryan van Rijn said:

Thanks for your post,....

Note: if you have an MSSQL 2005 server running on the same machine aswell, execute the following query on your SQLServer:

<code>

sp_dropserver 'OldServerName\Instance'

go

sp_addserver 'NewServerName\Instance'', 'local'

</code>

November 2, 2007 4:29 AM
 

vijay said:

Thanks for the post. It helped a lot.

I followed the steps. Everything works except the 'MySite' on the portal. It is still pointing to the old server name. Anyway to chaneg this?

November 2, 2007 11:20 AM
 

Tom said:

Hi,

I renamed my WSS 3 server using your instructions (using MSSQL DB on same box) and everything worked except for a recurring error 1000 in the Event Log (in the event description there is another error code #50070). A search of this error number seems to indicate that the Sharepoint Timer Service is still trying to access the ConfigDatabase using the original server name. The rest of the installation works fine (config, site collections, etc). I tried to run a backup but it never started because I think the Timer Service is not working correctly. The account the Timer Service service uses is correct. Any ideas?

Thanks in advance.

November 2, 2007 5:52 PM
 

Tom said:

I figured out my problem with the Timer Service generating errors. Turns out there was a DSN in the registry that still referenced the old SQL servername. I changed this entry to the correct SQL server name and the errors went away and the Timer Service started working correctly. The registry entry that needed to be changed was [HKEY_LOCAL_MACHINE}/Software/Microsoft/Shared Tools/Web Server Extensions/12.0/Secure/ConfigDB/dsn

Cheers,

Tom

November 5, 2007 12:55 PM
 

Mirjam said:

Hi Tom,

Thanks for answering your question here as well!

I hadn't heard this one before..

Regards,

Mirjam

November 6, 2007 4:40 AM
 

Mirjam said:

Hi Vijay,

Do I understand correctly that the "My Site" link on the top right corner of the portal is pointing to the wrong url?

I must say, I never tried renaming a server when My Sites were already created, although I would expect it to work normally.

Regards,

Mirjam

November 6, 2007 4:43 AM
 

Mirjam said:

Thanks for the addition Bryan!

November 6, 2007 4:43 AM
 

Bob harris said:

what exactly do you mean by ' Check all application pool identities in IIS, update where the old machine name is still there. ' i checked and did not see any server names here. I carried out the whol einstruction and cannot see my sites, except for configuration console.

November 18, 2007 9:56 PM
 

Tony said:

this is my second attempt in posting due to error and lost a looong text of post so will keep it short and right to the point.

Please help!

-my installation runs the default SQL server like DB on same machine.  

-I had to rename the server from hostname1 to hostname2.domain.com in order for users not part of our network to be able to access.

-followed the instruction above, everything went smooth, then lastly did the machine name change and reboot.

-now can not access Sharepoint sites or the Central Administration.

-error on Event log, this seemed to be the main error.

Event_ID: 3355

Cannot connect to SQL Server. hostname2.domain.com\MICROSOFT##SSEE not found. Additional error information from SQL Server is included below.

[DBNETLIB][ConnectionOpen (Connect()).]SQL Server does not exist or access denied.

on the bottom right of my window, it shows that the database is running on HOSTNAME2.  is this discrepancy in causing the problem?  This is a production intranet that went live last week, any help anyone can provide me would be greatly appreciated!!

Tony

I followed the instruction,

November 19, 2007 11:33 AM
 

Matthias Krehl said:

Hi Vijay,

did you solve the problem with "My Site"? Same trouble here, no solution yet.

Regards,

Matthias

November 22, 2007 3:12 AM
 

Matthias Krehl said:

Hi Mirjam, hi Vijay,

> did you solve the problem with "My Site"? Same

> trouble here, no solution yet.

having said that I stumbled across something called 'SharedServices1' comming from central administration. There we were able to configure MySite. Everything fine now.

Thanks for this blog!

Matthias

November 22, 2007 4:30 AM
 

Matthias Krehl said:

Oops, last post didn't make it. Once again, thanks and: the answer to the 'MySite'  trouble is to use the 'SharedServices' from central administration. There you can configure the 'MySite's.

Matthias

November 23, 2007 4:29 AM
 

Tony said:

Hi,  

Please disregard my post.  I ended up reinstalling the OS and recovering the site.  For my purpose, using the alternative access mapping only seemed to work.

If you are using the internal database that comes default with Sharepoint Service on a single tier installation, I strongly recommend not changint the machine name.

Cheers.

Tony

November 28, 2007 5:20 PM
 

Pankaj Adlakha said:

Hi Mirjam:

Thank you  so much for this great post...it came as ready made solution to my situation in which I had changed the name of the machine after installing MOSS 2007, and web application stopped connecting to the database with the message "Cannot connect to the configuration database". I just followed the steps you mentioned and it started working again.

Thank you so much again.

-Pankaj

November 30, 2007 12:46 PM
 

Amol Sonkul said:

Hi,

Very Nice post. Thanks a lot.

December 26, 2007 2:54 AM
 

Hassan said:

Great post!

I am working with like a Pro

January 2, 2008 2:16 PM
 

Tom C said:

How do you go about dropping the index?

January 15, 2008 7:53 AM
 

Mirjam said:

Hi Tom,

Go to the Central Administration to the Shared Service Provider.

Next go to Search Settings.

The last link in the Crawl Settings area is "Reset all crawled content. This will drop the index. Or in Microsoft's own words:

"Resetting the crawled content will erase the content index. "

Good luck!

Mirjam

January 25, 2008 8:59 AM
 

Reynaldo said:

Hi All,

I'm new to Sharepoint and have been setting up and playing with Sharepoint 2007. I am required to change the machine name that has Sharepoint 2007 and SQL 2005 installed on it. Is the above procedure for renaming Sharepoint 2007 server etc....

Secondly, dumb question time, "MOSS" can this refer to "Microsoft Office Sharepoint Server" & "Microsoft Office Search Server"? Sorry in advance for the novice questions!

Kind regards.

February 12, 2008 2:47 PM
 

SharePoint 2007 How To List « SharePoint Sherpa said:

Pingback from  SharePoint 2007 How To List &laquo; SharePoint Sherpa

February 12, 2008 7:30 PM
 

Chris said:

Hi,

We have recently moved our sharepoint server, after moving came across the Cannot connect to the configuration database error when trying to goto both the admin site and normal site/s. I have followed these steps, but when I run the command updatefarmcredentials I get the following error:

Error updating the administration application pool credentials.

Help??

March 2, 2008 5:57 PM
 

Rosario said:

Hi everyone,

I have recently renamed an existing domain. Everything is working fine in new domain. After rename my SQL sever 2005 does not work. I found the sql server mangement studio was missing.I have zero knowledge in SQL. Please help me,

Thankyou

clementrosario@gmail.com

March 16, 2008 12:44 PM
 

Ved said:

Hi,

I changed the machine name (in fact domain name as well as machine name) before changing the server name. So i m gettiing the error: "Can not connect to Configuration Database".

I tried the method above...but to no avail.

Is there a way ...i can get my sites  working now. As Central Administration is also not working now...i can not create new sites even.

Thanks

March 19, 2008 5:28 AM
 

"Sharepoint User Group" on LinkedIn said:

Useful blogs / articles..

March 27, 2008 4:50 AM
 

Sourabh Jain said:

Hi Mirjam,

         Thanks for such informative blog. I have some alike issues In my case the system is having MOSS7 and MSSql 2005 we have got system when client had already changed the machine name and IP address so we were not able to reconfigure the MOSS7 and then we rename the server to rectify the issue with the MSSql 2005 and executed the sp_dropserver and sp_addserver respecively but still not able to configure the MOSS7 back on the box. Please give your valueable comments to resolve this issue as now we want the old sites to be restored and make the system back into action. Currently the site that was hosted on MOSS7 is down and we are not even able to access the central admin of MOSS7 but able to log in the database. When we run the configuration wizard it throughs error while connecting to data base in step 2 the installation of our is stand alone. Please respond asap.

March 30, 2008 2:06 PM
 

Aaron said:

I used this method to rename my server, but I found alot of little things that had to be retouched. All my Logo URL's had to be pointed to the new server name. Any custom pages with url's had to be modified.

My deployment is not very large right now, but I could see this being a major headache depending on what content you've got. I guess the answer is to be careful to use relative url's whenever possible.  

April 24, 2008 1:10 PM
 

Hegde said:

How do I access my site on MOSS 2007 site after changing my System IP address? Before changing the IP address I was able to access my site and work with it. Now its not working after changing the IP address.

Appreciate if anybody gives a solution for this problem ?? Thanks.

May 13, 2008 8:08 AM

Leave a Comment

(required )  
(optional )
(required )  
Add

About Mirjam

Mirjam van Olst works as a lead SharePoint developer at Macaw in the Netherlands. She started working for Macaw in April 2004. Before that she had her own company (Van Olst Websolutions) with which she build web applications. Mirjam has specialized in SharePoint development since June 2004. She started working with the 2007 Office system in may 2006. She has implemented several world-wide intranet environments based on SharePoint. She also gives presentations about MOSS 2007 on a regular basis and occasionally writes articles about MOSS related subjects.

Need SharePoint Training? Attend a SharePoint Bootcamp!

Posts (c) their respective authors. Everything else (c) 2007 SharePoint Experts