Hi,
I've established the log shipping between my Primary database server and the
Stand by database server.
In the Stand by server, the database is gray, and in the BACKUP folder,
there're MyDB_init.bak and many .TRN files.
1.How do I make the MyDB's color not gray in that Stand by server? I wanna
test the SELECT and see if the record between the Primary and Stand by
server are consistant.
2. What will happen if I delete some .TRN files?
Thanks for help.
Jason
Jason
A standby database must be read-only. You can run SELECT statements againts
it. If you want the db READ-WRITE apply last log file and run
RESTORE DATABASE database_name WITH RECOVERY
EXEC SP_DBOPTION 'database_name', 'read only', 'false'
"Jason Huang" <JasonHuang8888@.hotmail.com> wrote in message
news:OGKoEINJIHA.5208@.TK2MSFTNGP04.phx.gbl...
> Hi,
> I've established the log shipping between my Primary database server and
> the
> Stand by database server.
> In the Stand by server, the database is gray, and in the BACKUP folder,
> there're MyDB_init.bak and many .TRN files.
> 1.How do I make the MyDB's color not gray in that Stand by server? I
> wanna
> test the SELECT and see if the record between the Primary and Stand by
> server are consistant.
> 2. What will happen if I delete some .TRN files?
> Thanks for help.
>
> Jason
>
Showing posts with label thestand. Show all posts
Showing posts with label thestand. Show all posts
Monday, March 26, 2012
Friday, March 23, 2012
log shipping question
Hi,
I've established the log shipping between my Primary database server and the
Stand by database server.
In the Stand by server, the database is gray, and in the BACKUP folder,
there're MyDB_init.bak and many .TRN files.
1.How do I make the MyDB's color not gray in that Stand by server? I wanna
test the SELECT and see if the record between the Primary and Stand by
server are consistant.
2. What will happen if I delete some .TRN files?
Thanks for help.
JasonJason
A standby database must be read-only. You can run SELECT statements againts
it. If you want the db READ-WRITE apply last log file and run
RESTORE DATABASE database_name WITH RECOVERY
EXEC SP_DBOPTION 'database_name', 'read only', 'false'
"Jason Huang" <JasonHuang8888@.hotmail.com> wrote in message
news:OGKoEINJIHA.5208@.TK2MSFTNGP04.phx.gbl...
> Hi,
> I've established the log shipping between my Primary database server and
> the
> Stand by database server.
> In the Stand by server, the database is gray, and in the BACKUP folder,
> there're MyDB_init.bak and many .TRN files.
> 1.How do I make the MyDB's color not gray in that Stand by server? I
> wanna
> test the SELECT and see if the record between the Primary and Stand by
> server are consistant.
> 2. What will happen if I delete some .TRN files?
> Thanks for help.
>
> Jason
>
I've established the log shipping between my Primary database server and the
Stand by database server.
In the Stand by server, the database is gray, and in the BACKUP folder,
there're MyDB_init.bak and many .TRN files.
1.How do I make the MyDB's color not gray in that Stand by server? I wanna
test the SELECT and see if the record between the Primary and Stand by
server are consistant.
2. What will happen if I delete some .TRN files?
Thanks for help.
JasonJason
A standby database must be read-only. You can run SELECT statements againts
it. If you want the db READ-WRITE apply last log file and run
RESTORE DATABASE database_name WITH RECOVERY
EXEC SP_DBOPTION 'database_name', 'read only', 'false'
"Jason Huang" <JasonHuang8888@.hotmail.com> wrote in message
news:OGKoEINJIHA.5208@.TK2MSFTNGP04.phx.gbl...
> Hi,
> I've established the log shipping between my Primary database server and
> the
> Stand by database server.
> In the Stand by server, the database is gray, and in the BACKUP folder,
> there're MyDB_init.bak and many .TRN files.
> 1.How do I make the MyDB's color not gray in that Stand by server? I
> wanna
> test the SELECT and see if the record between the Primary and Stand by
> server are consistant.
> 2. What will happen if I delete some .TRN files?
> Thanks for help.
>
> Jason
>
Monday, March 12, 2012
log shipping failover to stand by server
Hi Guys
in logshipping to fail over to stand by server do i have
to do any role change
as far as i know i have to run following script at the
stand by server. am i right?
RESTORE DATABASE database_name WITH RECOVERY
EXEC SP_DBOPTION 'database_name', 'read
only', 'false'
EXEC SP_DBOPTION 'database_name', 'dbo use
only', 'false'
pls advice me
Thanks
Biju
Biju,
have a look at 'log shipping, role changes' in BOL. You don't need to run
your script manually, but run
sp_change_primary_role
sp_change_secondary_role
sp_change_monitor_role
Usually the logins have already been transferred so there's nothing else to
do. These sprocs are useful because they'll try to get the last log (the
live one) if at all possible.
HTH,
Paul Ibison
|||BUT I DONT want to change roles.
>--Original Message--
>Biju,
>have a look at 'log shipping, role changes' in BOL. You
don't need to run
>your script manually, but run
>sp_change_primary_role
>sp_change_secondary_role
>sp_change_monitor_role
>Usually the logins have already been transferred so
there's nothing else to
>do. These sprocs are useful because they'll try to get
the last log (the
>live one) if at all possible.
>HTH,
>Paul Ibison
>
>.
>
|||Biju,
the name is perhaps slightly unintuitive. sp_change_secondary_role:
(a) Copies the final production database transaction log backup to the
standby server along with any additional transaction log backups that were
not previously copied.
(b) Disables the log-shipping transaction copy job on the standby server.
(c) Restores all transaction log backups not previously restored to the
standby database and initiates the recovery of the standby database.
(d) Terminates and rolls back all pending transactions.
(e) Sets the access level of the standby database after completion of the
system stored procedure to multiuser mode.
(f) Creates a log-shipping database maintenance plan on the new primary
server for the new production database. The SQL Server Agent job defined in
this plan backs up the transaction log of the new production database to the
folder location you specified when you set up log shipping.
HTH,
Paul Ibison
in logshipping to fail over to stand by server do i have
to do any role change
as far as i know i have to run following script at the
stand by server. am i right?
RESTORE DATABASE database_name WITH RECOVERY
EXEC SP_DBOPTION 'database_name', 'read
only', 'false'
EXEC SP_DBOPTION 'database_name', 'dbo use
only', 'false'
pls advice me
Thanks
Biju
Biju,
have a look at 'log shipping, role changes' in BOL. You don't need to run
your script manually, but run
sp_change_primary_role
sp_change_secondary_role
sp_change_monitor_role
Usually the logins have already been transferred so there's nothing else to
do. These sprocs are useful because they'll try to get the last log (the
live one) if at all possible.
HTH,
Paul Ibison
|||BUT I DONT want to change roles.
>--Original Message--
>Biju,
>have a look at 'log shipping, role changes' in BOL. You
don't need to run
>your script manually, but run
>sp_change_primary_role
>sp_change_secondary_role
>sp_change_monitor_role
>Usually the logins have already been transferred so
there's nothing else to
>do. These sprocs are useful because they'll try to get
the last log (the
>live one) if at all possible.
>HTH,
>Paul Ibison
>
>.
>
|||Biju,
the name is perhaps slightly unintuitive. sp_change_secondary_role:
(a) Copies the final production database transaction log backup to the
standby server along with any additional transaction log backups that were
not previously copied.
(b) Disables the log-shipping transaction copy job on the standby server.
(c) Restores all transaction log backups not previously restored to the
standby database and initiates the recovery of the standby database.
(d) Terminates and rolls back all pending transactions.
(e) Sets the access level of the standby database after completion of the
system stored procedure to multiuser mode.
(f) Creates a log-shipping database maintenance plan on the new primary
server for the new production database. The SQL Server Agent job defined in
this plan backs up the transaction log of the new production database to the
folder location you specified when you set up log shipping.
HTH,
Paul Ibison
Subscribe to:
Posts (Atom)