December 9, 2011 at 4:45 am
Hi Team,
I have DR setup in 'ABC' as primary and the same databases in 'BCD' aas mirrored database.
If I faile this database from ABC to BCD now the database primary will be in BCD.
NOw i need the sql agest jobs to be the same.
Any suggestions please guide me.
Thanks in advance.
December 9, 2011 at 5:02 am
You can set up an SSIS Transfer Jobs task to do this, then run it as a scheduled job or on demand as necessary.
You can also do the same for logins if required.
December 9, 2011 at 7:16 am
With your jobs, also keep in mind to check your db-state in a first step ...
cfr
if exists ( select 1
from sys.database_mirroring
Where mirroring_role_desc = 'MIRROR'
and database_id = db_id('DMKoudwals') )
begin
Print 'Mirrored db Status [DMKoudwals]: ' + convert(varchar(128),databasepropertyex( 'DMKoudwals','Status'))
end
else
begin
BACKUP DATABASE [DMKoudwals] TO [DMKoudwalsFull] WITH INIT , NOUNLOAD , NAME = 'DMKoudwals_Full', SKIP , STATS = 10, DESCRIPTION = 'Full Database Backup' , NOFORMAT
end
Johan
Learn to play, play to learn !
Dont drive faster than your guardian angel can fly ...
but keeping both feet on the ground wont get you anywhere :w00t:
- How to post Performance Problems
- How to post data/code to get the best help[/url]
- How to prevent a sore throat after hours of presenting ppt
press F1 for solution, press shift+F1 for urgent solution 😀
Need a bit of Powershell? How about this
Who am I ? Sometimes this is me but most of the time this is me
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply