BACKUP AND RESTORE PROCEDURES
27-May-1999
SQL Server - One Time Backup
1. Select Windows NT SERVER version 4.00, press .
2. Press and login as SQL Service at the login screen.
3. Click , ,,.
4. Highlight server name under ,, .
5. Click , on menu bar.
6. Select database name with pull down, in database field.
7. Select radio button.
8. Enter name of file to store data, in the name field.
9. Select radio button.
10. Select radio button, click .
11. Accept default Tape0.
12. Click .
13. Click tab.
14. Check "Verify backup upon completion" box.
15. Uncheck "Check media set name…" box.
16. Click .
17. Click at back complete window.
SQL Server - Scheduled Backup
1. Select Windows NT SERVER version 4.00, press .
2. Press and login as SQL Service at the login screen.
1
BACKUP AND RESTORE PROCEDURES
3. Click , ,,.
4. Highlight server name under ,, .
5. Click , .
6. Click .
7. Select , , and under these database radio
buttons.
8. Click .
9. Check "Reorganize data and index pages" box.
10. Check the "Remove unused space from database files" box, then click .
11. Check the "Check database integrity" box.
12. Check the "Attempt to repair any minor problems" box.
13. Click .
14. Select radio button.
15. Click .
16. Check boxes.
17. Select "Occurs once at" radio button.
18. Enter 11PM in field.
19. Click .
20. Click , .
21. Check box.
22. Check box and change corresponding values to 2 weeks.
23. Click , , .
24. Click .
2
BACKUP AND RESTORE PROCEDURES
SQL Server - Restore
1. Select Windows NT SERVER version 4.00, press .
2. Press and login as SQL Service at the login screen.
3. Click , ,,.
4. Highlight server name under ,, .
5. Click , on menu bar.
6. Enter Homes in the "Restore as database" field.
7. Select radio button.
8. Click button.
9. Select radio button, then click .
10. Select Tape0, click .
11. Click .
12. Click tab.
13. Select the "Force restore over existing database".
14. Click , .
SQL Server - After Restoring Database
1. Select Windows NT SERVER version 4.00, press .
2. Press and login as SQL Service at the login screen.
3. Click , ,,.
4. Highlight server name under ,, .
5. Click sign next to server name.
3
BACKUP AND RESTORE PROCEDURES
6. Click sign next to security.
7. Right click .
8. Select .
9. Enter "Homes3 Users" in the name field.
10. Click pull down next to domain field and select the appropriate domain "HSGSill".
11. Click pull down next to domain and select Homes.
12. Click "Server Roles" tab.
13. Check the "System Administrator" box.
14. Click "Database Access" tab.
15. Check "Homes" box.
16. Check the "db_datareader" box.
17. Check the "db_datawriter" box.
18. Check "Master" box.
19. Click .
20. If error is received then continue to next step; If no error is received then skip to step 31.
21. Click to close error window.
22. Click to close “…New Login” window.
23. Click + next to server name under ,, .
24. Click + next to Databases.
25. Click + next to Database Names.
26. Click .
27. Right click sysusers in the right frame.
28. Select ,.
4
BACKUP AND RESTORE PROCEDURES
29. Select row with Homes3 Users and press .
30. Click to confirm delete.
31. Close window and start from step 1 of this section.
------------------------------------------------------------------
32. Click sign next to Databases.
33. Click sign next to Master.
34. Click on "Extended Stored Procedures".
35. Scroll down in right frame and double click on XP_CmdShell.
36. Click button.
37. Check the box under the exec column.
38. Click , .
39. Click sign next to Homes.
40. Click on .
41. Double click on in the right frame.
42. Click button.
43. Check the "Sp_assign_delete" box in the exec column and all boxes below it in the exec
column.
44. Click .
45. Select from the menu bar.
Login to the Homes Application from a Workstation
1. Enter Sill_S001 in the server name field.
2. Enter Homes in the database name field.
3. Click ,,.
5
BACKUP AND RESTORE PROCEDURES
NT - One Time Backup
1. Insert floppy disk in A drive.
2. Click , ,.
3. Type “r disk /s” at the command prompt and hit .
4. Click .
5. Remove Floppy when complete.
6. Double click server symbol in lower right hand corner near clock.
7. Click button, then , .
8. Click , , , .
9. Check the box next to the C drive.
10. Click .
11. Check the "Hardware compression" box.
12. Check the "Backup local registry" box.
13. Click .
14. Double click server symbol in lower right hand corner near the clock.
15. Click button.
6
BACKUP AND RESTORE PROCEDURES
Attaching and Detaching a Database
The SQL Database files have a file extension of *.mdf and *.ldf. These are the actual files that
hold the data.
With these database files, you create a new database with these data files and call the database
whatever you want.
1. Navigate to Query Analyzer.
2. Navigate to the server where you want the database.
3. Type in the following SQL command and run it:
sp_attach_db HomesDB,
‘D:\MSSQL7\Data\Homesdb_Data.mdf’,
‘D:\MSSQL7\Data\Homesdb_Log.ldf’
4. To Detach a database, type in the following command and run it:
sp_detach_db HomesDB
7