SharePoint Upgrade Error on Individual sites - Gradual Approach

Scenario:
When we tried to upgrade individual site from SharePoint 2003 to MOSS 2007, individual site upgrade resulted error:
Please refer to the upgrade log at C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\12\Logs\Upgrade.log and the trace log for additional information.

Status Job failed
Mode Side-By-Side
Elapsed Time 
Starting object SPMigratableSiteCollection Parent=SPManager
Current object 
Current action 
Step within the action 
Total steps in this action 
Server  ABC
It gave me two options, either resume or delete. I checked Upgrade.log and it has following entry:

[SPSiteCollectionMigrator] [DEBUG] [7/30/2008 3:08:01 PM]: ————- Begin SPMigratableSiteCollection ————-
[SPSiteCollectionMigrator] [DEBUG] [7/30/2008 3:08:01 PM]: SPSite Url=http://abc/sites/xyz
[SPSiteCollectionMigrator] [DEBUG] [7/30/2008 3:08:01 PM]: ————– End SPMigratableSiteCollection ————–
[SPServerSequence] [DEBUG] [7/30/2008 3:08:01 PM]: [SPServer Name=SQL10 Parent=SPFarm Name=SharePoint_Config] BuildVersion = 12.0.0.4518.
[SPServerSequence] [DEBUG] [7/30/2008 3:08:01 PM]: [SPServer Name=SQL10 Parent=SPFarm Name=SharePoint_Config] SchemaVersion = 3.0.2.0.
[SearchServiceInstanceSequence] [DEBUG] [7/30/2008 3:08:01 PM]: [SPServer Name=SQL10 Parent=SPFarm Name=SharePoint_Config] SchemaVersion = 12.0.1.0.
[SPServerSequence] [DEBUG] [7/30/2008 3:08:01 PM]: [SPServer Name=SQL10 Parent=SPFarm Name=SharePoint_Config] BuildVersion = 12.0.0.4518.
[SPServerSequence] [DEBUG] [7/30/2008 3:08:01 PM]: [SPServer Name=SQL10 Parent=SPFarm Name=SharePoint_Config] SchemaVersion = 3.0.2.0.
[SearchServiceInstanceSequence] [DEBUG] [7/30/2008 3:08:01 PM]: [SPServer Name=SQL10 Parent=SPFarm Name=SharePoint_Config] SchemaVersion = 12.0.1.0.
[SPUtility] [DEBUG] [7/30/2008 3:08:01 PM]: File C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\60\Template\sql\store.sql, Time out = 600 sec
[SPSiteCollectionMigrator] [DEBUG] [7/30/2008 3:08:17 PM]: PregrowTempDatabase: computing the size of temp db.
[SPSiteCollectionMigrator] [DEBUG] [7/30/2008 3:08:17 PM]: PregrowTempDatabase: target size 20 MB.
[SPSiteCollectionMigrator] [DEBUG] [7/30/2008 3:08:17 PM]: SPContentDatabase2 Name=EnPointe1_SITE Parent=SPDatabaseServiceInstance FullTextSearchEnabled: True
[SPManager] [ERROR] [7/30/2008 4:08:18 PM]: Migrate [SPMigratableSiteCollection Parent=SPManager] failed.
[SPManager] [ERROR] [7/30/2008 4:08:18 PM]: Timeout expired.  The timeout period elapsed prior to completion of the operation or the server is not responding.
[SPManager] [ERROR] [7/30/2008 4:08:18 PM]:    at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection)
   at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection)
   at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj)
   at System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj)
   at System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString)
   at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async)
   at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, DbAsyncResult result)
   at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult result, String methodName, Boolean sendToPipe)
   at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
   at Microsoft.SharePoint.Utilities.SqlSession.ExecuteNonQuery(SqlCommand command)
   at Microsoft.SharePoint.Upgrade.SPContentDatabase2.set_FullTextSearchEnabled(Boolean value)
   at Microsoft.SharePoint.Upgrade.SPSiteCollectionMigrator.Migrate()
   at Microsoft.SharePoint.Upgrade.SPManager.Migrate(Object o, Boolean bRecurse)
[SPManager] [DEBUG] [7/30/2008 4:08:18 PM]: Elapsed time migrating [SPMigratableSiteCollection Parent=SPManager]: 01:00:17.0340845.
[SPManager] [INFO] [7/30/2008 4:08:18 PM]: Gradual Upgrade session finishes. root object = SPMigratableSiteCollection Parent=SPManager, recursive = True. 1 errors and 0 warnings encountered.
[SPManager] [DEBUG] [7/30/2008 4:08:18 PM]: Removing exclusive upgrade regkey by setting the mode to none

Workaround:

When you have the situation where “Resume” and “Delete” buttons are available for site upgrade. Open “upgrade.log” and look for [ERROR]. Check the line preceding the line where [ERROR] is written and you will find entry with a GUID like following:
[SPWebTemplateSequence] [DEBUG] [7/30/2008 3:08:01 PM]: Template SPSSITES#0: Activating feature a311bf68-c990-4da3-89b3-88989a3d7721 in site with URL “http://abc/xyz“, force=False.
Note GUID:a311bf68-c990-4da3-89b3-88989a3d7721. Go to STSADM.exe and run the following command:
stsadm –o activefeature –id GUID –url http://abc/xyz
Click on resume button and if the status remains same, repeat this until error is removed.

Comments

MOSS 2007: LoadBalancer.RegisterLauncher failed

Description:

Event Viewer of MOSS 2007 server machine filled with “LoadBalancer.RegisterLauncher failed” error after almost every 30 to 40 seconds. Description is as under:

Event Type: Error
Event Source: Office SharePoint Server
Event Category: Launcher Service
Event ID: 6102
Date:  8/18/2008
Time:  8:45:52 AM
User:  N/A
Computer: ABC
Description:
LoadBalancer.RegisterLauncher failed:  Unable to connect to the remote server

For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp.

Workaround:

One workaround is to restart the service and this will work fine until the next restart of the machine. Other is to move from Central Administration -> Operation -> Service Account. Select the service “Load Balancer Service” and select the account “Network Service”.

Comments

After upgrade, Internet Users Cannot Access SharePoint 2003 sites

Scenario:

Our SharePoint 2003 URL is exposed to internet. Let it be http://share.companyname.com .

 Our SharePoint 2003 was running on port 80. When we upgraded using gradual approach, SharePoint 2003 was moved to another port, say, 42154 and new MOSS 2007 started running on port 80.

Now, the functionality is that when we try to access a SharePoint 2003, we are redirected. Like if when we tried to access http://share.compantname/sites/abc , we were redirected to SharePoint 2003 and URL turns out to be http://share:42154/sites/abc. This works find for intranet users but for internet users http://share:42154/sites/abc is not Fully Qualified Domain Name (FQDN), so they get stuck with page not found error.

 

Workaround:                                  

What we did was used SSL for port 42154. One can do this by going to IIS Manager, select Web Site running SharePoint 2003. Right click and click on properties. In front of TCP PORT: 42154, you have SSL Port: test box. Write 443. You will be able to access SharePoint 2003 sites using httpS://share.companyname.com/sites/abc

 

What went wrong?

When started Upgrade by clicking on “Begin Upgrade”, we didn’t put host header name and did not exposed that host header to internet

 

 

For more explanation, kindly visit the heading “Determine and create new domain names (gradual upgrade only)” at the following link:

http://office.microsoft.com/download/afile.aspx?AssetID=AM101638521033

Comments

Upgrading from SharePoint 2003 to MOSS 2007 Using Gradual Approach

Of all the three upgrade techniques, my favorite is database migration but of our client requirement was Gradual Upgrade. These steps are done for upgrade from WSS2.0/SharePoint 2003 to WSS3.0/MOSS 2007 in a single form environment. For different architecture, you may need some more steps. Also, we have to face with almost zero customization. Steps for upgrading from SharePoint Portal Server 2003 to Microsoft Office SharePoint Server 2007 using the gradual approach are as under:

 

1. Download and install Microsoft .NET Framework Version 3.0 Redistributable Package (x86) from the following URL:

 

http://www.microsoft.com/downloads/details.aspx?FamilyID=10CC340B-F857-4A14-83F5-25634C3BF043&displaylang=en 

 

2. Run PreScan.exe. The steps for running PreScan can be found at the following URL:

 

http://farhanfaiz.wordpress.com/2008/05/15/sharepoint-upgrade-prescanexe/

 

Remove all the error that are mentioned by PreScan. 

 

3. Install Microsoft Office SharePoint Server 2007. The steps for installing MOSS 2007 are as under: 

a. Run setup.exe file, enter product key and accept License Terms.

b. First important thing to do is to choose your upgrade approach. We will select gradual approach and click install now.

  

 

 

 

 

 

 

 

 

 

 

 

 

  

 

c. After installation, you get the completion screen.  Don’t uncheck “Run the SharePoint Products and Technologies Configuration Wizard nowand click close.

 

 

 

 

 

 

 

 

 

 

 

 

 

  

 

d. Odds are you will get a screen that says you must Reboot to complete setup. If so, click “Yes”.

  

4. SharePoint Products and Technologies Configuration Wizard will run.

a. This will take you to “Welcome to SharePoint Products and Technologies” screen. Click “Next”.

 

 

 

 

 

 

 

 

 

 

 

 

 

  

 

b. It will ask about restarting server services. Click “Yes”.

c. On the language pack screen click OK. If you have any language packs to install, this is the time to do it.

d. On the “Connect to a server farm” screen, choose “No, I want to create a new server farm and click “Next”.

 

 

 

 

 

 

 

 

 

 

 

 

 

 

  

e. Specify the name of the SQL server and the account password that SharePoint will use and click “Next”.

 

 

 

 

 

 

 

 

 

 

 

 

 

  

 

f. It will inquire about the central administrator port, change it or use the default. Select “Authentication Provider” according to you needs. We selected NTLM.

g. Screen with options you selected will appear. Click “Next” to start the configuration.

h. Once this finishes, it will display a Configuration Successful screen with the information of the settings. Click “Finish”.

i. You will be automatically taken to SharePoint Central Administration 2007.

 

5. The steps for SharePoint Central Administration are as under: 

a. Move from Operation to “Services on server” under “Topology and Services”.

b. Under the server role section you will notice several options. We selected “Single Server”.

c. Now for the options at the bottom we need to get all of them started.

d. Click on “Start” for Document Conversions Load Balancer Service

e. Click on “Start” for Document Conversions Launcher Service by selecting the server and clicking on “OK”.

h. Click start for Windows SharePoint Services Search and fill out your service accounts in the form domain\username and the enter password. Accept the other defaults and click Start.

 

6. We are now ready to go on performing a gradual upgrade. The steps for upgrading sites one by one are as under: 

 

a. The first step is move from Central Administration > Operations > Site Content Upgrade Status.   

b. Select Begin Upgrade under actions. (If you SharePoint 2003 is 

exposed to internet, do check the URL :

http://farhanfaiz.wordpress.com/2008/08/16/after-upgrade-internet-users-cannot-access-sharepoint-2003-sites/)

c. List of sites will appear with the options Database names, Refresh site list, Revert Site, Upgrade settings, Site Content Upgrade Status and Finalize Upgrade.

e. Select “\” root site first to start upgrade. This will result in the following actions:

                                               I.    MOSS 2007 will occupy the port on which SharePoint 2003 is running.

                                               II.    SharePoint 2003 with all the contents will be shifted to a new port, say, 5417.

                                              III.    Shared Service Provider for MOSS 2007 will be created with the same name as that SharePoint 2003 virtual server.

                                              IV.    When a user tries to access a site which is not upgrade to MOSS 2007, he will be redirected to SharePoint 2003.

                                              V.    Select the sites one by one to upgrade from SharePoint 2003 to MOSS 2007.

                                             VI.    When all the sites upgraded from SharePoint 2003 to MOSS 2007, click “Finalize Upgrade”.

 

7. Post Upgrade steps are as under:

 

a. Uninstall SharePoint portal Server 2003 (Stop SharePoint Portal Server Search Service first).

b. Delete Portal Configuration and Content Databases.

Comments

MOSS 2007: Server error: http://go.microsoft.com/fwlink?LinkID=96177

While trying to install WSS 3.0 SP1 (http://technet.microsoft.com/en-us/office/sharepointserver/bb735839.aspx) the installation get stuck at task 9 of 10 of SharePoint Products and Technology Configuration Wizard. When tried to access the server, encountered the following error:

 

Server error: http://go.microsoft.com/fwlink?LinkID=96177

 

When look into the “Event Viewer”, found the following error description:

 

The schema version (3.0.149.0) of the database DATA
DATABASE_NAME on DATABA_SESERVER_NAME is not consistent with the expected database schema version (3.X.X.X) on DATABASE_NAME.  Connections to this database from this server have been blocked to avoid data loss.  Upgrade the web front end or the content database to ensure that these versions match.

 

Resolution:

 

The first thing we did was either remove content database from the web application which are having the error or Detach the database. This doesn’t seem to work. So we run the command

 

stsadm –o upgrade –inplace –url Central_Administration_URL –forceupgrade

 

and we were back in the business J.

Comments (2)

MOSS 2007: Event Viewer Error Code 6482 and 6398

Recently we encountered a problem in the Event Viewer of MOSS server machine. The event viewer is getting populated after approximately every 40 second with the Error Code 6482 and 6398. Details of the error are as under:-

 

Event ID:   6482

 

Event Type:        Error

Event Source:     Office SharePoint Server

Event Category:  Office Server Shared Services

Event ID:   6482

Date:        6/24/2008

Time:                10:12:41 AM

User:         N/A

Computer:  ABC

 

Description:

Application Server Administration job failed for service instance Microsoft.Office.Server.Search.Administration.SearchAdminSharedWebServiceInstance (f0fc6cd7-fd20-49e3-8965-218a64ed4fbc).

 

Reason: An error occurred loading a configuration file: Access to the path ‘C:\Program Files\Microsoft Office Servers\12.0\WebServices\Root\ibgueyl_.tmp’ is denied. (C:\Program Files\Microsoft Office Servers\12.0\WebServices\Root\web.config)

 

Techinal Support Details:

System.Configuration.ConfigurationErrorsException: An error occurred loading a configuration file: Access to the path ‘C:\Program Files\Microsoft Office Servers\12.0\WebServices\Root\ibgueyl_.tmp’ is denied. (C:\Program Files\Microsoft Office Servers\12.0\WebServices\Root\web.config) —> System.UnauthorizedAccessException: Access to the path ‘C:\Program Files\Microsoft Office Servers\12.0\WebServices\Root\ibgueyl_.tmp’ is denied.

   at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)

   at System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy)

   at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access)

   at System.CodeDom.Compiler.TempFileCollection.EnsureTempNameCreated()

   at System.CodeDom.Compiler.TempFileCollection.AddExtension(String fileExtension, Boolean keepFile)

   at System.CodeDom.Compiler.TempFileCollection.AddExtension(String fileExtension)

   at System.Configuration.Internal.WriteFileContext..ctor(String filename, String templateFilename)

   at System.Configuration.Internal.InternalConfigHost.StaticOpenStreamForWrite(String streamName, String templateStreamName, Object& writeContext, Boolean assertPermissions)

   at System.Configuration.Internal.InternalConfigHost.System.Configuration.Internal.IInternalConfigHost.OpenStreamForWrite(String streamName, String templateStreamName, Object& writeContext, Boolean assertPermissions)

   at System.Configuration.Internal.InternalConfigHost.System.Configuration.Internal.IInternalConfigHost.OpenStreamForWrite(String streamName, String templateStreamName, Object& writeContext)

   at System.Configuration.Internal.DelegatingConfigHost.OpenStreamForWrite(String streamName, String templateStreamName, Object& writeContext)

   at System.Configuration.UpdateConfigHost.OpenStreamForWrite(String streamName, String templateStreamName, Object& writeContext)

   at System.Configuration.MgmtConfigurationRecord.SaveAs(String filename, ConfigurationSaveMode saveMode, Boolean forceUpdateAll)

   — End of inner exception stack trace —

   at System.Configuration.MgmtConfigurationRecord.SaveAs(String filename, ConfigurationSaveMode saveMode, Boolean forceUpdateAll)

   at System.Configuration.Configuration.SaveAsImpl(String filename, ConfigurationSaveMode saveMode, Boolean forceSaveAll)

   at System.Configuration.Configuration.Save()

   at Microsoft.Office.Server.Administration.SharedWebServiceInstance.ProvisionSharedResourceProviderWebConfigSettings(SharedResourceProvider srp)

   at Microsoft.Office.Server.Administration.SharedWebServiceInstance.Synchronize()

   at Microsoft.Office.Server.Administration.ApplicationServerJob.ProvisionLocalSharedServiceInstances(Boolean isAdministrationServiceJob)

 

For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp.

 

 

Event ID:   6398

 

Event Type:        Error

Event Source:     Windows SharePoint Services 3

Event Category:  Timer

Event ID:   6398

Date:        6/27/2008

Time:                3:07:38 PM

User:         N/A

Computer:  ABC

Description:

The Execute method of job definition Microsoft.SharePoint.Administration.SPUpgradeJobDefinition (ID 2d9efa9c-d2e8-4be4-9312-b8ff74b93247) threw an exception. More information is included below.

 

Requested registry access is not allowed.

 

For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp.

 

Resolution:

 

After a lot of net search, the final solution was of installing Office SharePoint Server 2007 Service Pack 1 available at the URL (http://technet.microsoft.com/en-us/office/sharepointserver/bb735839.aspx).

 

But for this solution work, you should have a server with version older than 12.0.0.6219.

You can check the version number by running SharePoint Central Administration and moving to Operation to “Servers in Farm”.

 

Hope that this solution works for you as well. J

 

Comments

SharePoint / MOSS: Creating Site Programmatically

I was interested in creating MOSS 2007 site using code. I end up with the following code:

 

SPSite oSiteCollection = new SPSite(“http://servername/SiteDirectory”);            

SPWeb oWebSite = oSiteCollection.OpenWeb();

SPWebCollection oSitesCollection = oWebSite.Webs;

SPWeb newWebSite = oSitesCollection.Add(“abc”, “Document Library                 Template”, “This is site created through code.”, 1033, “STS#2″, true, false);

 

We will only explore SPWebCollection Add Method. The Add method has following parameters:

 

strWebUrl:

 

A string that contains the new Web site URL relative to the root Web site in the site collection. For example, to create a Web site at http://MyServer/sites/MySiteCollection/MyNewWebsite, specify MyNewWebsite, or to create a Web site one level lower at http://MyServer/sites/MySiteCollection/Website/MyNewWebsite, specify Website/MyNewWebsite.

 

strTitle

 

A string that contains the title.

 

strDescription

 

A string that contains the description.

 

nLCID

 

An unsigned 32-bit integer that specifies the locale ID. You can find a complete list of local ID at the following URL:

 

http://www.microsoft.com/globaldev/reference/lcid-all.mspx

 

We have used “1033” for English – United States.

 

strWebTemplate

 

A string that contains the name of the site definition configuration or site template. The following table shows the values for the default site definition configurations that are included in an installation of Windows SharePoint Services

 

Value

Site Definition

STS#0

Team Site

STS#1

Blank Site

STS#2

Document Workspace

MPS#0

Basic Meeting Workspace

MPS#1

Blank Meeting Workspace

MPS#2

Decision Meeting Workspace

MPS#3

Social Meeting Workspace

MPS#4

Multipage Meeting Workspace

WIKI#0

Wiki

BLOG#0

Blog

 

For more MOSS/WSS SiteTemplate codes, visit the following URLs:

 

http://mystepstones.wordpress.com/2008/02/14/sitetemplate-codes/

 

http://stevenjohnevans.co.uk/blogs/dotnet/archive/2007/11/25/standard-site-definitions-within-sharepoint-2007-moss.aspx

 

useUniquePermissions

 

true to create a subsite that does not inherit permissions from another site; otherwise, false.

 

bConvertIfThere

 

true to convert an existing folder of the same name to a SharePoint site. false to throw an exception that indicates that a URL path with the specified site name already exists.

   

http://msdn.microsoft.com/en-us/library/microsoft.sharepoint.spwebcollection.aspx

Comments

MOSS: Send email to all site users

The trick is simple with one prerequisite. The prerequisite is that one ocument library should exist which can be access by all users of the site.

Upload and open or open an existing MS Word Document. It will have Shared Workspace on the left of the screen. If not, click on “Shared Workspace” under “Tools” menu. “Shared Workspace” select “Members” tab and it has option “Send an email to all members…”. Click on it and get email address of all the users of the site.

Comments

SharePoint 2003 to MOSS 2007 Upgrade: Database migration

Of all the three upgrade techniques, my favorite is database migration. Database migration can be defined as “Requires the server administrator to install the new version on a separate farm or separate hardware, and then manually migrate the databases into the new environment.”

 

Database Migration enables moving to new farm or new hardware while SharePoint Portal Server 2003 environment is available and is untouched by upgrade. Microsoft says that database migration is a “Complex process that requires many manual steps and a higher risk of error. Requires additional manual steps to retain original URLs for sites. Search scopes must be re-created and search settings must be reapplied. Requires new server farm, and twice the amount of SQL Server storage space”. My advise is don’t be afraid and do try.

 

These steps are done for upgrade from WSS2.0/SharePoint 2003 to WSS3.0/MOSS 2007 in a single form environment. For different architecture, you may need some more steps. The steps are under: 

·     Get ready your MOSS 2007 environment.

·     Run PreScan on SharePoint Portal Server 2003.

·     Set the content database of SharePoint Portal Server 2003 as read only.

·     Take back up of content database of SharePoint Portal Server 2003.

·     Restore back up on SQL Server attached with MOSS 2007.

·     Create web application in MOSS 2007.

·     Remove content database of the newly created web application in MOSS 2007.

·     Attach restore database with the newly created web application in MOSS 2007.

 

And that’s itJ.

 

I am not going into the details of creating MOSS 2007 environment. We will start from the second step:

 

Run PreScan on SharePoint Portal Server 2003:

 

The first step is to run PreScan.exe. For details kindly visit the following blog:

 

http://farhanfaiz.wordpress.com/2008/05/15/sharepoint-upgrade-prescanexe/

 

Set the content database of SharePoint Portal Server 2003 as read only:

The content database of SharePoint Portal Server 2003 ends with 1_SITE like Abc1_SITE.

 

The steps for setting database as read only are:

 

For SQL Server 2000

 

1.     In Microsoft® SQL Server™ Enterprise Manager, right-click the name of the database that you want to set to read-only, and then click Properties.

2.     In the Properties dialog box, click the Options tab.

3.     Under Access, select the Read-only check box, and then click OK.

 

 

For Server 2005

1.     In Microsoft SQL Server Management Studio, right-click the name of the database that you want to set to read-only, and then click Properties.

2.     In the left pane, click Options.

3.     In the right pane, under Other options, under State, next to Database Read-Only, click the down arrow, and then select True.

 

Take back up of content database of SharePoint Portal Server 2003:

 

For details kindly visit the following blog:

 

http://farhanfaiz.wordpress.com/2008/05/16/sharepoint-2003moss-2007-take-back-up-of-content-database-in-sql-server-2000-and-sql-server-2005/

 

Let the name of the back be “Portal_Site.bak”. Wait after this. The time of database backup depends upon the system power and database size.

 

 

Restore back up on SQL Server attached with MOSS 2007:

 

The first step in restoring database is to create a database in SQL Server 2005. Let the newly created database name is “Portal_Site_Restore”.

 

1.     Expand Database “Portal_Site_Restore”, right-click the database you want to restore, point to Tasks, point to Restore, and then click Database. The Restore Database dialog box appears.

2.     On the General page, the name of the restoring database appears in the To database list box.

3.     In the To a point in time text box (if using SQL Server 2005 Enterprise Edition), retain the default (Most recent possible).

4.     To specify the source and location of the backup sets to restore, click From device, and then specify the database backup path (in our case, it is “Portal_Site.bak”) in the list box.

5.     In the Select the backup sets to restore grid, select the backup path.

6.     From the options tab, select “overwrite existing database”.

7.     Specify the paths for .ldf and .mdf in the options tab.

8.     Click OK to start the restore process.

 

Wait after this. The time of restoring database depends upon the system power and database size.

 

 

Create web application in MOSS 2007

 

In the SharePoint Central Administration, move to “Application Management” and click on “Create or extend Web application” under “SharePoint Web Application Management”.

 

Again click on “Create Web application”. Set the settings according to your own needs (do check the name of the web application and content database. Let the name of the web application be “http://servername:1234” and the name of the content database be “WSS_Content_1234”) and click OK. Don’t create any site collection.

 

 

Remove content database of the newly created web application in MOSS 2007

 

We can do that using Central Administrator or stsadm utility. I will like to do that using stsadm. Central Administration is easy. You will be able to learn that if you know how to do it using stsadm.

 

The command for removing content database using stsadm is ‘deletecontentdb’. The description is as under:

 

stsadm.exe -o deletecontentdb

-url <URL name>

-databasename <database name>

[-databaseserver] <database server name>

 

Parameter name

Value

Required?

Description

url

A valid URL, such as http://serverame:1234

Yes

Specifies the Web application from which the content database will be detached.

databasename

A valid database name, such as “WSS_Content_1234”

Yes

Specifies the name of content database to be detached.

databaseserver

A valid database server, such as “SQLServer1″

No

Database server name to be detached.

 

A typical command will be like:

 

stsadm.exe -o deletecontentdb -url http://servername:1234 -databasename WSS_Content_1234

 

Attach restore database with the newly created web application in MOSS 2007

 

We can do that using Central Administrator or stsadm utility. I will like to do that using stsadm. Central Administration is easy. You will be able to learn that if you know how to do it using stsadm.

 

The command for removing content database using stsadm is ‘addcontentdb’. The description is as under:

 

stsadm.exe -o addcontentdb

-url <URL name>

-databasename <database name>

[-databaseserver <database server name>]

[-databaseuser <database username>]

[-databasepassword <database password>]

[-sitewarning <site warning count>]

[-sitemax <site max count>]

 

Parameter name

Value

Required?

Description

url

A valid URL 

Yes

URL of

the Web

application

to which

the content

database is

being

added.

databasename

A valid

database name

Yes

Database

name.

databaseserver

A valid

database