Friday, March 30, 2012
Restore Deleted Instance of SQL 2000
great.
We decided to upgrade to SQL 2005. We ran the upgrade on the default
instance. Everything was great.
Before we upgraded the second instance, someone went into 'add remove
programs' and removed the second instance of SQL 2000. Can I get it
back?
I created a second instance in SQL 2005 and attached the single
important DB from that second instance of SQL 2000 and the data is all
there, but we are having connection issues. I'm afraid it may be
because we deleted the second instance of SQL 2000 before we got a
chance to upgrade.
Any ideas?
-BDOn Nov 2, 3:16 am, i...@.clowwater.com wrote:
> We had a server with SQL 2000 on it. It had two instances. Worked
> great.
> We decided to upgrade to SQL 2005. We ran the upgrade on the default
> instance. Everything was great.
> Before we upgraded the second instance, someone went into 'add remove
> programs' and removed the second instance of SQL 2000. Can I get it
> back?
> I created a second instance in SQL 2005 and attached the single
> important DB from that second instance of SQL 2000 and the data is all
> there, but we are having connection issues. I'm afraid it may be
> because we deleted the second instance of SQL 2000 before we got a
> chance to upgrade.
> Any ideas?
> -BD
I don't think that this has something to do with the fact that the
second instance was deleted. Can you post more details? What is the
error that you get? Do you get it each time that you try to connect
to the server? Do you also get it if you try to connect to the SQL
Server from the server it self?
Adi
Monday, March 26, 2012
RESTORE DATABASE question
I ran the script bellow, then the statsales datbase log and data
"logical" file names changed to those of the database
'statsales_staging_victory_full' which I restored from as shown in the
script bellow.
The questions are:
Do I have one chared log file now, for both statsales and
statsales_staging ?
Will this hurt or confuse anything on the server?
How can I change those names back to there original names?
Thanks for any help.
mFH
================================================================== USE master
RESTORE DATABASE statsales
FROM DISK = 'E:\backup\statsales_staging_victory_full'
WITH REPLACE ,
MOVE 'statsales_staging_dat' TO 'G:\statsales\statsales_Data.MDF',
MOVE 'statsales_staging_log' TO 'D:\statsales_Log\statsales.LDF'
GO
==================================================================They don't share a log. I think you are ok. The boundry on the logical
name for database devices (bad memories) is the database.
Christian Smith
"shaab mohagir" <shaab.mohagir@.bonbon.net> wrote in message
news:e1b3da1b.0402121213.3b0d353d@.posting.google.com...
> Hello,
> I ran the script bellow, then the statsales datbase log and data
> "logical" file names changed to those of the database
> 'statsales_staging_victory_full' which I restored from as shown in the
> script bellow.
> The questions are:
> Do I have one chared log file now, for both statsales and
> statsales_staging ?
> Will this hurt or confuse anything on the server?
> How can I change those names back to there original names?
> Thanks for any help.
> mFH
> ==================================================================> USE master
> RESTORE DATABASE statsales
> FROM DISK = 'E:\backup\statsales_staging_victory_full'
> WITH REPLACE ,
> MOVE 'statsales_staging_dat' TO 'G:\statsales\statsales_Data.MDF',
> MOVE 'statsales_staging_log' TO 'D:\statsales_Log\statsales.LDF'
> GO
> ==================================================================|||Correct, Christian.
It might also be worth mentioning that in SQL2K, you can rename the logical
filename using ALTER DATABASE.
--
Tibor Karaszi, SQL Server MVP
Archive at:
http://groups.google.com/groups?oi=djq&as_ugroup=microsoft.public.sqlserver
"Christian Smith" <csmith@.digex.com> wrote in message
news:u9Govfa8DHA.2168@.TK2MSFTNGP12.phx.gbl...
> They don't share a log. I think you are ok. The boundry on the logical
> name for database devices (bad memories) is the database.
> Christian Smith
> "shaab mohagir" <shaab.mohagir@.bonbon.net> wrote in message
> news:e1b3da1b.0402121213.3b0d353d@.posting.google.com...
> > Hello,
> >
> > I ran the script bellow, then the statsales datbase log and data
> > "logical" file names changed to those of the database
> > 'statsales_staging_victory_full' which I restored from as shown in the
> > script bellow.
> >
> > The questions are:
> >
> > Do I have one chared log file now, for both statsales and
> > statsales_staging ?
> > Will this hurt or confuse anything on the server?
> > How can I change those names back to there original names?
> >
> > Thanks for any help.
> >
> > mFH
> >
> > ==================================================================> > USE master
> > RESTORE DATABASE statsales
> > FROM DISK = 'E:\backup\statsales_staging_victory_full'
> > WITH REPLACE ,
> > MOVE 'statsales_staging_dat' TO 'G:\statsales\statsales_Data.MDF',
> > MOVE 'statsales_staging_log' TO 'D:\statsales_Log\statsales.LDF'
> >
> > GO
> > ==================================================================>|||Thanks Christian and Thanks Tibor...
I'll see how can I change the log names using ALTER DATABASE, I hope
it's something I can do.
Thanks again.
mfharraz
"Tibor Karaszi" <tibor_please.no.email_karaszi@.hotmail.nomail.com> wrote in message news:<eQvgLra8DHA.1428@.TK2MSFTNGP12.phx.gbl>...
> Correct, Christian.
> It might also be worth mentioning that in SQL2K, you can rename the logical
> filename using ALTER DATABASE.
> --
> Tibor Karaszi, SQL Server MVP
> Archive at:
> http://groups.google.com/groups?oi=djq&as_ugroup=microsoft.public.sqlserver
>
> "Christian Smith" <csmith@.digex.com> wrote in message
> news:u9Govfa8DHA.2168@.TK2MSFTNGP12.phx.gbl...
> > They don't share a log. I think you are ok. The boundry on the logical
> > name for database devices (bad memories) is the database.
> >
> > Christian Smith
> >
> > "shaab mohagir" <shaab.mohagir@.bonbon.net> wrote in message
> > news:e1b3da1b.0402121213.3b0d353d@.posting.google.com...
> > > Hello,
> > >
> > > I ran the script bellow, then the statsales datbase log and data
> > > "logical" file names changed to those of the database
> > > 'statsales_staging_victory_full' which I restored from as shown in the
> > > script bellow.
> > >
> > > The questions are:
> > >
> > > Do I have one chared log file now, for both statsales and
> > > statsales_staging ?
> > > Will this hurt or confuse anything on the server?
> > > How can I change those names back to there original names?
> > >
> > > Thanks for any help.
> > >
> > > mFH
> > >
> > > ==================================================================> > > USE master
> > > RESTORE DATABASE statsales
> > > FROM DISK = 'E:\backup\statsales_staging_victory_full'
> > > WITH REPLACE ,
> > > MOVE 'statsales_staging_dat' TO 'G:\statsales\statsales_Data.MDF',
> > > MOVE 'statsales_staging_log' TO 'D:\statsales_Log\statsales.LDF'
> > >
> > > GO
> > > ==================================================================> >
> >
RESTORE DATABASE question
I ran the script bellow, then the statsales datbase log and data
"logical" file names changed to those of the database
'statsales_staging_victory_full' which I restored from as shown in the
script bellow.
The questions are:
Do I have one chared log file now, for both statsales and
statsales_staging ?
Will this hurt or confuse anything on the server?
How can I change those names back to there original names?
Thanks for any help.
mFH
========================================
==========================
USE master
RESTORE DATABASE statsales
FROM DISK = 'E:\backup\statsales_staging_victory_ful
l'
WITH REPLACE ,
MOVE 'statsales_staging_dat' TO 'G:\statsales\statsales_Data.MDF',
MOVE 'statsales_staging_log' TO 'D:\statsales_Log\statsales.LDF'
GO
========================================
==========================They don't share a log. I think you are ok. The boundry on the logical
name for database devices (bad memories) is the database.
Christian Smith
"shaab mohagir" <shaab.mohagir@.bonbon.net> wrote in message
news:e1b3da1b.0402121213.3b0d353d@.posting.google.com...
> Hello,
> I ran the script bellow, then the statsales datbase log and data
> "logical" file names changed to those of the database
> 'statsales_staging_victory_full' which I restored from as shown in the
> script bellow.
> The questions are:
> Do I have one chared log file now, for both statsales and
> statsales_staging ?
> Will this hurt or confuse anything on the server?
> How can I change those names back to there original names?
> Thanks for any help.
> mFH
> ========================================
==========================
> USE master
> RESTORE DATABASE statsales
> FROM DISK = 'E:\backup\statsales_staging_victory_ful
l'
> WITH REPLACE ,
> MOVE 'statsales_staging_dat' TO 'G:\statsales\statsales_Data.MDF',
> MOVE 'statsales_staging_log' TO 'D:\statsales_Log\statsales.LDF'
> GO
> ========================================
==========================|||Correct, Christian.
It might also be worth mentioning that in SQL2K, you can rename the logical
filename using ALTER DATABASE.
Tibor Karaszi, SQL Server MVP
Archive at:
http://groups.google.com/groups?oi=...ublic.sqlserver
"Christian Smith" <csmith@.digex.com> wrote in message
news:u9Govfa8DHA.2168@.TK2MSFTNGP12.phx.gbl...
> They don't share a log. I think you are ok. The boundry on the logical
> name for database devices (bad memories) is the database.
> Christian Smith
> "shaab mohagir" <shaab.mohagir@.bonbon.net> wrote in message
> news:e1b3da1b.0402121213.3b0d353d@.posting.google.com...
>|||Thanks Christian and Thanks Tibor...
I'll see how can I change the log names using ALTER DATABASE, I hope
it's something I can do.
Thanks again.
mfharraz
"Tibor Karaszi" <tibor_please.no.email_karaszi@.hotmail.nomail.com> wrote in message news
:<eQvgLra8DHA.1428@.TK2MSFTNGP12.phx.gbl>...
> Correct, Christian.
> It might also be worth mentioning that in SQL2K, you can rename the logica
l
> filename using ALTER DATABASE.
> --
> Tibor Karaszi, SQL Server MVP
> Archive at:
> [url]http://groups.google.com/groups?oi=djq&as_ugroup=microsoft.public.sqlserver[/url
]
>
> "Christian Smith" <csmith@.digex.com> wrote in message
> news:u9Govfa8DHA.2168@.TK2MSFTNGP12.phx.gbl...
Wednesday, March 21, 2012
Restore database April CTP 2005 Failed?
studio I think) and I scripted it out and ran it in a query window to
get more info. This works fine in SQL 2000 but not in 2005. I also tried
to 'create' the database first then ran this command below but with the
'force restore over existing database' checked on but this failed also
which is odd as well. Any ideas. This is my very first play with 2005 so
it is not off to a great start although to be fair, i seem to have gor
lucky on the install as it all went OK. BTW, is there a more approriate
newsgroup for this query?
Thanks
RESTORE DATABASE [bob] FROM DISK = N'C:\BigFujiCopies\Bob.bak' WITH
FILE = 1,
MOVE N'bob_Data' TO N'c:\Program Files\Microsoft SQL
Server\MSSQL\Data\bob_Data.MDF',
MOVE N'bob_Log' TO N'c:\Program Files\Microsoft SQL
Server\MSSQL\Data\bob_Log.LDF',
NOUNLOAD, STATS = 10
GO
Msg 5122, Level 16, State 1, Line 1
Directory lookup for the file "c:\Program Files\Microsoft SQL
Server\MSSQL\Data\bob_Data.MDF"
failed with the operating system error 3(error not found).
Msg 3156, Level 16, State 3, Line 1
File 'bob_Data' cannot be restored to 'c:\Program Files\Microsoft SQL
Server\MSSQL\Data\bob_Data.MDF'.
Use WITH MOVE to identify a valid location for the file.
Msg 5122, Level 16, State 1, Line 1
Directory lookup for the file "c:\Program Files\Microsoft SQL
Server\MSSQL\Data\bob_Log.LDF" failed with the operating system error
3(error not found).
Msg 3156, Level 16, State 3, Line 1
File 'bob_Log' cannot be restored to 'c:\Program Files\Microsoft SQL
Server\MSSQL\Data\bob_Log.LDF'. Use WITH MOVE to identify a valid
location for the file.
Msg 3119, Level 16, State 1, Line 1
Problems were identified while planning for the RESTORE statement.
Previous messages provide details.
Msg 3013, Level 16, State 1, Line 1
RESTORE DATABASE is terminating abnormally.
*** Sent via Developersdex http://www.developersdex.com ***Dearie me, if i would just take a closer look at what was stating me in
the face, i might just save myself countless wasted hours and an eggy
coupon. Suffice as to say the error is pretty much right as a database
cannot be restored/created to that location because of a complete lack
of a directory!! The directory structure in 2005 is a litlle differet as
MSSQL now appears under MSSQL.1, so ,he says (hanging head) it should be
'c:\Program Files\Microsoft SQL
Server\MSSQL.1\MSSQL\Data\bob_Data.MDF'.
and NOT
'c:\Program Files\Microsoft SQL
Server\MSSQL\Data\bob_Data.MDF'.
Worth making a not of (although is there not a case for the restore
command to simply create the directory structure you wish to restore to
on the hoof which would save people having to come of management studio,
make the directory tree up for cases where they want to store data and
log files in odd places?)
*** Sent via Developersdex http://www.developersdex.com ***|||DMAC@.devdex.com (DMAC@.devdex.com) writes:
> Worth making a not of (although is there not a case for the restore
> command to simply create the directory structure you wish to restore to
> on the hoof which would save people having to come of management studio,
> make the directory tree up for cases where they want to store data and
> log files in odd places?)
Maybe there is, but the newsgroup to post this to is really
microsoft.private.sqlserver2005.tools.graphical. See
http://go.microsoft.com/fwlink/?linkid=31765 for access information.
--
Erland Sommarskog, SQL Server MVP, esquel@.sommarskog.se
Books Online for SQL Server SP3 at
http://www.microsoft.com/sql/techin.../2000/books.asp