??? ????? ?????? SQL Server 7.0 ??? ???? ???? ?? ????? ????????? ??????????

?????? ????????? ?????? ?????????
???? ???????: 304692 - ??? ???????? ???? ????? ????? ??? ???????.
????? ???? | ?? ????

?? ??? ??????

??????

???? ??? ??????? ????? ??????? ????? ????????? ?????? ???????? ?????????? ?????? ??? ????? SQL Server 7.0 ??? ????? ??? ??????? ??? ???? ????? ????? ?? ?????? ???? ?? ????? ????????? ?????? ????????. ????? ??????? ??? ??????? ????? ???? ??? ????? ?????? ???????? ????? ????????? ?????? ???????? ?? ??????? ????? ????????. ?????? ??? ???? ?? ????????? ??? ??????? ????? ????? ???? ??? ??? ??????? ?????? ?????? ?? "????? ??????? ?? Microsoft:
224071????? ??? ????? ?????? SQL Server ??? ???? ???? ???????? "???" ? "?????" ?? SQL Server
??????: ?? ??? ????? ??? ????????? ?? ??? ??????? ??? SQL Server 2000.

?? ????? ??????? ????? ???? SQL Server 7.0 ???????? ?? ???? ? msdb ?? ??????? ?? SQL Server 2000. SQL Server 7.0 ?? ????? ?????? ?????? ??? ??????? ?? SQL Server 2000.

??????? ????

????? ??????? ?? ??? ?????? ???????? ???????:
  • ??? ????? ?????? SQL Server 7.0 ?? ?????? D:\Mssql7 ? ????? ????? ???????? ?????? ????? ???????? ?? ?????? D:\Mssql7\data ?????????.
  • ???? ????? SQL Server 7.0 ?? ?????? C:\Mssql7 ???? ??? ????? ???????? ?????? ????? ???????? ?? ?????? ????????? C:\Mssql7\data.

????????? ????????

  • ??? ???? ???????? ??????? ?? ???? ????? ???????? ?? ?????? ?????? ???? ????? ???????? ???????????? ????? ???????? ?????? msdb.
  • ??? ?? ???? ???? ???????? ????? ??????.
  • ??? ????? ?????? ???? ?? ??? ???????? ?????? ??????? ?? ???? ????? ???????? ???? ????? ???????? ???? ???? ?????????.

    ??????: ?????? ????? ?????? ???? ??????? ???? ???? ????????? ?? ?????? ????? ????????? ???? ???????? ?????? ????? ?????? ?? ????? "???? ???????" ??? mydbdata.bak ?? ??? ????? ???? ????? ??? ????? ????????? ?????? ????????:
    RESTORE FILELISTONLY FROM DISK='d:\mssql7\backup\mydbdata.bak'
    go
    					
  • ??? ????? SQL Server 7.0 ?????? ??????? ????? ??????? ???? ?????? ????.
??? ?????? ????? ????? ??????? ?? ???? ?????? ??? ????? ?????? ???? ??? ?????? ?? ??? ?? ????? ?? ??? ????? SQL Server ???? "??? ????? SQL Server ? SQL Server 7.0 ????????" ?????? ??? ?????? ??? ??????? ???? ???????.

???????? ????? ????????

  1. ??????? ????? ???????? ????????.

    ?? ?????? ??????? ????? ????? ???????? ???????? ??? ??? ??? ???? Mastlog.ldf ?? ????? ?????? ????? ??? ????? ????????? ? Master_db.bak ? Master.mdf ?? ??? ?????? ????.
    1. ?? ?????? ????? ?????? ?? ???? ????? ???? ????? SQL Server:
      d:\mssql7\binn\sqlservr -c -m

      ??????: -m ????? ??? ????? SQL Server ?? ??? ???????? ??????. ?? ??? ???????? ?????? ????? ????? ????? ???? ?? ????? ????. ?????? ?? ?????? ??? ??? ?? ????? ???? ?? ??????? ???? ?? ???? ??????? ???? ??? ??????? ?? ???? ??????? ???? SQL.
    2. ???? ??????? SQL Server ? ?????? ???? ?????? ?????? ??? ??????? ???? ???????? ?? ????? ???????? ????????:
      RESTORE DATABASE master FROM disk='d:\mssql7\backup\master_db.bak'
      WITH MOVE 'master' to 'd:\mssql7\data\master.mdf',
      MOVE 'mastlog' to 'd:\mssql7\data\mastlog.ldf',
      REPLACE
      go
      ??????: SQL Server ????? ???????? ??? ??????? ????? ???????? ????????.
    3. ?? ?????? ????? ?????? ?? ???? ????? ???? ????? SQL Server:
      d:\mssql7\binn\sqlservr -c -f -T3608 -T4022
      ??????: ??? ???????? ???? ?????? ??????, ????? ????? ??????? ?????? ??????.
    4. ?? ???? ??????? SQL Server ? ????? ???????? ??????? ?? ??????:

      ?????: ????? ????? ?????? ???? ??? ???? ??? ????? ?? ???? ?????? ????? ???? ????? ????? SQL Server. ??? ???? Microsoft ?? ????? ?? ?? ??????? ??????? ?? ????? ??? ???? ????? ??????. ????? ????? ?????? ??? ???????? ??????.
      USE master
      go
      UPDATE sysdatabases SET filename='d:\mssql7\data\tempdb.mdf' WHERE name='tempdb'
      go
      ALTER DATABASE tempdb MODIFY FILE (name = tempdev, filename = 'd:\mssql7\data\tempdb.mdf')
      ALTER DATABASE tempdb MODIFY FILE (name = templog, filename = 'd:\mssql7\data\templog.ldf')
      go
      ??? ?? ????? ??????? ??????? ?????? ???????:
      ????? 'tempdev' ????? ?? sysaltfiles. ?? ???? ????? ?????? ??? ????? ????? SQL Server.

      ????? 'templog' ????? ?? sysaltfiles. ?? ???? ????? ?????? ??? ????? ????? SQL Server.
  2. ??????? ????? ?????? ?????.

    ?? ?????? ??????? ????? ????? ???????? ???? ??? ??? ?????? ???? Model.mdf ? ??? ??? ???? Modellog.ldf ?? ????? ?????? ????? ??? ????? ????????? ? Model_db.bak. ??? ?? ??? ???? ???? ???????? ?? ????? ???????? ???? ?? ??? ??? ???? ??????? ???? ??? ?????? ????????? ????? ????? SQL Server ???? remap ???? ????? ????????. ???? ??? ??????? ??? ??????? ?????? ?? northwind ?????? pubs (????????) ?? ?????? 4.
    1. ?? ???? ??????? SQL Server ? ????? ??????? ?????? ??????? ???? ????? ???????? ?????? ?????? ?? SQL Server:
      exec sp_detach_db N'model'
      go
      ??? ????? ??????? ?????? ? ????? ??????? ???????:
      ????? ??? ????? ???????? '?????'
      ????? ??????? DBCC. ????? DBCC ????? ?????, ???? ?????? ??????
      ??????: ??? ??? ????? ???????? ???? ???? ?? ????? ??????? ?????? ??? ???? ???????? ????? RESTORE. ??? ???? ????? ????? ?????? ?????? ?????? ???????? ??? ?????? ??? ??????? ????? ????????. ???????? ??? ???? ?? ????? ????? ????? ???????? ?? ??? ????? ????????? ??????.
    2. ???? ??????? SQL Server ? ?????? ???? ?????? ?????? ??? ??????? ???? ???????? ?? ????? ???????? ??????:
      RESTORE DATABASE model FROM disk='d:\mssql7\backup\model_db.bak'
      WITH MOVE 'modeldev' TO 'd:\mssql7\data\model.mdf',
           MOVE 'modellog' TO 'd:\mssql7\data\modellog.ldf',
           REPLACE
      go
      ?????? ??????? ?? SQL Server ??? ??? ??? ??????? ????? ?????? ?????.
  3. ??????? ????? ?????? msdb.

    ?? ?????? ??????? ????? ????? ???????? msdb ??? ??? ??? ???? Msdblog.ldf ?? ????? ?????? ????? ??? ????? ????????? ? Msdb_db.bak ? Msdbdata.mdf ?? ??? ?????? ????.
    1. ?? ?????? ????? ?????? ?? ???? ????? ???? ????? SQL Server:
      d:\mssql7\binn\sqlservr -c -f -T3608 -T4022
    2. ?? ???? ??????? SQL Server ? ????? ??????? ?????? ??????? ???? ????? ???????? msdb:
      exec sp_detach_db N'msdb'
      go
    3. ???? ??????? SQL Server ? ?????? ???? ?????? ?????? ??? ??????? ???? ???????? ?? ????? ???????? msdb:
      RESTORE DATABASE msdb FROM disk='d:\mssql7\backup\msdb_db.bak'
      WITH MOVE 'msdbdata' TO 'd:\mssql7\data\msdbdata.mdf',
           MOVE 'msdblog' TO 'd:\mssql7\data\msdblog.ldf',
           REPLACE
      go
      ?????? ??????? ?? SQL Server ??? ??? ??? ??????? ????? ?????? msdb.
  4. ????? northwindpubs (????????):

    ??? ??????? ????? ???????? ???????? "?" ???? "??????" ??? ????? ??????? northwind ?????? pubs (????????) "?" ????? ?????? ????? ??? ???? ????? ???????? ???? ???? ?? ??? ????? ???. ??? ??? ???? ?? ????? ??????? ????? ????? ???????? ??????? ?? re-attach ??? ?????? ????? ??????? ?????? ??????. ????? ??? ??? ???? ?? ??????? ???? ?? ???? ???????? ??????? ?????? ????? ?????? mydb ?????? ?? ?????? 6. ??????? ?????? ?????? ?????? ????? ?????? ?????? ?????? ?????? northwind. ????? ????? ?????? northwind ??? ?????? ???? Northwind.mdf ??? ??? ???? Northwind.ldf.
    1. ?? ?????? ????? ?????? ?? ???? ????? ???? ????? SQL Server:
      d:\mssql7\binn\sqlservr -c -f -T3608 -T4022
    2. ?? ???? ??????? SQL Server ? ????? ??????? ?????? ??????? ???? ????? ???????? northwind:
      exec sp_detach_db N'northwind'
      go

      ??????: ?? ???? ??????? ??????? ???? ???? ??? ??? ???? ?? ???? ?????? ??? ??????? ???????:
      ????: ????? 947 ? ??????? 16 1 ???? ???? 1 ??? ????? ????? ????? ???????? 'Northwind' ?????.
      ????? ??? ????? ???????? 'northwind'.
      ????? ??????? DBCC. ????? DBCC ????? ?????, ???? ?????? ??????.
    3. ???? ??????? SQL Server ? ?????? ???? ?????? ?????? ?????? ????? ???????? northwind:
      exec sp_attach_db N'northwind', N'd:\mssql7\data\northwnd.mdf', N'd:\mssql7\data\northwnd.ldf'
      go
  5. remap ????? ?????? pubs (????????).

    ????? ????? ?????? pubs (????????) ??? ?????? ???? Pubs.mdf ??? ??? ???? Pubs_log.ldf. ???? remap ????? ?????? pubs (????????) ???? ??????? ????? ????? ????? ???????? northwind.
  6. ??????? ????? ?????? mydb.

    ????? ????? ?????? mydb ??? ?????? ???? Mydbdata.mdf ??? ??? ???? Mydblog.ldf ?? ????? ?????? ????? ??? ????? ????????? ? Mydb_db.bak.
    1. ?? ???? ??????? SQL Server ? ????? ??????? ?????? ??????? ???? ????? ???????? mydb:
      exec sp_detach_db N'mydb'
      go
    2. ???? ??????? SQL Server ? ?????? ???? ?????? ?????? ??? ??????? ???? ???????? ?? ????? ???????? mydb:
      RESTORE DATABASE mydb FROM disk='d:\mssql7\backup\mydb_db.bak'
      WITH MOVE 'mydbdata' TO 'd:\mssql7\data\mydbdata.mdf',
           MOVE 'mydblog' TO 'd:\mssql7\data\mydblog.ldf',
           REPLACE
      go
  7. ????? ????? ???? SQL.

    ???: ??? ??? ??? ??????? ??? ??? ??? ???? ?????? ??? ????? SQL Server ???? ??? ???? ???????? ????? ???????? ????????.

    ??? ???? ??????? ????? ????? SQL Server ???:

    • ??????? ????? ????????? ?????? ???????? ?? ??????? ?????? SOURCESVR ??? ??????? ?????? TARGETSVR.
    • ??? ????????? ?????? TARGETSVR ???? SQL ????? ???? SOURCESVR.
    ??? ??? ????? ??? ????? ????? ???? SQL ??????? ???? ???? ???? ??????? ??? ???? SQL ???? ?????????:
    exec sp_dropserver 'SOURCESVR'
    go
    exec sp_addserver 'TARGETSVR', 'LOCAL'
    go
  8. ????? ????? ???? SQL Server.

?????

????? ?? ?????????? ???? ??? ??? ??????? ?????? ?????? ?? "????? ??????? ?? Microsoft:
224071????? ??? ????? ?????? SQL Server ??? ???? ???? ???????? "???" ? "?????" ?? SQL Server
314546????? ??? ????? ???????? ??? ????? ????????? ???? ???? ????? ??????? SQL Server
??????: ?????? ??? ??????? ?????? ??? ?????? ??? ??????? ?????? ??? - C ? -m ? ? -f ? ?????? ?????? ??? "??? SQL Server ???????".

???????

???? ???????: 304692 - ????? ??? ??????: 24/???? ??????/1427 - ??????: 3.3
????? ???
  • Microsoft SQL Server 7.0 Standard Edition
????? ??????: 
kbmt kbinfo KB304692 KbMtar
????? ????
???: ??? ????? ??? ?????? ???????? ?????? ????? ???? ????? ?????????? ????? ?? ????????? ?????? ????. ???? ???? ?????????? ???? ?? ???????? ???????? ?????? ????????? ????? ????????? ???????? ????? ???????? ?????? ?? ?????? ??? ?? ???????? ???????? ?? ????? ??????? ?????? ??? ??????? ?????? ??. ?????? ?? ???? ??? ??????? ???????? ????? ?? ???? ????? ?????? ??? ????? ??? ????? ??????? ?? ????? ?? ?????? ??? ??? ??????? ??????? ?? ????? ????? ????? ????? ?????. ?? ????? ???? ?????????? ??????? ??? ????? ?? ??????? ?? ????? ?????? ?? ??? ????? ?? ????? ??????? ?? ???????? ?? ??? ???????. ???? ???? ?????????? ???????? ??? ????? ?????? ??????? ??????
???? ??? ????? ??????? ?????? ??????????304692

????? ???????

 

Contact us for more help

Contact us for more help
Connect with Answer Desk for expert help.
Get more support from smallbusiness.support.microsoft.com