Monday, March 19, 2012

Crashed C drive, but DB on D drive

SQL 7.0
The C drive crashed, but the DB was safe(?) on drive D.
When a new drive C is installed is there any way to
retore or whatever the database?
Thanks,
DonDon wrote:

> SQL 7.0
> The C drive crashed, but the DB was safe(?) on drive D.
> When a new drive C is installed is there any way to
> retore or whatever the database?
You should be able to attach the databases after you install SQL.
Typically in this scenario if you were using SQL Logins and you don't
have them anymore, you probably lost the passwords. There are ways to
restore the master database which stores these passwords, however I have
never had much success with such a thing and is usually not necessary.
Attaching a database can be done through Enterprise Manager by right
clicking on the databases folder.
Aaron Weiker
http://blogs.sqladvice.com/aweiker
http://aaronweiker.com/|||Hi,
Step -1
Can you tell the location of system databases (Master,model,msdb,tempdb) MDF
and LDF locations. If it is in D drive you can easily make the
SQL server up with all the configurations and data same as old.
1. Install SQL server with same directory structure as old
2. Apply the service pack as old
3. Stop sql server
4. Copy all the MDF and LDF files to the same directory stucture as before
(Ensure that u keep the original some where safe)
5. Start SQL Server
Normally this will enable to have all the databases and Logins same as old.
Step 2
Incase if your system MDF and LDF were lost then, (the below steps will work
if you have MASTER database backup (master.bak))
1. Install SQL server with same directory structure as old
2. Apply service packs
3. Start SQL server in sigle user mode (-m)
4. Restore the master database
5. Restore MSDB database
6. Stop SQL server and copy the MDF and LDF to the directories as old
7. Start SQL server
Step 3
Incase if you dont have the MASTER database backup. Now all depends on luck.
SOme times your ATTACH may not work since you have not
detached the database using SP_DETACH_DB. If attach gives you issue then
probably you have restore the databases from Backup you have
and then create the logins manually and assign permissions.
Thanks
Hari
MCDBA
"Don" <anonymous@.discussions.microsoft.com> wrote in message
news:9d1701c4063f$47542660$a001280a@.phx.gbl...
> SQL 7.0
> The C drive crashed, but the DB was safe(?) on drive D.
> When a new drive C is installed is there any way to
> retore or whatever the database?
> Thanks,
> Don
>

No comments:

Post a Comment