Перенос файлов баз данных Lync Standard
Останавливаем службы Lync
Stop-CsWindowsService
Подключаемся к экземпляру RTCLOCAL
ALTER DATABASE rtc SET OFFLINE WITH ROLLBACK AFTER 10 Seconds;
ALTER DATABASE rtcdyn SET OFFLINE WITH ROLLBACK AFTER 10 Seconds;
ALTER DATABASE xds SET OFFLINE WITH ROLLBACK AFTER 10 Seconds;
Подключаемся к экземпляру RTC
ALTER DATABASE cpsdyn SET OFFLINE WITH ROLLBACK AFTER 10 Seconds;
ALTER DATABASE rgsconfig SET OFFLINE WITH ROLLBACK AFTER 10 Seconds;
ALTER DATABASE rgsdyn SET OFFLINE WITH ROLLBACK AFTER 10 Seconds;
ALTER DATABASE rtcab SET OFFLINE WITH ROLLBACK AFTER 10 Seconds;
ALTER DATABASE rtcshared SET OFFLINE WITH ROLLBACK AFTER 10 Seconds;
ALTER DATABASE rtcxds SET OFFLINE WITH ROLLBACK AFTER 10 Seconds;
ALTER DATABASE xds SET OFFLINE WITH ROLLBACK AFTER 10 Seconds;
ALTER DATABASE lis SET OFFLINE WITH ROLLBACK AFTER 10 Seconds;
Подключаемся к экземпляру LYNCLOCAL
ALTER DATABASE lyss SET OFFLINE WITH ROLLBACK AFTER 10 Seconds;
Копируем файлы
xcopy c:\CsData d:\CsData /E /I /F /H /R /K /O /Y
Подключаемся к экземпляру RTCLOCAL
ALTER DATABASE rtc MODIFY FILE ( NAME = rtc_data, FILENAME = 'D:\CsData\RtcDatabaseStore\rtclocal\DbPath\rtc.mdf' );
ALTER DATABASE rtc MODIFY FILE ( NAME = rtc_log, FILENAME = 'D:\CsData\RtcDatabaseStore\rtclocal\LogPath\rtc.ldf' );
ALTER DATABASE rtcdyn MODIFY FILE ( NAME = rtcdyn_data, FILENAME = 'D:\CsData\RtcDatabaseStore\rtclocal\DynDbPath\rtcdyn.mdf' );
ALTER DATABASE rtcdyn MODIFY FILE ( NAME = rtcdyn_log, FILENAME = 'D:\CsData\RtcDatabaseStore\rtclocal\DynLogPath\rtcdyn.ldf' );
ALTER DATABASE rtc SET ONLINE ;
ALTER DATABASE rtcdyn SET ONLINE ;
Подключаемся к экземпляру RTC
ALTER DATABASE cpsdyn MODIFY FILE ( NAME = cpsdyn_data, FILENAME = 'd:\csdata\applicationstore\rtc\dbpath\cpsdyn.mdf' );
ALTER DATABASE cpsdyn MODIFY FILE ( NAME = cpsdyn_log, FILENAME = 'd:\csdata\applicationstore\rtc\logpath\cpsdyn.ldf' );
ALTER DATABASE rgsconfig MODIFY FILE ( NAME = rgsconfig_data, FILENAME = 'd:\csdata\applicationstore\rtc\dbpath\rgsconfig.mdf' );
ALTER DATABASE rgsconfig MODIFY FILE ( NAME = rgsconfig_log, FILENAME = 'd:\csdata\applicationstore\rtc\logpath\rgsconfig.ldf' );
ALTER DATABASE rgsdyn MODIFY FILE ( NAME = rgsdyn_data, FILENAME = 'd:\csdata\applicationstore\rtc\dbpath\rgsdyn.mdf' );
ALTER DATABASE rgsdyn MODIFY FILE ( NAME = rgsdyn_log, FILENAME = 'd:\csdata\applicationstore\rtc\logpath\rgsdyn.ldf' );
ALTER DATABASE rtcab MODIFY FILE ( NAME = rtcab_data, FILENAME = 'd:\csdata\absstore\rtc\dbpath\rtcab.mdf' );
ALTER DATABASE rtcab MODIFY FILE ( NAME = rtcab_log, FILENAME = 'd:\csdata\absstore\rtc\logpath\rtcab.ldf' );
ALTER DATABASE rtcshared MODIFY FILE ( NAME = rtcshared_data, FILENAME = 'D:\CsData\BackendStore\rtc\DbPath\rtcshared.mdf' );
ALTER DATABASE rtcshared MODIFY FILE ( NAME = rtcshared_log, FILENAME = 'D:\CsData\BackendStore\rtc\LogPath\rtcshared.ldf' );
ALTER DATABASE rtcxds MODIFY FILE ( NAME = rtcxds_data, FILENAME = 'D:\CsData\BackendStore\rtc\DbPath\rtcxds.mdf' );
ALTER DATABASE rtcxds MODIFY FILE ( NAME = rtcxds_log, FILENAME = 'D:\CsData\BackendStore\rtc\LogPath\rtcxds.ldf' );
ALTER DATABASE xds MODIFY FILE ( NAME = xds_data , FILENAME = 'd:\csdata\centralmgmtstore\rtc\dbpath\xds.mdf' );
ALTER DATABASE xds MODIFY FILE ( NAME = xds_log , FILENAME = 'd:\csdata\centralmgmtstore\rtc\logpath\xds.ldf' );
ALTER DATABASE lis MODIFY FILE ( NAME = lis_data , FILENAME = 'd:\csdata\centralmgmtstore\rtc\dbpath\lis.mdf' );
ALTER DATABASE lis MODIFY FILE ( NAME = lis_log , FILENAME = 'd:\csdata\centralmgmtstore\rtc\logpath\lis.ldf' );
ALTER DATABASE cpsdyn SET ONLINE ;
ALTER DATABASE rgsconfig SET ONLINE ;
ALTER DATABASE rgsdyn SET ONLINE ;
ALTER DATABASE rtcab SET ONLINE ;
ALTER DATABASE rtcshared SET ONLINE ;
ALTER DATABASE rtcxds SET ONLINE ;
ALTER DATABASE xds SET ONLINE ;
ALTER DATABASE lis SET ONLINE ;
Подключаемся к экземпляру LYNCLOCAL
ALTER DATABASE lyss MODIFY FILE ( NAME = lyss_data, FILENAME = 'D:\CsData\LyssStore\lynclocal\dbpath\lyss.mdf' );
ALTER DATABASE lyss MODIFY FILE ( NAME = lyss_log, FILENAME = 'D:\CsData\LyssStore\lynclocal\logpath\lyss.ldf' );
ALTER DATABASE lyss SET ONLINE ;
Запускаем службы Lync
Start-CsWindowsService