Showing posts with label drives. Show all posts
Showing posts with label drives. Show all posts

Monday, March 26, 2012

Restore to Multiple Files?

I am in the process of configuring a new laptop. It has two hard drives and
I want to restore several of my large databases to files on both hard
drives, even though the original dbs on my old laptop are single-file.
Anyone know a secret that will allow you to restore a single-file database
to spread it's data over two files during the restore'
--
TheSQLGuru
President
Indicium Resources, Inc.Hi
I'm affraid you cannot do that. As SQL Server needs to restore/attach the
same number of files as you created db.
"TheSQLGuru" <kgboles@.earthlink.net> wrote in message
news:%23mNKpyH9HHA.4180@.TK2MSFTNGP05.phx.gbl...
>I am in the process of configuring a new laptop. It has two hard drives
>and I want to restore several of my large databases to files on both hard
>drives, even though the original dbs on my old laptop are single-file.
>Anyone know a secret that will allow you to restore a single-file database
>to spread it's data over two files during the restore'
> --
> TheSQLGuru
> President
> Indicium Resources, Inc.
>
>|||I didn't think it could be done either, but I have found quite a number of
things that fall into that category on this forum so I thought I would ask
anyway!! :-)
--
TheSQLGuru
President
Indicium Resources, Inc.
"Uri Dimant" <urid@.iscar.co.il> wrote in message
news:uqQ5U8H9HHA.1484@.TK2MSFTNGP06.phx.gbl...
> Hi
> I'm affraid you cannot do that. As SQL Server needs to restore/attach the
> same number of files as you created db.
> "TheSQLGuru" <kgboles@.earthlink.net> wrote in message
> news:%23mNKpyH9HHA.4180@.TK2MSFTNGP05.phx.gbl...
>>I am in the process of configuring a new laptop. It has two hard drives
>>and I want to restore several of my large databases to files on both hard
>>drives, even though the original dbs on my old laptop are single-file.
>>Anyone know a secret that will allow you to restore a single-file database
>>to spread it's data over two files during the restore'
>> --
>> TheSQLGuru
>> President
>> Indicium Resources, Inc.
>>
>|||You are probably better off placing the log files on one drive and the data
on the other.
--
Andrew J. Kelly SQL MVP
Solid Quality Mentors
"TheSQLGuru" <kgboles@.earthlink.net> wrote in message
news:%23mNKpyH9HHA.4180@.TK2MSFTNGP05.phx.gbl...
>I am in the process of configuring a new laptop. It has two hard drives
>and I want to restore several of my large databases to files on both hard
>drives, even though the original dbs on my old laptop are single-file.
>Anyone know a secret that will allow you to restore a single-file database
>to spread it's data over two files during the restore'
> --
> TheSQLGuru
> President
> Indicium Resources, Inc.
>
>|||That will be done for my 'standard' databases. I have a few very large ones
I use for analyzing trace files and also one large test db for a client and
for those the read-throughput is key to optimal perforance thus the desire
to spread the data across both drives.
--
TheSQLGuru
President
Indicium Resources, Inc.
"Andrew J. Kelly" <sqlmvpnooospam@.shadhawk.com> wrote in message
news:uTTCReJ9HHA.5456@.TK2MSFTNGP05.phx.gbl...
> You are probably better off placing the log files on one drive and the
> data on the other.
> --
> Andrew J. Kelly SQL MVP
> Solid Quality Mentors
>
> "TheSQLGuru" <kgboles@.earthlink.net> wrote in message
> news:%23mNKpyH9HHA.4180@.TK2MSFTNGP05.phx.gbl...
>>I am in the process of configuring a new laptop. It has two hard drives
>>and I want to restore several of my large databases to files on both hard
>>drives, even though the original dbs on my old laptop are single-file.
>>Anyone know a secret that will allow you to restore a single-file database
>>to spread it's data over two files during the restore'
>> --
>> TheSQLGuru
>> President
>> Indicium Resources, Inc.
>>
>sql

Wednesday, March 7, 2012

Restore MSSQL Database, lost LDF-File

Hi.
I've following problem:
- Customer played with his logical drives in a CPQ smart array
- He played too much: he lost the drive with the LDF-File
- Now the SQL-Server is in a kind of wired mode; you can
start and stop it, but you cannot connect to (neiter 'sa' nor
any other user available before)
In fact the mode is not wired: what shall he do other when
most important file is missing... :o
- The problem for me now is:

> How can I get the Enterprise Manager or Query Analyzer
up and running again to start a restore?

PS: The restore is to be done from a tape-library running
Veritas Backup Exec + SQL-Agent

PPS: Error-log says (what I already know):
2005-10-04 17:18:02.69 spid11 Device activation error. The physical file name 'H:\DEVLOG1\DEVLOG1.ldf' may be incorrect.

Thanks in advance for assistance.

Regards,
Carsten Loefflerdid you try to connect with osql?|||Sounds like someone played with the default database of sa and BUILTIN\ADMINISTRATORS. That's bad. You can see if any of the local administrators can connect to the SQL Server with WndowsNT authentication, but it sounds like you have already tried that.|||If nobody can connect to SQL Server, maybe you want to run rebuildm, then restore the last good master database and other databases as needed.|||Hi Everyone,
thanks for the assistance.

Brett:
No, I didnt try it with OSQL. But thats a good idea. Any hints so far
before I go and investigate myself too much??

MCrowley:
Yip. You're right and I didnt mention it. Yes - I tried it with "sa" and
I tried it with all the others I knew that they were there.
The thing that confuses me: master-DB is still there and running
and didnt get touched...

Tomh:
Mmmh. Do you think I have to do it anyway. I think that master-DB
is up and running.

Regards,
Carsten Loeffler|||The thing that confuses me: master-DB is still there and running
and didnt get touched...

When you log into SQL Server, you always go to your default database first thing. If it is not there, then you get the error "Can not open default database". Has the same thing happened to BUITLIN\ADMINISTRATORS, or can a local Windows admin log in with Windows Authentication?|||Hi.
I've following problem:
<snip>
- Now the SQL-Server is in a kind of wired mode; you can
start and stop it, but you cannot connect to (neiter 'sa' nor
any other user available before)
</snip>

Since we know MCrowley is right, and if the statement above is true, then **all** users were defaulted to the database where the ldf is missing.

If I'm reading the quoted part right, not a single user can log in. If that is the case, then master will have to be restored. And since you have to be able to log in to rebuild master, rebuildm will be needed to get back to a place where a system admin can login. So maybe rebuildm, restore database where .ldf is missing, them restore master.|||And ->immediately<- reset sa's default database back to master. As well as BUILTIN\ADMINISTRATORS.|||And ->immediately<- reset sa's default database back to master. As well as BUILTIN\ADMINISTRATORS.
I am gonna bet all the whisky lying in my almirah it will be possible to login using BUILTIN\ADMINISTRATORS. It just seems that the guy is not aware of the account.

Suggestion : Try logging in with the radio button set to Windows Authentictation while you are logged in with a Windows System Administrator account ...