Showing posts with label GoldenGate. Show all posts
Showing posts with label GoldenGate. Show all posts

Thursday, October 21, 2010

SSWUG presentations October 2010 - LIVE!!

I actaully am sitting in the Bits on the Wire studios at this very moment, gearing up to present 3 sessinos. I will be speaking about GoldenGate SQL Server Replication Configuration, Database Switch preparedness, Profile and Trace.

I am always honored to be selected to present in this virtual conference and love to do it. It kicks me in the butt to get some topics prepared, and then to get them polished to the point that they may make sense to others. I simcerely hope that my knowledge can be shared with others thru these presentations and help others out there that are struggling with similar items that I work with daily.

I sit here writing notes on paper, to ensure that I actually cover everything I want too. Its tough to get all the information distilled, then ensure that its actually covered.

Just wanted to say some of these things to the blog and document it. So, when i am at home sometime, preparing a presentation, i can recall these excited moments just prior to going live.

Friday, December 04, 2009

Wanna see some of my favorite GoldenGate scripts?

We use GoldenGate for replication from our hot server, to our warm, search and dr. Lots of data is replicated, using many different GoldenGate processes. From time to time, we will stop a process, halting replicatino for a period. After starting it back up, replication will be latent for a period. Given time, it will catch up. But in the meantime, I get worried about the status. I also need to know if processes are running or stopped.

To aid in this purpose, I have created some standard sql scripts that will provide me the data needed.

To see which items are latent, we can check the ACONPROCSB table within the DirectorDB, and produce latency times for each item that is 3 minutes latent.

--Get Latent > 3:00
SELECT
SUBSTRING(LASTCHECKPOINTLAG, 1, 2) as [hours],
SUBSTRING(LASTCHECKPOINTLAG, 4, 2) as [minutes],
SUBSTRING(LASTCHECKPOINTLAG, 7, 2) as [seconds],
CommonName as [ServerName],
ProcessName,
ProcessType,
LastStatus,
LASTCHECKPOINTLAG
FROM DirectorDB.GGS_DIRECTOR.ACONPROCSB WITH(NOLOCK)
where LastCheckPointLag > '00:03:00'
order by LastCheckPointLag desc, [ServerName], ProcessType, ProcessName


To see which items are not running, we can check the ACONPROCSB table within the DirectorDB, and check the LastStatus value of each process.

--Get Non-Running
SELECT
CommonName as [ServerName],
ProcessName,
ProcessType,
LastStatus
FROM DirectorDB.GGS_DIRECTOR.ACONPROCSB WITH(NOLOCK)
where LastStatus <> 'Running'
and ProcessName not like 'R1T2T%'
order by LastCheckPointLag desc, [ServerName], ProcessType, ProcessName


I have as many of these scripts precoded to the appropriate director database, with the appropriate other 'where' clause values. I can quickly open up these scripts from within a project and execute them where they need to be executed, and tell the status of the systems. The results of this query are from the Director database, and it does contain a bit of latency itself, but its a quick and dirty solution to tell me status. Armed with this knowledge, I can easily tell where we stand.

I have used these queries to ease my mind on many many occasions. setting them up, testing them, and having them handy has helped me tremendously.