locked
Move SQL Server RRS feed

  • Question

  • I would like to move my OCS databases to a different back-end SQL server.  I have read the LCS documentation regarding this process, I assume that the process is similar, is there any documentation available that describes the steps for OCS?

    Monday, September 24, 2007 3:22 PM

All replies

  • Yes, except that you now have the RTCDyn database as well.  The process is:

     

    - Detach RTC, RTCConfig, and RTCDyn

    - Copy the ldf and mdf files to the new server

    - Attach the databases

    - Run lcscmd with the /updatepoolbackend switch
    Monday, September 24, 2007 3:27 PM
    Moderator
  • If I do a detach from the existing SQL server and then an attach on the SQL server does this mean that the exporting & importing of the config files is not necessary as specified in the LCS document? 

     

    This seems like it should be a standard SQL db move to a different server and then running the lcscmd /updatepoolbackend?  Have you done this before?

    Monday, September 24, 2007 6:20 PM
  • There is no need to export or import anything using that method.  As long as the databases come up successfully on the new server you should be good to go.  Make sure to allow for AD replication time after running /updatepoolbackend.  OCS reads the pool location information form AD upon startup.

    Monday, September 24, 2007 8:17 PM
    Moderator
  • Hi,

     

    I would like to move my Back end database to.

     

    I assume I should stop the OCS services before detaching by databases?

    isn’t it ?

     

    If that method doesn't work will it be possible to follow the LCS procedure?

     

    Thanks

     

    Rol

     

     

    Tuesday, September 25, 2007 2:32 PM
  • Yes, you should absolutely have all your OCS services stopped prior to working with the database.

     

    Tuesday, September 25, 2007 8:09 PM
    Moderator
  • I have followed these steps in my lab environment:

    - Detach RTC, RTCConfig, and RTCDyn

    - Copy the ldf and mdf files to the new server

    - Attach the databases

    - Run lcscmd with the /updatepoolbackend switch

     

    And the updatepoolbackend finishes successfully but the OCS services will not start.  They get a bunch of WMI errors, which basically say that the OCS server cannont connect to the new SQL server.  The permissions look identical on the source and target SQL servers.

    Thursday, September 27, 2007 4:22 PM
  • It looks like there is a failed logon causing the problem.  The rtcservice is not able to logon to the SQL server/db.  What permissions are required that would not have come across with the attach process?

     

    Thursday, September 27, 2007 5:21 PM
  • Used this KB article - http://support.microsoft.com/kb/918992/en-us - to bring over the permissions from the source SQL to the target SQL.  Also needed to run a stored procedure to provide db chaining.  After running both of these tasks the OCS services started up.

     

    Are there any specific events that I should look for in the event logs.  According to the LCS doc there is one event 30024, are there any others?

    Thursday, September 27, 2007 7:13 PM
  • Hi I hope that this is of use to you....

     

    To move OCS database, detach the RTC, RTCConfig, and RTCDyn databases from the Enterprise pool and move the database files to the new location.

     

    1.       Verify that the databases are backed up.

    2.       Log on as user in RTCUniversalServerAdmin group.

    3.       Stop all OCS 2007 Services in the pool (AV,Web, FrontEnd)

    4.       Log on as user in Administrators group to the SQL Backend server.

    5.       Open SQL Server MGMT Studio.

    6.       Find the Databases RTC, RTCconfig, and RTCDyn and detach them dropping connections.

    7.       Move the .mdf and .ldf DB files to the new location or server.

    8.       Attach the 3 databases. If on a different server, log on as user in Administrators group to the new SQL Backend server.

    9.       Open up the SQL Server Mgmt Studio and right click on Databases and then attach.

    10.   Verify all 3 databases RTC, RTCconfig, and RTCDyn show up under the databases in SQL Server Mgmt Studio.

    11.   Log on as user in RTCUniversalServerAdmins group and run OCS setup.

    12.   Run Deploy Pool Wizard and choose consolidated or expanded topology according what is being used.

    13.   Deploy the pool with the same settings before the database move You will need the following:

    a. Pool name.

    b. Domain

    c. Pool FQDN

    d. SQL Server Instance (the new SQL server where the database is or if just moving database locations, the same SQL server name )

    e. Internal and External Web farm FQDNs.

    f. Meeting Content, Meeting Metadata, and ABS share locations.

    14.   MAKE SURE TO CLEAR the Replace existing database check box. (If you don't you will have to restore the databases as all info will be wiped out).

    15.   Finish the Deploy pool wizard.

    16.   Verify deployment was successful.

    17.   Start services in order for Front-End, IM Conferencing, Telephony, and Web Conferencing services.

     

    These steps are details on Technet.http://technet.microsoft.com/en-us/bb936638.aspx

     

    Friday, June 6, 2008 12:37 AM
  • I did slightly less. Our situation was that we are planning to upgrade from OCS 2007 to OCS2007 R2 - and as the OCS R2 installation requires a new pool, but with the same database names, we had to move the OCS databases from the default instance to a named instance on the same server.

    This is what I did;
    1. Stop all OCS services on the OCS Pool servers (in Manage My Computer, Services and Applications, right-click on the OCS component and choose "stop all started services")
    2. Back up the RTC, RTCCONFIG and RTCDYN databases on the Database server
    3. Detach those three databases from the database server (in my example from the named instance), checking the box to drop existing connections
    4. Move the mdf files from the source to the destination database server (in my example, we didn't move files). Also move ldf files, keeping the file structure.
    5. Follow the instructions in http://support.microsoft.com/?kbid/918992 to export all security from the source database server to the destination database server - even if you are moving from the default instance to a named instance on the same server like I did.
    6. Attach the 3 databases to the new database server; Right click on the "Databases" folder in SQL Management studio, choose attach, browse to the mdf file. If the ldf file is in the same drive letter and path as before (step 4), then press OK, otherwise ensure that the ldf file path is correctly specified in the "Database details" box.
    7. On the OCS server, I opened a command prompt and went to C:\Program Files\Common Files\Microsoft Office Communications Server 2007\ and ran the command    LcsCmd.exe /forest /action:UpdatePoolBackend /poolname:pool01 /poolbe:SQLServer1\INSTANCE1   - changing the names to match my pool name and DB server\instance name. This took 600 milliseconds to run.

    Once all three databases are mounted, I tried to start the OCS service, but the "Front End" service would not start. I found an event log entry ID 12304 which was unusual because not only was it helpful, but it also told me how to fix the problem;

     On the new database server instance, select the database "RTC" and open a new query window. Type  "sp_dboption '<dbname>', 'db chaining', TRUE"  where you change <dbname> to rtc, rtcdyn and then rtcconfig - then execute this command. I did this command for all three database names, on all three databases. Someone will probably tell me which ones you need to do, but I did all.
    8. Then I started all OCS services, in the same way as step1.

    The OCS services all started and everything worked fine.
    Monday, April 13, 2009 11:39 PM
  • Antk - Can you clarify? Does step 11 (and steps 12-16) get run on the database server or on the OCS server?
    Monday, April 13, 2009 11:40 PM