[Webinar] Streamline your web hosting managementRegister Today

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 336
  • Last Modified:

How do I bring capture program of Db2 SQL replication up automatically

Hi Experts,

I have setup SQL replication on AIX servers. The capture program often terminated with no DB connection error.

I require a script that often checks if capture program is up and start them if it is down.
If the capture is intentionally down then it should not be started.
 i have script files that will start the capture in warm mode.

But have to make them automatic. Please help me on this

0
jsaravana
Asked:
jsaravana
  • 5
  • 4
2 Solutions
 
momi_sabagCommented:
i think the better approach would be to fix the no DB connection error
why does this error happens?
0
 
jsaravanaAuthor Commented:
There are some scripts which issue force commands. Hence the db connection is lost.

Are you suggesting to stop the capture and start them after these force commands?

0
 
momi_sabagCommented:
that could work
it is always recommended to stop the capture in warm mode and not to force it's connection
0
Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

 
jsaravanaAuthor Commented:
Can we stop the capture also in warm mode?

asnccmd capture_server=db capture_schema=ASN stop

this is the command to stop capture rite. Please correct me if I am wrong.

I agree with you view of avoiding DB connection errors. But by writing a script we can always be sure that capture program is running rite. Please provide you views and suggestions on this.
0
 
momi_sabagCommented:
this looks like the write command to stop the capture
stop it like this, and after you do your force commands, start them again
0
 
jsaravanaAuthor Commented:
ok Thanks..

Can all users execute the  start and stop capture commands?

if not what is the privilege required to start and stop a capture program.
0
 
jsaravanaAuthor Commented:
I have placed these commands in a script file. They are given 744 file permissions.
0
 
momi_sabagCommented:
i think that it is enought to have permissions to run this file
0
 
jsaravanaAuthor Commented:
Thanks for you help
0

Featured Post

Learn to develop an Android App

Want to increase your earning potential in 2018? Pad your resume with app building experience. Learn how with this hands-on course.

  • 5
  • 4
Tackle projects and never again get stuck behind a technical roadblock.
Join Now