database mirroring - How to find exact time of last received transaction on asynchronous mirror (SQL Server 2005)? -


I think I can get to the previous LSN using: [Master] from

  SELECT [mirroring_failover_lsn]. [Sys]. [Database_mirroring]  

But it will not give me the right time.

read. You will notice that LOP_BEGIN_XACT contains a timestamp, looking at an LSN, you can correct the log and get all pending transactions (these are all Xact_ads which have no committed or rollback logs before the given LSN is). All pending changes will be brought back in case of failover Data will be lost if this incorrect failover The number of pending transactions will be pending, and these different transactions have started several times. If you want to attach the 'right time of data integrity' you can say that any data loss will not occur before the earliest pending lop_begin_xact. for example. The following log streams:

  + ----- + ----------- + --------- + ----- - ------ + | Lsn Operation | Xact_id | Timestamp | + ----- + ----------- + --------- + ------------ + | 1 | INSERT | 1 | | | 2 | BEGIN_XACT | 2 | 12:00 pm | 3 | INSERT | 1 | | | 4 | BEGIN_XACT | 3 | 12:02 | | 5 | COMMIT_XACT | 1 | | | 6 | INSERT | 2 | | | 7 | INSERT | 3 | | | 8 | COMMIT_XACT | 3 | | | 9 | COMMIT_XACT | 2 | |  

We say that mirroring failover is LSN8. In this case you can say that the data loss will not be before 12:00, because Xact_id is not committed on 2 LSN 8 and therefore it will be rolled back Note that xact_id 3 is to LSN 8, so it will not be lost, even if there is a later time ticket. So your timestamp is not complete, that's why I say 'Data will be done before ...' after 'After data ... will be lost'


Comments

Popular posts from this blog

java - Can't add JTree to JPanel of a JInternalFrame -

javascript - data.match(var) not working it seems -

javascript - How can I pause a jQuery .each() loop, while waiting for user input? -