Showing posts with label master. Show all posts
Showing posts with label master. Show all posts

Friday, March 30, 2012

Restrict delete from a table

Hi

I need to restrict delete from one table by any user of SQL. How can we do this? This is our master table and we dont want any one to delete data from this table.

Thanks
BalaTry Cascade ON DELETE NO ACTION, you can use either code or set it on the table properties. Run a search for Cascade Delete in the BOL(books online) for more examples. NO ACTION is an ANSI SQL DRI(Declarative Referential Integrity) rule that prevents Deletes from tables. Hope this helps

CREATE TABLE order_part
(order_nmbr int,
part_nmbr int
FOREIGN KEY REFERENCES part_sample(part_nmbr)
ON DELETE NO ACTION,
qty_ordered int)
GO

Kind regards,
Gift Peddie

Monday, March 26, 2012

Restoring the replication environment

Is it possible to restoring the master db ? This is to
restore the merge agents settings, without creating the
merge agents again? If any one got an answer for this
please reply asap.
Binoy,
replication agents and the master database are two separate issues. In
master there is sysservers and sysxlogins, both of which are relevant to the
replication setup. However, you are concerned about the merge agent jobs and
parameters which are in msdb (sysjobs, MSagent_profiles, MSagent_parameters
etc). For a good set of details on the replication backup strategy, you can
have a look in BOL for 'replication, backup and restore
operations,Strategies for Backing Up and Restoring Merge Replication'.
HTH,
Paul Ibison

Restoring the master to different drive letters

Can you restore the master database, running on windows server 2000, sql
server 2000 from a backup that was taken from c:\ to another server
restoring to d:\?

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!Hi

See:
http://support.microsoft.com/defaul...ben-us%3b224071

John

"spec_server" <spec_9@.nwy.com> wrote in message
news:415c6810$0$26132$c397aba@.news.newsgroups.ws.. .
> Can you restore the master database, running on windows server 2000, sql
> server 2000 from a backup that was taken from c:\ to another server
> restoring to d:\?
>
> *** Sent via Developersdex http://www.developersdex.com ***
> Don't just participate in USENET...get rewarded for it!

restoring the master database

I read earlier posts about restoring the master database.
I am testing for failover, and I found that after I had restored the master
database to the failover server, the SQL Server service stopped immediately
after starting.
The databases on the production server are on a drive which doesn't exist on
the failover server. Is it necessary to configure the servers identically?
I think perhaps SQL Server service can't start because it can't locate the
model database to create the tempdb, or because the path the tempdb doesn't
exist.
I can't get it started even with sqlservr.exe -f, in order to Alter Database
and change the location of the databases.
The Event log had errors (17052, 17204) because the path in sysdatabases
points to a non-existent location.
I am running SQL Server 2000 Standard edition.
Thanks
BillHere is a nice article on moving db locations:
http://support.microsoft.com/defaul...b;en-us;224071.
Check the master db first.
Dejan Sarka, SQL Server MVP
Associate Mentor
www.SolidQualityLearning.com
"bill" <belgie@.datamti.com> wrote in message
news:%237QDmlDwEHA.1292@.TK2MSFTNGP10.phx.gbl...
> I read earlier posts about restoring the master database.
> I am testing for failover, and I found that after I had restored the
master
> database to the failover server, the SQL Server service stopped
immediately
> after starting.
> The databases on the production server are on a drive which doesn't exist
on
> the failover server. Is it necessary to configure the servers
identically?
> I think perhaps SQL Server service can't start because it can't locate the
> model database to create the tempdb, or because the path the tempdb
doesn't
> exist.
> I can't get it started even with sqlservr.exe -f, in order to Alter
Database
> and change the location of the databases.
> The Event log had errors (17052, 17204) because the path in sysdatabases
> points to a non-existent location.
> I am running SQL Server 2000 Standard edition.
> Thanks
> Bill
>
>|||Master, Model, and MSDB must be in the same path they originally came from.
Keep in mind though that for reasons unknown to me SQL will shut down after
restoring even to the correct path.
"bill" <belgie@.datamti.com> wrote in message
news:#7QDmlDwEHA.1292@.TK2MSFTNGP10.phx.gbl...
> I read earlier posts about restoring the master database.
> I am testing for failover, and I found that after I had restored the
master
> database to the failover server, the SQL Server service stopped
immediately
> after starting.
> The databases on the production server are on a drive which doesn't exist
on
> the failover server. Is it necessary to configure the servers
identically?
> I think perhaps SQL Server service can't start because it can't locate the
> model database to create the tempdb, or because the path the tempdb
doesn't
> exist.
> I can't get it started even with sqlservr.exe -f, in order to Alter
Database
> and change the location of the databases.
> The Event log had errors (17052, 17204) because the path in sysdatabases
> points to a non-existent location.
> I am running SQL Server 2000 Standard edition.
> Thanks
> Bill
>
>|||Hi
The SQL server log will tell you why it fails to start, but if you are
restoring a master database from a different configuration one of the
problems will be that it can not find the databases.
You hardware should be the same configuration, see "single node failover"
section of
[url]http://www.microsoft.com/technet/prodtechnol/sql/2000/maintain/failclus.mspx#EJAA[
/url]
John
"bill" wrote:

> I read earlier posts about restoring the master database.
> I am testing for failover, and I found that after I had restored the maste
r
> database to the failover server, the SQL Server service stopped immediatel
y
> after starting.
> The databases on the production server are on a drive which doesn't exist
on
> the failover server. Is it necessary to configure the servers identically
?
> I think perhaps SQL Server service can't start because it can't locate the
> model database to create the tempdb, or because the path the tempdb doesn'
t
> exist.
> I can't get it started even with sqlservr.exe -f, in order to Alter Databa
se
> and change the location of the databases.
> The Event log had errors (17052, 17204) because the path in sysdatabases
> points to a non-existent location.
> I am running SQL Server 2000 Standard edition.
> Thanks
> Bill
>
>sql

Restoring the master database

Hello,
I am going throught my disaster recovery. I am at the point where I have a
nightly databases backup and I am backing up the transaction logs frequently
during the day.
I am having the problem that i am trying to restore the backedup master
database, but every time I restore it, I cannot get SQL to run again, so I
have to re-build the master database. I have tried doing it with Enterprise
manager and with Querry analizer, in both cases I get the message 'master
database succesfully recover and then it is shutting donw the service right
away, at this point I cannot re-start the service, am I missing something?
Please help
Joe HernandezMy guess is that the master database you have restored specifies that tempdb
and/or model should be
located on some other place compared to where they are on your restored syst
em.
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
Blog: http://solidqualitylearning.com/blogs/tibor/
"Joe Hernandez" <JoeHernandez@.discussions.microsoft.com> wrote in message
news:046BF402-C476-4489-9773-15DB290E4FC9@.microsoft.com...
> Hello,
> I am going throught my disaster recovery. I am at the point where I have a
> nightly databases backup and I am backing up the transaction logs frequent
ly
> during the day.
> I am having the problem that i am trying to restore the backedup master
> database, but every time I restore it, I cannot get SQL to run again, so I
> have to re-build the master database. I have tried doing it with Enterpris
e
> manager and with Querry analizer, in both cases I get the message 'master
> database succesfully recover and then it is shutting donw the service righ
t
> away, at this point I cannot re-start the service, am I missing something?
> Please help
> Joe Hernandez|||Please look at the error log , what error you found in it?
Regards
Amish|||Hello,
I am very new at SQL, can you tell me how to look up the error log?
"amish" wrote:

> Please look at the error log , what error you found in it?
> Regards
> Amish
>|||I dont know how would I tell that.
So do I need to restore the tempdb and the model before I restore the
masterdb?
thanks,
Joe H
"Tibor Karaszi" wrote:

> My guess is that the master database you have restored specifies that temp
db and/or model should be
> located on some other place compared to where they are on your restored sy
stem.
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://www.solidqualitylearning.com/
> Blog: http://solidqualitylearning.com/blogs/tibor/
>
> "Joe Hernandez" <JoeHernandez@.discussions.microsoft.com> wrote in message
> news:046BF402-C476-4489-9773-15DB290E4FC9@.microsoft.com...
>|||Check sysdatabases on the old installation for the original path for those d
atabases. Or the
errorlog file. You can then create a directory as the original and have copy
the files of those
databases so that they exist in the original location. Then use KB 224071 to
move those databases to
the desired location. Some articles that might be helpful:
Have a look at this list compiled by Andrew Kelly:
Moving DB's between Servers
http://www.support.microsoft.com/?id=314546
Moving SQL Server Databases to a New Location with Detach/Attach
http://www.support.microsoft.com/?id=224071
Using WITH MOVE in a Restore
http://support.microsoft.com/?id=221465
How To Transfer Logins and Passwords Between SQL Servers
http://www.support.microsoft.com/?id=246133
Mapping Logins & SIDs after a Restore
http://www.support.microsoft.com/?id=298897
Utility to map logins to users
http://www.dbmaint.com/SyncSql Logins.asp
User Logon and/or Permission Errors After Restoring Dump
http://www.support.microsoft.com/?id=168001
How to Resolve Permission Issues When a Database Is Moved Between SQL
Servers
http://www.support.microsoft.com/?id=240872
Restoring a .mdf
http://www.sqlservercentral.com/scr...sp?scriptid=599
Disaster Recovery Articles for SQL Server
http://www.support.microsoft.com/?id=307775
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
Blog: http://solidqualitylearning.com/blogs/tibor/
"Joe Hernandez" <JoeHernandez@.discussions.microsoft.com> wrote in message
news:6F9B255A-7822-4B8D-976C-1C04E44E2374@.microsoft.com...[vbcol=seagreen]
>I dont know how would I tell that.
> So do I need to restore the tempdb and the model before I restore the
> masterdb?
> thanks,
> Joe H
> "Tibor Karaszi" wrote:
>|||Tibor,
Thanks for all your help.
Do you know if it makes a difference if I am using 2 different instaces
names? should I have the same instance name on my production server as well
as my test server?
Thanks,
Joe Hernandez
"Tibor Karaszi" wrote:

> Check sysdatabases on the old installation for the original path for those
databases. Or the
> errorlog file. You can then create a directory as the original and have co
py the files of those
> databases so that they exist in the original location. Then use KB 224071
to move those databases to
> the desired location. Some articles that might be helpful:
> Have a look at this list compiled by Andrew Kelly:
> Moving DB's between Servers
> http://www.support.microsoft.com/?id=314546
> Moving SQL Server Databases to a New Location with Detach/Attach
> http://www.support.microsoft.com/?id=224071
> Using WITH MOVE in a Restore
> http://support.microsoft.com/?id=221465
> How To Transfer Logins and Passwords Between SQL Servers
> http://www.support.microsoft.com/?id=246133
> Mapping Logins & SIDs after a Restore
> http://www.support.microsoft.com/?id=298897
> Utility to map logins to users
> http://www.dbmaint.com/SyncSql Logins.asp
> User Logon and/or Permission Errors After Restoring Dump
> http://www.support.microsoft.com/?id=168001
> How to Resolve Permission Issues When a Database Is Moved Between SQL
> Servers
> http://www.support.microsoft.com/?id=240872
> Restoring a .mdf
> http://www.sqlservercentral.com/scr...sp?scriptid=599
> Disaster Recovery Articles for SQL Server
> http://www.support.microsoft.com/?id=307775
>
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://www.solidqualitylearning.com/
> Blog: http://solidqualitylearning.com/blogs/tibor/
>
> "Joe Hernandez" <JoeHernandez@.discussions.microsoft.com> wrote in message
> news:6F9B255A-7822-4B8D-976C-1C04E44E2374@.microsoft.com...
>|||For 2000, the instance name is part for the directory structure for SQL Serv
er. So, it will probably
be easier of you have the same instance name, more likely that you will have
the same directory
structure.
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
Blog: http://solidqualitylearning.com/blogs/tibor/
"Joe Hernandez" <JoeHernandez@.discussions.microsoft.com> wrote in message
news:0C55B74D-03E2-4A73-BAD4-FA8E72BA27EE@.microsoft.com...[vbcol=seagreen]
> Tibor,
> Thanks for all your help.
> Do you know if it makes a difference if I am using 2 different instaces
> names? should I have the same instance name on my production server as wel
l
> as my test server?
> Thanks,
> Joe Hernandez
> "Tibor Karaszi" wrote:
>|||you will find it in log folder in the directory where you installed
microsoft sql server.
Open the file Errorlog in notepad. It will show you the error why sql
server not starts.
Post it here to identify the reason why Services not starting.
Regards
Amish|||Tibor,
After I changed the instance name in SQL200, I had no problems restoring the
master database and right after was able to re-start server, took it off fro
m
single user mode, have restore all my other databases and I am running full
boat on the test server.
I want to thank you all that helped me and hope that others can benefit from
this issue.
Joe Hernandez
"Tibor Karaszi" wrote:

> For 2000, the instance name is part for the directory structure for SQL Se
rver. So, it will probably
> be easier of you have the same instance name, more likely that you will ha
ve the same directory
> structure.
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://www.solidqualitylearning.com/
> Blog: http://solidqualitylearning.com/blogs/tibor/
>
> "Joe Hernandez" <JoeHernandez@.discussions.microsoft.com> wrote in message
> news:0C55B74D-03E2-4A73-BAD4-FA8E72BA27EE@.microsoft.com...
>

Restoring the Master Database

I am trying to restore the master database and am getting the following erro
r:
RESTORE DATABASE must be used in single user mode when trying to restore the
master database. RESTORE DATABASE is terminating abnormally.
I know a little bit about SQL, but I am no guru, so any help is appreciated.
Thanks.Hi,
(Master database can be restore while SQL server is started in Single
user Mode)
1.. Stop SQL server Service
2.. Start Microsoft SQL Server in single-user mode.
From a command prompt, enter:
sqlservr.exe -c -m
3. Login to Query analyzer as SA
4. Execute the RESTORE DATABASE statement to restore the master
database backup, specifying:
RESTORE database master from disk='c:\backup\master.bak'
Thanks
Hari
MCDBA
"Steve" <anonymous@.discussions.microsoft.com> wrote in message
news:1DB3B978-8131-4E92-8CFB-137D6582E367@.microsoft.com...
> I am trying to restore the master database and am getting the following
error:
> RESTORE DATABASE must be used in single user mode when trying to restore
the master database. RESTORE DATABASE is terminating abnormally.
> I know a little bit about SQL, but I am no guru, so any help is
appreciated. Thanks.|||You need to start SQL Server in single-user mode in order to restore master.
This is usually done by starting SQL Server in a command window using
sqlservr.exe. For example:
CD C:\Program Files\Microsoft SQL Server\MSSQL\Binn
SQLSERVR -c -m
After you execute the RESTORE (using OSQL or Query Analyzer), SQL Server
will automatically shutdown in the command window. You can then start it
normally.
See the Books Online for more information on the SQLSERVR application.
Hope this helps.
Dan Guzman
SQL Server MVP
"Steve" <anonymous@.discussions.microsoft.com> wrote in message
news:1DB3B978-8131-4E92-8CFB-137D6582E367@.microsoft.com...
> I am trying to restore the master database and am getting the following
error:
> RESTORE DATABASE must be used in single user mode when trying to restore
the master database. RESTORE DATABASE is terminating abnormally.
> I know a little bit about SQL, but I am no guru, so any help is
appreciated. Thanks.|||Thank you, the database was restored. Now I have another problem. I restor
ed the master database to a disaster recovery server and the database names
are different. How do I Point the master DB to the new databases?|||"Steve" <anonymous@.discussions.microsoft.com> wrote in message
news:9A89A18C-6F95-4066-B08E-3D5657CDF85B@.microsoft.com...
> Thank you, the database was restored. Now I have another problem. I
restored the master database to a disaster recovery server and the database
names are different. How do I Point the master DB to the new databases?
EXEC sp_attach_db or sp_attach_single_file_db
e.g.
EXEC sp_attach_db @.dbname = N'pubs',
@.filename1 = N'c:\Program Files\Microsoft SQL
Server\MSSQL\Data\pubs.mdf',
@.filename2 = N'c:\Program Files\Microsoft SQL
Server\MSSQL\Data\pubs_log.ldf'
EXEC sp_attach_single_file_db @.dbname = 'pubs',
@.physname = 'c:\Program Files\Microsoft SQL Server\MSSQL\Data\pubs.mdf'
--Outgoing mail is certified Virus Free.Checked by AVG anti-virus system
(http://www.grisoft.com).Version: 6.0.647 / Virus Database: 414 - Release
Date: 29/03/2004|||Hi,
Since the database names and Physical file names are different in the
restored database you may need to do the below steps:-
1. Execute sp_detach_db <dbname> to detach the database
2. Use sp_attach_db <actual_dbname>,'physical mdf file name with
path','physical LDF file name with path'
Note:
Not the above 2 steps for all the problematic databases.
Thanks
Hari
MCDBA
"Steve" <anonymous@.discussions.microsoft.com> wrote in message
news:9A89A18C-6F95-4066-B08E-3D5657CDF85B@.microsoft.com...
> Thank you, the database was restored. Now I have another problem. I
restored the master database to a disaster recovery server and the database
names are different. How do I Point the master DB to the new databases?

Restoring the master database

As part of testing a cluster-to-cluster migration process, I am
attempting to restore the master database from an old test cluster
into a new one. I've read quite a bit about this online, and it looks
like a relatively easy procedure. These are the steps I'm following:
1. Stop the SQL Server.
2. At the command line, use sqlservr.exe -c -m to start SQL up in
single-user mode.
3. Use Query Analyzer or osql.exe to restore the database.
The problem I'm seeing is, with the MSSQLSERVER service stopped, I
can't get QA or osql.exe to work. I get the following error, no
matter which one I use:
Unable to connect to server:
Server: Msg 17, Level 16, State 1
[Microsoft][ODBC SQL Server Driver][DBNETLIB]SQL Server does not exist
or access denied.
With the SQL resources in Cluster Administrator offline, but the
MSSQLSERVER service not stopped, however, I can't start SQL from the
command line due to various files already being in use.
Does anyone have any suggestions on how to get around this problem.
It seems a lot of people have done something similar, but I can't
figure out what I'm missing.
Thanks!
Eric
Logon to one of the nodes and bring up 2 command line windows.
In the first command window type 'sqlservr -m'
Once SQL has started in will be running in this command window not allowing
you to do further work so switch over to the other window and run the
following 'osql -E'
You should now have a SQL prompt.
John Vandervliet.
<ecore1@.gmail.com> wrote in message
news:1176232183.047000.210960@.o5g2000hsb.googlegro ups.com...
> As part of testing a cluster-to-cluster migration process, I am
> attempting to restore the master database from an old test cluster
> into a new one. I've read quite a bit about this online, and it looks
> like a relatively easy procedure. These are the steps I'm following:
> 1. Stop the SQL Server.
> 2. At the command line, use sqlservr.exe -c -m to start SQL up in
> single-user mode.
> 3. Use Query Analyzer or osql.exe to restore the database.
> The problem I'm seeing is, with the MSSQLSERVER service stopped, I
> can't get QA or osql.exe to work. I get the following error, no
> matter which one I use:
> Unable to connect to server:
> Server: Msg 17, Level 16, State 1
> [Microsoft][ODBC SQL Server Driver][DBNETLIB]SQL Server does not exist
> or access denied.
> With the SQL resources in Cluster Administrator offline, but the
> MSSQLSERVER service not stopped, however, I can't start SQL from the
> command line due to various files already being in use.
> Does anyone have any suggestions on how to get around this problem.
> It seems a lot of people have done something similar, but I can't
> figure out what I'm missing.
> Thanks!
> Eric
>

Restoring the master database

Hello,
I am going throught my disaster recovery. I am at the point where I have a
nightly databases backup and I am backing up the transaction logs frequently
during the day.
I am having the problem that i am trying to restore the backedup master
database, but every time I restore it, I cannot get SQL to run again, so I
have to re-build the master database. I have tried doing it with Enterprise
manager and with Querry analizer, in both cases I get the message 'master
database succesfully recover and then it is shutting donw the service right
away, at this point I cannot re-start the service, am I missing something?
Please help
Joe Hernandez
My guess is that the master database you have restored specifies that tempdb and/or model should be
located on some other place compared to where they are on your restored system.
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
Blog: http://solidqualitylearning.com/blogs/tibor/
"Joe Hernandez" <JoeHernandez@.discussions.microsoft.com> wrote in message
news:046BF402-C476-4489-9773-15DB290E4FC9@.microsoft.com...
> Hello,
> I am going throught my disaster recovery. I am at the point where I have a
> nightly databases backup and I am backing up the transaction logs frequently
> during the day.
> I am having the problem that i am trying to restore the backedup master
> database, but every time I restore it, I cannot get SQL to run again, so I
> have to re-build the master database. I have tried doing it with Enterprise
> manager and with Querry analizer, in both cases I get the message 'master
> database succesfully recover and then it is shutting donw the service right
> away, at this point I cannot re-start the service, am I missing something?
> Please help
> Joe Hernandez
|||Please look at the error log , what error you found in it?
Regards
Amish
|||Hello,
I am very new at SQL, can you tell me how to look up the error log?
"amish" wrote:

> Please look at the error log , what error you found in it?
> Regards
> Amish
>
|||I dont know how would I tell that.
So do I need to restore the tempdb and the model before I restore the
masterdb?
thanks,
Joe H
"Tibor Karaszi" wrote:

> My guess is that the master database you have restored specifies that tempdb and/or model should be
> located on some other place compared to where they are on your restored system.
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://www.solidqualitylearning.com/
> Blog: http://solidqualitylearning.com/blogs/tibor/
>
> "Joe Hernandez" <JoeHernandez@.discussions.microsoft.com> wrote in message
> news:046BF402-C476-4489-9773-15DB290E4FC9@.microsoft.com...
>
|||Check sysdatabases on the old installation for the original path for those databases. Or the
errorlog file. You can then create a directory as the original and have copy the files of those
databases so that they exist in the original location. Then use KB 224071 to move those databases to
the desired location. Some articles that might be helpful:
Have a look at this list compiled by Andrew Kelly:
Moving DB's between Servers
http://www.support.microsoft.com/?id=314546
Moving SQL Server Databases to a New Location with Detach/Attach
http://www.support.microsoft.com/?id=224071
Using WITH MOVE in a Restore
http://support.microsoft.com/?id=221465
How To Transfer Logins and Passwords Between SQL Servers
http://www.support.microsoft.com/?id=246133
Mapping Logins & SIDs after a Restore
http://www.support.microsoft.com/?id=298897
Utility to map logins to users
http://www.dbmaint.com/SyncSql Logins.asp
User Logon and/or Permission Errors After Restoring Dump
http://www.support.microsoft.com/?id=168001
How to Resolve Permission Issues When a Database Is Moved Between SQL
Servers
http://www.support.microsoft.com/?id=240872
Restoring a .mdf
http://www.sqlservercentral.com/scri...p?scriptid=599
Disaster Recovery Articles for SQL Server
http://www.support.microsoft.com/?id=307775
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
Blog: http://solidqualitylearning.com/blogs/tibor/
"Joe Hernandez" <JoeHernandez@.discussions.microsoft.com> wrote in message
news:6F9B255A-7822-4B8D-976C-1C04E44E2374@.microsoft.com...[vbcol=seagreen]
>I dont know how would I tell that.
> So do I need to restore the tempdb and the model before I restore the
> masterdb?
> thanks,
> Joe H
> "Tibor Karaszi" wrote:
|||Tibor,
Thanks for all your help.
Do you know if it makes a difference if I am using 2 different instaces
names? should I have the same instance name on my production server as well
as my test server?
Thanks,
Joe Hernandez
"Tibor Karaszi" wrote:

> Check sysdatabases on the old installation for the original path for those databases. Or the
> errorlog file. You can then create a directory as the original and have copy the files of those
> databases so that they exist in the original location. Then use KB 224071 to move those databases to
> the desired location. Some articles that might be helpful:
> Have a look at this list compiled by Andrew Kelly:
> Moving DB's between Servers
> http://www.support.microsoft.com/?id=314546
> Moving SQL Server Databases to a New Location with Detach/Attach
> http://www.support.microsoft.com/?id=224071
> Using WITH MOVE in a Restore
> http://support.microsoft.com/?id=221465
> How To Transfer Logins and Passwords Between SQL Servers
> http://www.support.microsoft.com/?id=246133
> Mapping Logins & SIDs after a Restore
> http://www.support.microsoft.com/?id=298897
> Utility to map logins to users
> http://www.dbmaint.com/SyncSql Logins.asp
> User Logon and/or Permission Errors After Restoring Dump
> http://www.support.microsoft.com/?id=168001
> How to Resolve Permission Issues When a Database Is Moved Between SQL
> Servers
> http://www.support.microsoft.com/?id=240872
> Restoring a .mdf
> http://www.sqlservercentral.com/scri...p?scriptid=599
> Disaster Recovery Articles for SQL Server
> http://www.support.microsoft.com/?id=307775
>
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://www.solidqualitylearning.com/
> Blog: http://solidqualitylearning.com/blogs/tibor/
>
> "Joe Hernandez" <JoeHernandez@.discussions.microsoft.com> wrote in message
> news:6F9B255A-7822-4B8D-976C-1C04E44E2374@.microsoft.com...
>
|||For 2000, the instance name is part for the directory structure for SQL Server. So, it will probably
be easier of you have the same instance name, more likely that you will have the same directory
structure.
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
Blog: http://solidqualitylearning.com/blogs/tibor/
"Joe Hernandez" <JoeHernandez@.discussions.microsoft.com> wrote in message
news:0C55B74D-03E2-4A73-BAD4-FA8E72BA27EE@.microsoft.com...[vbcol=seagreen]
> Tibor,
> Thanks for all your help.
> Do you know if it makes a difference if I am using 2 different instaces
> names? should I have the same instance name on my production server as well
> as my test server?
> Thanks,
> Joe Hernandez
> "Tibor Karaszi" wrote:
|||you will find it in log folder in the directory where you installed
microsoft sql server.
Open the file Errorlog in notepad. It will show you the error why sql
server not starts.
Post it here to identify the reason why Services not starting.
Regards
Amish
|||Tibor,
After I changed the instance name in SQL200, I had no problems restoring the
master database and right after was able to re-start server, took it off from
single user mode, have restore all my other databases and I am running full
boat on the test server.
I want to thank you all that helped me and hope that others can benefit from
this issue.
Joe Hernandez
"Tibor Karaszi" wrote:

> For 2000, the instance name is part for the directory structure for SQL Server. So, it will probably
> be easier of you have the same instance name, more likely that you will have the same directory
> structure.
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://www.solidqualitylearning.com/
> Blog: http://solidqualitylearning.com/blogs/tibor/
>
> "Joe Hernandez" <JoeHernandez@.discussions.microsoft.com> wrote in message
> news:0C55B74D-03E2-4A73-BAD4-FA8E72BA27EE@.microsoft.com...
>

restoring the master database

I read earlier posts about restoring the master database.
I am testing for failover, and I found that after I had restored the master
database to the failover server, the SQL Server service stopped immediately
after starting.
The databases on the production server are on a drive which doesn't exist on
the failover server. Is it necessary to configure the servers identically?
I think perhaps SQL Server service can't start because it can't locate the
model database to create the tempdb, or because the path the tempdb doesn't
exist.
I can't get it started even with sqlservr.exe -f, in order to Alter Database
and change the location of the databases.
The Event log had errors (17052, 17204) because the path in sysdatabases
points to a non-existent location.
I am running SQL Server 2000 Standard edition.
Thanks
Bill
Here is a nice article on moving db locations:
http://support.microsoft.com/default...;en-us;224071.
Check the master db first.
Dejan Sarka, SQL Server MVP
Associate Mentor
www.SolidQualityLearning.com
"bill" <belgie@.datamti.com> wrote in message
news:%237QDmlDwEHA.1292@.TK2MSFTNGP10.phx.gbl...
> I read earlier posts about restoring the master database.
> I am testing for failover, and I found that after I had restored the
master
> database to the failover server, the SQL Server service stopped
immediately
> after starting.
> The databases on the production server are on a drive which doesn't exist
on
> the failover server. Is it necessary to configure the servers
identically?
> I think perhaps SQL Server service can't start because it can't locate the
> model database to create the tempdb, or because the path the tempdb
doesn't
> exist.
> I can't get it started even with sqlservr.exe -f, in order to Alter
Database
> and change the location of the databases.
> The Event log had errors (17052, 17204) because the path in sysdatabases
> points to a non-existent location.
> I am running SQL Server 2000 Standard edition.
> Thanks
> Bill
>
>
|||Master, Model, and MSDB must be in the same path they originally came from.
Keep in mind though that for reasons unknown to me SQL will shut down after
restoring even to the correct path.
"bill" <belgie@.datamti.com> wrote in message
news:#7QDmlDwEHA.1292@.TK2MSFTNGP10.phx.gbl...
> I read earlier posts about restoring the master database.
> I am testing for failover, and I found that after I had restored the
master
> database to the failover server, the SQL Server service stopped
immediately
> after starting.
> The databases on the production server are on a drive which doesn't exist
on
> the failover server. Is it necessary to configure the servers
identically?
> I think perhaps SQL Server service can't start because it can't locate the
> model database to create the tempdb, or because the path the tempdb
doesn't
> exist.
> I can't get it started even with sqlservr.exe -f, in order to Alter
Database
> and change the location of the databases.
> The Event log had errors (17052, 17204) because the path in sysdatabases
> points to a non-existent location.
> I am running SQL Server 2000 Standard edition.
> Thanks
> Bill
>
>
|||Hi
The SQL server log will tell you why it fails to start, but if you are
restoring a master database from a different configuration one of the
problems will be that it can not find the databases.
You hardware should be the same configuration, see "single node failover"
section of
http://www.microsoft.com/technet/pro...clus.mspx#EJAA
John
"bill" wrote:

> I read earlier posts about restoring the master database.
> I am testing for failover, and I found that after I had restored the master
> database to the failover server, the SQL Server service stopped immediately
> after starting.
> The databases on the production server are on a drive which doesn't exist on
> the failover server. Is it necessary to configure the servers identically?
> I think perhaps SQL Server service can't start because it can't locate the
> model database to create the tempdb, or because the path the tempdb doesn't
> exist.
> I can't get it started even with sqlservr.exe -f, in order to Alter Database
> and change the location of the databases.
> The Event log had errors (17052, 17204) because the path in sysdatabases
> points to a non-existent location.
> I am running SQL Server 2000 Standard edition.
> Thanks
> Bill
>
>
sql

Restoring the Master Database

Thank you, the database was restored. Now I have another problem. I restored the master database to a disaster recovery server and the database names are different. How do I Point the master DB to the new databases?
"Steve" <anonymous@.discussions.microsoft.com> wrote in message
news:9A89A18C-6F95-4066-B08E-3D5657CDF85B@.microsoft.com...
> Thank you, the database was restored. Now I have another problem. I
restored the master database to a disaster recovery server and the database
names are different. How do I Point the master DB to the new databases?
EXEC sp_attach_db or sp_attach_single_file_db
e.g.
EXEC sp_attach_db @.dbname = N'pubs',
@.filename1 = N'c:\Program Files\Microsoft SQL
Server\MSSQL\Data\pubs.mdf',
@.filename2 = N'c:\Program Files\Microsoft SQL
Server\MSSQL\Data\pubs_log.ldf'
EXEC sp_attach_single_file_db @.dbname = 'pubs',
@.physname = 'c:\Program Files\Microsoft SQL Server\MSSQL\Data\pubs.mdf'
--Outgoing mail is certified Virus Free.Checked by AVG anti-virus system
(http://www.grisoft.com).Version: 6.0.647 / Virus Database: 414 - Release
Date: 29/03/2004

restoring the master database

I read earlier posts about restoring the master database.
I am testing for failover, and I found that after I had restored the master
database to the failover server, the SQL Server service stopped immediately
after starting.
The databases on the production server are on a drive which doesn't exist on
the failover server. Is it necessary to configure the servers identically?
I think perhaps SQL Server service can't start because it can't locate the
model database to create the tempdb, or because the path the tempdb doesn't
exist.
I can't get it started even with sqlservr.exe -f, in order to Alter Database
and change the location of the databases.
The Event log had errors (17052, 17204) because the path in sysdatabases
points to a non-existent location.
I am running SQL Server 2000 Standard edition.
Thanks
BillHere is a nice article on moving db locations:
http://support.microsoft.com/default.aspx?scid=kb;en-us;224071.
Check the master db first.
--
Dejan Sarka, SQL Server MVP
Associate Mentor
www.SolidQualityLearning.com
"bill" <belgie@.datamti.com> wrote in message
news:%237QDmlDwEHA.1292@.TK2MSFTNGP10.phx.gbl...
> I read earlier posts about restoring the master database.
> I am testing for failover, and I found that after I had restored the
master
> database to the failover server, the SQL Server service stopped
immediately
> after starting.
> The databases on the production server are on a drive which doesn't exist
on
> the failover server. Is it necessary to configure the servers
identically?
> I think perhaps SQL Server service can't start because it can't locate the
> model database to create the tempdb, or because the path the tempdb
doesn't
> exist.
> I can't get it started even with sqlservr.exe -f, in order to Alter
Database
> and change the location of the databases.
> The Event log had errors (17052, 17204) because the path in sysdatabases
> points to a non-existent location.
> I am running SQL Server 2000 Standard edition.
> Thanks
> Bill
>
>|||Master, Model, and MSDB must be in the same path they originally came from.
Keep in mind though that for reasons unknown to me SQL will shut down after
restoring even to the correct path.
"bill" <belgie@.datamti.com> wrote in message
news:#7QDmlDwEHA.1292@.TK2MSFTNGP10.phx.gbl...
> I read earlier posts about restoring the master database.
> I am testing for failover, and I found that after I had restored the
master
> database to the failover server, the SQL Server service stopped
immediately
> after starting.
> The databases on the production server are on a drive which doesn't exist
on
> the failover server. Is it necessary to configure the servers
identically?
> I think perhaps SQL Server service can't start because it can't locate the
> model database to create the tempdb, or because the path the tempdb
doesn't
> exist.
> I can't get it started even with sqlservr.exe -f, in order to Alter
Database
> and change the location of the databases.
> The Event log had errors (17052, 17204) because the path in sysdatabases
> points to a non-existent location.
> I am running SQL Server 2000 Standard edition.
> Thanks
> Bill
>
>|||Hi
The SQL server log will tell you why it fails to start, but if you are
restoring a master database from a different configuration one of the
problems will be that it can not find the databases.
You hardware should be the same configuration, see "single node failover"
section of
http://www.microsoft.com/technet/prodtechnol/sql/2000/maintain/failclus.mspx#EJAA
John
"bill" wrote:
> I read earlier posts about restoring the master database.
> I am testing for failover, and I found that after I had restored the master
> database to the failover server, the SQL Server service stopped immediately
> after starting.
> The databases on the production server are on a drive which doesn't exist on
> the failover server. Is it necessary to configure the servers identically?
> I think perhaps SQL Server service can't start because it can't locate the
> model database to create the tempdb, or because the path the tempdb doesn't
> exist.
> I can't get it started even with sqlservr.exe -f, in order to Alter Database
> and change the location of the databases.
> The Event log had errors (17052, 17204) because the path in sysdatabases
> points to a non-existent location.
> I am running SQL Server 2000 Standard edition.
> Thanks
> Bill
>
>

Restoring the master database

Hello,
I am going throught my disaster recovery. I am at the point where I have a
nightly databases backup and I am backing up the transaction logs frequently
during the day.
I am having the problem that i am trying to restore the backedup master
database, but every time I restore it, I cannot get SQL to run again, so I
have to re-build the master database. I have tried doing it with Enterprise
manager and with Querry analizer, in both cases I get the message 'master
database succesfully recover and then it is shutting donw the service right
away, at this point I cannot re-start the service, am I missing something?
Please help
Joe HernandezMy guess is that the master database you have restored specifies that tempdb and/or model should be
located on some other place compared to where they are on your restored system.
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
Blog: http://solidqualitylearning.com/blogs/tibor/
"Joe Hernandez" <JoeHernandez@.discussions.microsoft.com> wrote in message
news:046BF402-C476-4489-9773-15DB290E4FC9@.microsoft.com...
> Hello,
> I am going throught my disaster recovery. I am at the point where I have a
> nightly databases backup and I am backing up the transaction logs frequently
> during the day.
> I am having the problem that i am trying to restore the backedup master
> database, but every time I restore it, I cannot get SQL to run again, so I
> have to re-build the master database. I have tried doing it with Enterprise
> manager and with Querry analizer, in both cases I get the message 'master
> database succesfully recover and then it is shutting donw the service right
> away, at this point I cannot re-start the service, am I missing something?
> Please help
> Joe Hernandez|||Please look at the error log , what error you found in it?
Regards
Amish|||Hello,
I am very new at SQL, can you tell me how to look up the error log?
"amish" wrote:
> Please look at the error log , what error you found in it?
> Regards
> Amish
>|||I dont know how would I tell that.
So do I need to restore the tempdb and the model before I restore the
masterdb?
thanks,
Joe H
"Tibor Karaszi" wrote:
> My guess is that the master database you have restored specifies that tempdb and/or model should be
> located on some other place compared to where they are on your restored system.
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://www.solidqualitylearning.com/
> Blog: http://solidqualitylearning.com/blogs/tibor/
>
> "Joe Hernandez" <JoeHernandez@.discussions.microsoft.com> wrote in message
> news:046BF402-C476-4489-9773-15DB290E4FC9@.microsoft.com...
> > Hello,
> >
> > I am going throught my disaster recovery. I am at the point where I have a
> > nightly databases backup and I am backing up the transaction logs frequently
> > during the day.
> >
> > I am having the problem that i am trying to restore the backedup master
> > database, but every time I restore it, I cannot get SQL to run again, so I
> > have to re-build the master database. I have tried doing it with Enterprise
> > manager and with Querry analizer, in both cases I get the message 'master
> > database succesfully recover and then it is shutting donw the service right
> > away, at this point I cannot re-start the service, am I missing something?
> >
> > Please help
> >
> > Joe Hernandez
>|||Check sysdatabases on the old installation for the original path for those databases. Or the
errorlog file. You can then create a directory as the original and have copy the files of those
databases so that they exist in the original location. Then use KB 224071 to move those databases to
the desired location. Some articles that might be helpful:
Have a look at this list compiled by Andrew Kelly:
Moving DB's between Servers
http://www.support.microsoft.com/?id=314546
Moving SQL Server Databases to a New Location with Detach/Attach
http://www.support.microsoft.com/?id=224071
Using WITH MOVE in a Restore
http://support.microsoft.com/?id=221465
How To Transfer Logins and Passwords Between SQL Servers
http://www.support.microsoft.com/?id=246133
Mapping Logins & SIDs after a Restore
http://www.support.microsoft.com/?id=298897
Utility to map logins to users
http://www.dbmaint.com/SyncSql Logins.asp
User Logon and/or Permission Errors After Restoring Dump
http://www.support.microsoft.com/?id=168001
How to Resolve Permission Issues When a Database Is Moved Between SQL
Servers
http://www.support.microsoft.com/?id=240872
Restoring a .mdf
http://www.sqlservercentral.com/scripts/scriptdetails.asp?scriptid=599
Disaster Recovery Articles for SQL Server
http://www.support.microsoft.com/?id=307775
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
Blog: http://solidqualitylearning.com/blogs/tibor/
"Joe Hernandez" <JoeHernandez@.discussions.microsoft.com> wrote in message
news:6F9B255A-7822-4B8D-976C-1C04E44E2374@.microsoft.com...
>I dont know how would I tell that.
> So do I need to restore the tempdb and the model before I restore the
> masterdb?
> thanks,
> Joe H
> "Tibor Karaszi" wrote:
>> My guess is that the master database you have restored specifies that tempdb and/or model should
>> be
>> located on some other place compared to where they are on your restored system.
>> --
>> Tibor Karaszi, SQL Server MVP
>> http://www.karaszi.com/sqlserver/default.asp
>> http://www.solidqualitylearning.com/
>> Blog: http://solidqualitylearning.com/blogs/tibor/
>>
>> "Joe Hernandez" <JoeHernandez@.discussions.microsoft.com> wrote in message
>> news:046BF402-C476-4489-9773-15DB290E4FC9@.microsoft.com...
>> > Hello,
>> >
>> > I am going throught my disaster recovery. I am at the point where I have a
>> > nightly databases backup and I am backing up the transaction logs frequently
>> > during the day.
>> >
>> > I am having the problem that i am trying to restore the backedup master
>> > database, but every time I restore it, I cannot get SQL to run again, so I
>> > have to re-build the master database. I have tried doing it with Enterprise
>> > manager and with Querry analizer, in both cases I get the message 'master
>> > database succesfully recover and then it is shutting donw the service right
>> > away, at this point I cannot re-start the service, am I missing something?
>> >
>> > Please help
>> >
>> > Joe Hernandez
>>|||Tibor,
Thanks for all your help.
Do you know if it makes a difference if I am using 2 different instaces
names? should I have the same instance name on my production server as well
as my test server?
Thanks,
Joe Hernandez
"Tibor Karaszi" wrote:
> Check sysdatabases on the old installation for the original path for those databases. Or the
> errorlog file. You can then create a directory as the original and have copy the files of those
> databases so that they exist in the original location. Then use KB 224071 to move those databases to
> the desired location. Some articles that might be helpful:
> Have a look at this list compiled by Andrew Kelly:
> Moving DB's between Servers
> http://www.support.microsoft.com/?id=314546
> Moving SQL Server Databases to a New Location with Detach/Attach
> http://www.support.microsoft.com/?id=224071
> Using WITH MOVE in a Restore
> http://support.microsoft.com/?id=221465
> How To Transfer Logins and Passwords Between SQL Servers
> http://www.support.microsoft.com/?id=246133
> Mapping Logins & SIDs after a Restore
> http://www.support.microsoft.com/?id=298897
> Utility to map logins to users
> http://www.dbmaint.com/SyncSql Logins.asp
> User Logon and/or Permission Errors After Restoring Dump
> http://www.support.microsoft.com/?id=168001
> How to Resolve Permission Issues When a Database Is Moved Between SQL
> Servers
> http://www.support.microsoft.com/?id=240872
> Restoring a .mdf
> http://www.sqlservercentral.com/scripts/scriptdetails.asp?scriptid=599
> Disaster Recovery Articles for SQL Server
> http://www.support.microsoft.com/?id=307775
>
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://www.solidqualitylearning.com/
> Blog: http://solidqualitylearning.com/blogs/tibor/
>
> "Joe Hernandez" <JoeHernandez@.discussions.microsoft.com> wrote in message
> news:6F9B255A-7822-4B8D-976C-1C04E44E2374@.microsoft.com...
> >I dont know how would I tell that.
> >
> > So do I need to restore the tempdb and the model before I restore the
> > masterdb?
> >
> > thanks,
> >
> > Joe H
> >
> > "Tibor Karaszi" wrote:
> >
> >> My guess is that the master database you have restored specifies that tempdb and/or model should
> >> be
> >> located on some other place compared to where they are on your restored system.
> >>
> >> --
> >> Tibor Karaszi, SQL Server MVP
> >> http://www.karaszi.com/sqlserver/default.asp
> >> http://www.solidqualitylearning.com/
> >> Blog: http://solidqualitylearning.com/blogs/tibor/
> >>
> >>
> >> "Joe Hernandez" <JoeHernandez@.discussions.microsoft.com> wrote in message
> >> news:046BF402-C476-4489-9773-15DB290E4FC9@.microsoft.com...
> >> > Hello,
> >> >
> >> > I am going throught my disaster recovery. I am at the point where I have a
> >> > nightly databases backup and I am backing up the transaction logs frequently
> >> > during the day.
> >> >
> >> > I am having the problem that i am trying to restore the backedup master
> >> > database, but every time I restore it, I cannot get SQL to run again, so I
> >> > have to re-build the master database. I have tried doing it with Enterprise
> >> > manager and with Querry analizer, in both cases I get the message 'master
> >> > database succesfully recover and then it is shutting donw the service right
> >> > away, at this point I cannot re-start the service, am I missing something?
> >> >
> >> > Please help
> >> >
> >> > Joe Hernandez
> >>
> >>
>|||For 2000, the instance name is part for the directory structure for SQL Server. So, it will probably
be easier of you have the same instance name, more likely that you will have the same directory
structure.
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
Blog: http://solidqualitylearning.com/blogs/tibor/
"Joe Hernandez" <JoeHernandez@.discussions.microsoft.com> wrote in message
news:0C55B74D-03E2-4A73-BAD4-FA8E72BA27EE@.microsoft.com...
> Tibor,
> Thanks for all your help.
> Do you know if it makes a difference if I am using 2 different instaces
> names? should I have the same instance name on my production server as well
> as my test server?
> Thanks,
> Joe Hernandez
> "Tibor Karaszi" wrote:
>> Check sysdatabases on the old installation for the original path for those databases. Or the
>> errorlog file. You can then create a directory as the original and have copy the files of those
>> databases so that they exist in the original location. Then use KB 224071 to move those databases
>> to
>> the desired location. Some articles that might be helpful:
>> Have a look at this list compiled by Andrew Kelly:
>> Moving DB's between Servers
>> http://www.support.microsoft.com/?id=314546
>> Moving SQL Server Databases to a New Location with Detach/Attach
>> http://www.support.microsoft.com/?id=224071
>> Using WITH MOVE in a Restore
>> http://support.microsoft.com/?id=221465
>> How To Transfer Logins and Passwords Between SQL Servers
>> http://www.support.microsoft.com/?id=246133
>> Mapping Logins & SIDs after a Restore
>> http://www.support.microsoft.com/?id=298897
>> Utility to map logins to users
>> http://www.dbmaint.com/SyncSql Logins.asp
>> User Logon and/or Permission Errors After Restoring Dump
>> http://www.support.microsoft.com/?id=168001
>> How to Resolve Permission Issues When a Database Is Moved Between SQL
>> Servers
>> http://www.support.microsoft.com/?id=240872
>> Restoring a .mdf
>> http://www.sqlservercentral.com/scripts/scriptdetails.asp?scriptid=599
>> Disaster Recovery Articles for SQL Server
>> http://www.support.microsoft.com/?id=307775
>>
>> --
>> Tibor Karaszi, SQL Server MVP
>> http://www.karaszi.com/sqlserver/default.asp
>> http://www.solidqualitylearning.com/
>> Blog: http://solidqualitylearning.com/blogs/tibor/
>>
>> "Joe Hernandez" <JoeHernandez@.discussions.microsoft.com> wrote in message
>> news:6F9B255A-7822-4B8D-976C-1C04E44E2374@.microsoft.com...
>> >I dont know how would I tell that.
>> >
>> > So do I need to restore the tempdb and the model before I restore the
>> > masterdb?
>> >
>> > thanks,
>> >
>> > Joe H
>> >
>> > "Tibor Karaszi" wrote:
>> >
>> >> My guess is that the master database you have restored specifies that tempdb and/or model
>> >> should
>> >> be
>> >> located on some other place compared to where they are on your restored system.
>> >>
>> >> --
>> >> Tibor Karaszi, SQL Server MVP
>> >> http://www.karaszi.com/sqlserver/default.asp
>> >> http://www.solidqualitylearning.com/
>> >> Blog: http://solidqualitylearning.com/blogs/tibor/
>> >>
>> >>
>> >> "Joe Hernandez" <JoeHernandez@.discussions.microsoft.com> wrote in message
>> >> news:046BF402-C476-4489-9773-15DB290E4FC9@.microsoft.com...
>> >> > Hello,
>> >> >
>> >> > I am going throught my disaster recovery. I am at the point where I have a
>> >> > nightly databases backup and I am backing up the transaction logs frequently
>> >> > during the day.
>> >> >
>> >> > I am having the problem that i am trying to restore the backedup master
>> >> > database, but every time I restore it, I cannot get SQL to run again, so I
>> >> > have to re-build the master database. I have tried doing it with Enterprise
>> >> > manager and with Querry analizer, in both cases I get the message 'master
>> >> > database succesfully recover and then it is shutting donw the service right
>> >> > away, at this point I cannot re-start the service, am I missing something?
>> >> >
>> >> > Please help
>> >> >
>> >> > Joe Hernandez
>> >>
>> >>
>>|||you will find it in log folder in the directory where you installed
microsoft sql server.
Open the file Errorlog in notepad. It will show you the error why sql
server not starts.
Post it here to identify the reason why Services not starting.
Regards
Amish|||Tibor,
After I changed the instance name in SQL200, I had no problems restoring the
master database and right after was able to re-start server, took it off from
single user mode, have restore all my other databases and I am running full
boat on the test server.
I want to thank you all that helped me and hope that others can benefit from
this issue.
Joe Hernandez
"Tibor Karaszi" wrote:
> For 2000, the instance name is part for the directory structure for SQL Server. So, it will probably
> be easier of you have the same instance name, more likely that you will have the same directory
> structure.
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://www.solidqualitylearning.com/
> Blog: http://solidqualitylearning.com/blogs/tibor/
>
> "Joe Hernandez" <JoeHernandez@.discussions.microsoft.com> wrote in message
> news:0C55B74D-03E2-4A73-BAD4-FA8E72BA27EE@.microsoft.com...
> > Tibor,
> >
> > Thanks for all your help.
> >
> > Do you know if it makes a difference if I am using 2 different instaces
> > names? should I have the same instance name on my production server as well
> > as my test server?
> >
> > Thanks,
> >
> > Joe Hernandez
> >
> > "Tibor Karaszi" wrote:
> >
> >> Check sysdatabases on the old installation for the original path for those databases. Or the
> >> errorlog file. You can then create a directory as the original and have copy the files of those
> >> databases so that they exist in the original location. Then use KB 224071 to move those databases
> >> to
> >> the desired location. Some articles that might be helpful:
> >>
> >> Have a look at this list compiled by Andrew Kelly:
> >>
> >> Moving DB's between Servers
> >> http://www.support.microsoft.com/?id=314546
> >>
> >> Moving SQL Server Databases to a New Location with Detach/Attach
> >> http://www.support.microsoft.com/?id=224071
> >>
> >> Using WITH MOVE in a Restore
> >> http://support.microsoft.com/?id=221465
> >>
> >> How To Transfer Logins and Passwords Between SQL Servers
> >> http://www.support.microsoft.com/?id=246133
> >>
> >> Mapping Logins & SIDs after a Restore
> >> http://www.support.microsoft.com/?id=298897
> >>
> >> Utility to map logins to users
> >> http://www.dbmaint.com/SyncSql Logins.asp
> >>
> >> User Logon and/or Permission Errors After Restoring Dump
> >> http://www.support.microsoft.com/?id=168001
> >>
> >> How to Resolve Permission Issues When a Database Is Moved Between SQL
> >> Servers
> >> http://www.support.microsoft.com/?id=240872
> >>
> >> Restoring a .mdf
> >> http://www.sqlservercentral.com/scripts/scriptdetails.asp?scriptid=599
> >>
> >> Disaster Recovery Articles for SQL Server
> >> http://www.support.microsoft.com/?id=307775
> >>
> >>
> >>
> >> --
> >> Tibor Karaszi, SQL Server MVP
> >> http://www.karaszi.com/sqlserver/default.asp
> >> http://www.solidqualitylearning.com/
> >> Blog: http://solidqualitylearning.com/blogs/tibor/
> >>
> >>
> >> "Joe Hernandez" <JoeHernandez@.discussions.microsoft.com> wrote in message
> >> news:6F9B255A-7822-4B8D-976C-1C04E44E2374@.microsoft.com...
> >> >I dont know how would I tell that.
> >> >
> >> > So do I need to restore the tempdb and the model before I restore the
> >> > masterdb?
> >> >
> >> > thanks,
> >> >
> >> > Joe H
> >> >
> >> > "Tibor Karaszi" wrote:
> >> >
> >> >> My guess is that the master database you have restored specifies that tempdb and/or model
> >> >> should
> >> >> be
> >> >> located on some other place compared to where they are on your restored system.
> >> >>
> >> >> --
> >> >> Tibor Karaszi, SQL Server MVP
> >> >> http://www.karaszi.com/sqlserver/default.asp
> >> >> http://www.solidqualitylearning.com/
> >> >> Blog: http://solidqualitylearning.com/blogs/tibor/
> >> >>
> >> >>
> >> >> "Joe Hernandez" <JoeHernandez@.discussions.microsoft.com> wrote in message
> >> >> news:046BF402-C476-4489-9773-15DB290E4FC9@.microsoft.com...
> >> >> > Hello,
> >> >> >
> >> >> > I am going throught my disaster recovery. I am at the point where I have a
> >> >> > nightly databases backup and I am backing up the transaction logs frequently
> >> >> > during the day.
> >> >> >
> >> >> > I am having the problem that i am trying to restore the backedup master
> >> >> > database, but every time I restore it, I cannot get SQL to run again, so I
> >> >> > have to re-build the master database. I have tried doing it with Enterprise
> >> >> > manager and with Querry analizer, in both cases I get the message 'master
> >> >> > database succesfully recover and then it is shutting donw the service right
> >> >> > away, at this point I cannot re-start the service, am I missing something?
> >> >> >
> >> >> > Please help
> >> >> >
> >> >> > Joe Hernandez
> >> >>
> >> >>
> >>
> >>
>

Restoring the master

I getting a versioning error when trying to restore the master at our
disaster recovery site? The error I'm getting is below, any information
would be appreciated!
2004-01-29 14:43:43.61 spid51 Using 'xpstar.dll' version
'2000.80.760' to execute extended stored procedure 'sp_MSgetversion'.
*** Sent via Developersdex http://www.examnotes.net ***
Don't just participate in USENET...get rewarded for it!This is an informational message, net an error.
Note that once the master database restore has completed, SQL Server will
shut itself down.
Hope this helps.
Dan Guzman
SQL Server MVP
"Dave Brooks" <dbrooks@.neca.org> wrote in message
news:%2359brYq5DHA.1948@.TK2MSFTNGP12.phx.gbl...
quote:

> I getting a versioning error when trying to restore the master at our
> disaster recovery site? The error I'm getting is below, any information
> would be appreciated!
> 2004-01-29 14:43:43.61 spid51 Using 'xpstar.dll' version
> '2000.80.760' to execute extended stored procedure 'sp_MSgetversion'.
> *** Sent via Developersdex http://www.examnotes.net ***
> Don't just participate in USENET...get rewarded for it!

Tuesday, March 20, 2012

restoring msdb of different server

Hi
Evironment: SQL Server 2000 SP3a
I want to restore master & msdb (which transfers login,
settings, jobs etc.) of old server to the new server. What
are the possible issues with this approach, if any? Is
UPDATE msdb.dbo.sysjobs
SET originating_server = 'NewServerName'
WHERE originating_server = 'OldServerName'
enough in case of msdb?
The old server is Windows 2000 Advanced Server SP4, HP
Proliant DL 380 G3 with 2 x 2.4 GHz Intel Xeon
Hyper-Threading CPUs, 4GB RAM, of which 2GB is for apps,
and HP SmartArray 5300/256 Ultra SCSI 320 RAID controller
with Ultra SCSI 320 15k RPM disks attached. The new server
is Windows 2003 Server Standart SP1, HP ProLiant DL 380 G4
with 2 x 3.6 GHz Intel Xeon Hyper-Threading CPUs, 3.5 GB of
app/OS RAM, the same RAID setup as in the old server.
I haven't changed any SQL Server settings on the old
server, except CPU affinity mask to use just one virtual
CPU on each of the physical CPUs and max. degree of
paralellism to 1.
Is SQL Server Setup aware of more advanced hardware of the
new server to such an extent that it can automatically
produce more optimal SQL server settings (stored in master)
than they were produced for the old server?
I.e. will the auto-generated settings in master database
from old server hurt performance on the new server?
--
Many, many thanks,
OskSee if this helps:
HOW TO: Move Databases Between Computers That Are Running SQL Server
http://support.microsoft.com/default.aspx?scid=kb;en-us;314546
AMB
"Osk" wrote:
> Hi
> Evironment: SQL Server 2000 SP3a
> I want to restore master & msdb (which transfers login,
> settings, jobs etc.) of old server to the new server. What
> are the possible issues with this approach, if any? Is
> UPDATE msdb.dbo.sysjobs
> SET originating_server = 'NewServerName'
> WHERE originating_server = 'OldServerName'
> enough in case of msdb?
> The old server is Windows 2000 Advanced Server SP4, HP
> Proliant DL 380 G3 with 2 x 2.4 GHz Intel Xeon
> Hyper-Threading CPUs, 4GB RAM, of which 2GB is for apps,
> and HP SmartArray 5300/256 Ultra SCSI 320 RAID controller
> with Ultra SCSI 320 15k RPM disks attached. The new server
> is Windows 2003 Server Standart SP1, HP ProLiant DL 380 G4
> with 2 x 3.6 GHz Intel Xeon Hyper-Threading CPUs, 3.5 GB of
> app/OS RAM, the same RAID setup as in the old server.
> I haven't changed any SQL Server settings on the old
> server, except CPU affinity mask to use just one virtual
> CPU on each of the physical CPUs and max. degree of
> paralellism to 1.
> Is SQL Server Setup aware of more advanced hardware of the
> new server to such an extent that it can automatically
> produce more optimal SQL server settings (stored in master)
> than they were produced for the old server?
> I.e. will the auto-generated settings in master database
> from old server hurt performance on the new server?
>
> --
> Many, many thanks,
> Osk
>

restoring msdb of different server

Hi
Evironment: SQL Server 2000 SP3a
I want to restore master & msdb (which transfers login,
settings, jobs etc.) of old server to the new server. What
are the possible issues with this approach, if any? Is
UPDATE msdb.dbo.sysjobs
SET originating_server = 'NewServerName'
WHERE originating_server = 'OldServerName'
enough in case of msdb?
The old server is Windows 2000 Advanced Server SP4, HP
Proliant DL 380 G3 with 2 x 2.4 GHz Intel Xeon
Hyper-Threading CPUs, 4GB RAM, of which 2GB is for apps,
and HP SmartArray 5300/256 Ultra SCSI 320 RAID controller
with Ultra SCSI 320 15k RPM disks attached. The new server
is Windows 2003 Server Standart SP1, HP ProLiant DL 380 G4
with 2 x 3.6 GHz Intel Xeon Hyper-Threading CPUs, 3.5 GB of
app/OS RAM, the same RAID setup as in the old server.
I haven't changed any SQL Server settings on the old
server, except CPU affinity mask to use just one virtual
CPU on each of the physical CPUs and max. degree of
paralellism to 1.
Is SQL Server Setup aware of more advanced hardware of the
new server to such an extent that it can automatically
produce more optimal SQL server settings (stored in master)
than they were produced for the old server?
I.e. will the auto-generated settings in master database
from old server hurt performance on the new server?
Many, many thanks,
Osk
See if this helps:
HOW TO: Move Databases Between Computers That Are Running SQL Server
http://support.microsoft.com/default...b;en-us;314546
AMB
"Osk" wrote:

> Hi
> Evironment: SQL Server 2000 SP3a
> I want to restore master & msdb (which transfers login,
> settings, jobs etc.) of old server to the new server. What
> are the possible issues with this approach, if any? Is
> UPDATE msdb.dbo.sysjobs
> SET originating_server = 'NewServerName'
> WHERE originating_server = 'OldServerName'
> enough in case of msdb?
> The old server is Windows 2000 Advanced Server SP4, HP
> Proliant DL 380 G3 with 2 x 2.4 GHz Intel Xeon
> Hyper-Threading CPUs, 4GB RAM, of which 2GB is for apps,
> and HP SmartArray 5300/256 Ultra SCSI 320 RAID controller
> with Ultra SCSI 320 15k RPM disks attached. The new server
> is Windows 2003 Server Standart SP1, HP ProLiant DL 380 G4
> with 2 x 3.6 GHz Intel Xeon Hyper-Threading CPUs, 3.5 GB of
> app/OS RAM, the same RAID setup as in the old server.
> I haven't changed any SQL Server settings on the old
> server, except CPU affinity mask to use just one virtual
> CPU on each of the physical CPUs and max. degree of
> paralellism to 1.
> Is SQL Server Setup aware of more advanced hardware of the
> new server to such an extent that it can automatically
> produce more optimal SQL server settings (stored in master)
> than they were produced for the old server?
> I.e. will the auto-generated settings in master database
> from old server hurt performance on the new server?
>
> --
> Many, many thanks,
> Osk
>

restoring msdb of different server

Hi
Evironment: SQL Server 2000 SP3a
I want to restore master & msdb (which transfers login,
settings, jobs etc.) of old server to the new server. What
are the possible issues with this approach, if any? Is
UPDATE msdb.dbo.sysjobs
SET originating_server = 'NewServerName'
WHERE originating_server = 'OldServerName'
enough in case of msdb?
The old server is Windows 2000 Advanced Server SP4, HP
Proliant DL 380 G3 with 2 x 2.4 GHz Intel Xeon
Hyper-Threading CPUs, 4GB RAM, of which 2GB is for apps,
and HP SmartArray 5300/256 Ultra SCSI 320 RAID controller
with Ultra SCSI 320 15k RPM disks attached. The new server
is Windows 2003 Server Standart SP1, HP ProLiant DL 380 G4
with 2 x 3.6 GHz Intel Xeon Hyper-Threading CPUs, 3.5 GB of
app/OS RAM, the same RAID setup as in the old server.
I haven't changed any SQL Server settings on the old
server, except CPU affinity mask to use just one virtual
CPU on each of the physical CPUs and max. degree of
paralellism to 1.
Is SQL Server Setup aware of more advanced hardware of the
new server to such an extent that it can automatically
produce more optimal SQL server settings (stored in master)
than they were produced for the old server?
I.e. will the auto-generated settings in master database
from old server hurt performance on the new server?
Many, many thanks,
OskSee if this helps:
HOW TO: Move Databases Between Computers That Are Running SQL Server
http://support.microsoft.com/defaul...kb;en-us;314546
AMB
"Osk" wrote:

> Hi
> Evironment: SQL Server 2000 SP3a
> I want to restore master & msdb (which transfers login,
> settings, jobs etc.) of old server to the new server. What
> are the possible issues with this approach, if any? Is
> UPDATE msdb.dbo.sysjobs
> SET originating_server = 'NewServerName'
> WHERE originating_server = 'OldServerName'
> enough in case of msdb?
> The old server is Windows 2000 Advanced Server SP4, HP
> Proliant DL 380 G3 with 2 x 2.4 GHz Intel Xeon
> Hyper-Threading CPUs, 4GB RAM, of which 2GB is for apps,
> and HP SmartArray 5300/256 Ultra SCSI 320 RAID controller
> with Ultra SCSI 320 15k RPM disks attached. The new server
> is Windows 2003 Server Standart SP1, HP ProLiant DL 380 G4
> with 2 x 3.6 GHz Intel Xeon Hyper-Threading CPUs, 3.5 GB of
> app/OS RAM, the same RAID setup as in the old server.
> I haven't changed any SQL Server settings on the old
> server, except CPU affinity mask to use just one virtual
> CPU on each of the physical CPUs and max. degree of
> paralellism to 1.
> Is SQL Server Setup aware of more advanced hardware of the
> new server to such an extent that it can automatically
> produce more optimal SQL server settings (stored in master)
> than they were produced for the old server?
> I.e. will the auto-generated settings in master database
> from old server hurt performance on the new server?
>
> --
> Many, many thanks,
> Osk
>

Restoring Master to get SQL login back

Hi Everyone, I'm hoping someone can help me.
We've had a SQL login deleted (special application one) and I understand the best way I can get it back, is to restore the Master database. Is this true ? All the manuals are working on the fact that Master has become corrupt & that it should be rebuilt before restoring. Ours is not corrupt, so am I ok to skip rebuilding it first ?

CheersI wouldn't do that in production environment, because you lose definition of all logins, linked servers, dbs etc. created after the backup you pick to restore. What about restoring master db on test server and using DTS Transfer Logins Task or script out the login and run the script on your server? mojza|||As to rebuild, you don't need to do that. Just restore master from backup over existing master. Look up How to restore the master database (Transact-SQL) topic in Books Online. mojza|||If you know the particulars of the login (name and password), it is much easier to re-add the login, rather than restore all of master. Assuming the user has been dropped as well (which Enterprise Manager cheerfully does for you), you would actually not get any benefit from restoring master, as all of the user's permissions in the application database would still be lost. Restoring the user's permissions is what is going to bog you down much more.

If the user was not deleted, then you can run sp_change_users_login to restore the link between the database user and the (new) login.

Restoring master to a different location

I am trying to restore master to a new server but location of data and log files is different in this new server. The previous location was 'D:\Program Files\Microsoft SQL Server\MSSQL\data\" the current location is in the C: Drive; when trying to restore using MOVE:

RESTORE DATABASE master FROM DISK ='\\Pfileserver\sqlbackup\MDFfiles\master_db_20070 8170121.BAK' WITH RECOVERY ,
MOVE 'master' TO 'C:\Program Files\Microsoft SQL Server\data\master.mdf',
MOVE 'mastlog' TO 'C:\Program Files\Microsoft SQL Server\MSSQL\data\mastlog.ldf'

I get the following error message:

The system database cannot be moved by RESTORE

Is there a way you can restore master to a different location?

Thanks,

Carloshttp://support.microsoft.com/kb/224071/EN-US/

Please let know whether this info is useful.

thanks

Restoring master to a different location

I am trying to restore master to a new server but location of data and log
files is different in this new server. The previous location was 'D:\Program
Files\Microsoft SQL Server\MSSQL\data\" the current is in the C: Drive when
trying to restore using MOVE:
RESTORE DATABASE master FROM DISK
='\\Pfileserver\sqlbackup\MDFfiles\master_db_200708170121.BAK' WITH RECOVERY ,
MOVE 'master' TO 'C:\Program Files\Microsoft SQL
Server\data\master.mdf',
MOVE 'mastlog' TO 'C:\Program Files\Microsoft SQL
Server\MSSQL\data\mastlog.ldf'
I get the following error message:
The system database cannot be moved by RESTORE
Is there a way you can restore master to a different location?
Thanks,
CarlosHi Carlos
http://support.microsoft.com/kb/304692/ describes how to restore a master
database
John
"Carlos" wrote:
> I am trying to restore master to a new server but location of data and log
> files is different in this new server. The previous location was 'D:\Program
> Files\Microsoft SQL Server\MSSQL\data\" the current is in the C: Drive when
> trying to restore using MOVE:
> RESTORE DATABASE master FROM DISK
> ='\\Pfileserver\sqlbackup\MDFfiles\master_db_200708170121.BAK' WITH RECOVERY ,
> MOVE 'master' TO 'C:\Program Files\Microsoft SQL
> Server\data\master.mdf',
> MOVE 'mastlog' TO 'C:\Program Files\Microsoft SQL
> Server\MSSQL\data\mastlog.ldf'
> I get the following error message:
> The system database cannot be moved by RESTORE
> Is there a way you can restore master to a different location?
> Thanks,
> Carlos

Restoring Master question

Ive done some reading and it appears as though restoring master to a box
with another name is frowned upon. Does anyone know if its supported or not?
If so, do you have step by step instructions? If not, what about another box
name but a matching named instance?
sql2k sp3
TIA, ChrisR
Hi
Check out:
http://support.microsoft.com/default...-us;Q314546#10
and
http://support.microsoft.com/default...en-us%3b224071
John
"ChrisR" <ChrisR@.NoEmails.com> wrote in message
news:u$x%23y2quEHA.2144@.tk2msftngp13.phx.gbl...
> Ive done some reading and it appears as though restoring master to a box
> with another name is frowned upon. Does anyone know if its supported or
not?
> If so, do you have step by step instructions? If not, what about another
box
> name but a matching named instance?
> --
> sql2k sp3
> TIA, ChrisR
>