Home | Troubleshooting |  Quick Setup  |  Cisco How to  |  Data Recovery  |  Forums   | Blog | IT Exam Practice | Services  | About Us | Chicagotech MVP  | Search  | Contact Us  |                 

 

 

Move WSS content database to a different drive with SSEE using Osql.exe tool

 

If you are using WSS 3.0 with SQL Server Embedded Edition (SSEE), follow the steps below:
==========
1.  Locate the database files location. By default, these files are located in the following folder:
C:\WINDOWS\SYSMSI\SSEE\MSSQL.2005\MSSQL\Data
 
2.  Click Start, click Run, type cmd , and then press ENTER. 

3.  Start the Osql.exe tool. To do this, type osql -E -S \\.\pipe\MSSQL$MICROSOFT##SSEE\sql\query at the command prompt, and then press ENTER.
 
4.  At the osql command prompt, back up the existing databases. To do this, type the following at the osql command prompt:
BACKUP DATABASE <SharePoint> TO DISK = ' PathName '
where <SharePoint> is the name of the SSEE database, and where PathName is the path and file name that you want, such as C:\SSEE\Backup
\sharepoint.bak. 

5.  Type GO , and then press ENTER. 

6.  Repeat steps 4 and 5 for each database. 

7.  Detach all the content databases. To do this, type EXEC sp_detach_db <DatabaseName> at the command prompt, where <DatabaseName> is the
name of the SSEE database name, and then press ENTER. 

Note If you receive a message that the database is in use and cannot be detached, open the services console by entering services.msc in a Run window,
and find SQL Server 2005 Embedded Edition (MICROSOFT##SSEE), Pause and then Start it.

8. Start another command prompt, or start Microsoft Windows Explorer, and then copy both of the SSEE database files (including the .ldf files) that you
located in step 1 to the new folder that you want. 

9.  Attach all the database. To do this, type the following at the command prompt where the Osql.exe tool is running
EXEC sp_attach_db @dbname  = <DatabaseName>, @filename1 = 'd:\ new_database_location \DatabaseName.mdf', @filename2 = 'd:\
new_database_location \DatabaseName_log.ldf'
where new_database_location is the folder where you moved the database files in step 8. 

10.  At the command prompt, type quit, and then press ENTER to quit the Osql.exe tool.

We can use Microsoft SQL Server Management Studio Express - a Graphical User Interface tool to detach and attach the databases:

Download Microsoft SQL Server Management Studio Express:
http://www.microsoft.com/downloads/details.aspx?FamilyID=c243a5ae-4bd1-4e3d-94b8-5a0f62bf7796&DisplayLang=en

Post your questions, comments, feedbacks and suggestions

Contact a consultant

Related Topics

Move WSS content database to a different drive with SSEE using SQL Server Management Studio Express

Microsoft SharePoint Issues

Authentication to WSS site fails in Internet access

Can't access Microsoft #SSEE with error 26

Internet Explorer cannot display WSS or SharePoint
Problem with downloaded a zip file from WSS

Received debug error when open Word stored in WSS

Word cannot compete the save due to a file permission error

 

 


 

 

Hit Counter   This web is provided "AS IS" with no warranties.
Copyright © 2002-2018 ChicagoTech.net, All rights reserved. Unauthorized reproduction forbidden.