Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: trigger script after archive log switch

Re: trigger script after archive log switch

From: Sean M <smckeownNO_at_BACKSIESearthlink.net>
Date: Tue, 25 Jun 2002 15:32:59 -0600
Message-ID: <3D18E18B.F6A44AF6@BACKSIESearthlink.net>


Philip Brown wrote:
>
> I am looking to invoke a system script, in the background, that will take
> care of copying the archive log, via scp, to an outside location.
> I dont want to simply use NFS with multiple archive dests, for multiple
> reasons.
>
> I am fully aware of potential overlap issues if the prior script has not
> finished running, etc. and will take care of that appropriately. I just
> need a way to make it get called automaticaly when a new archivelog
> is created, rather than have an inefficient demon that polls the directory
> every second or something.

Hi Philip-

You seem to have 2 criteria that are at odds with each other: 1) you want to guarantee that an archive is copied to an alternate location the instant it is created but 2) you don't want to let Oracle do this for you (using multiple archive_log_dest params). You can't have both. If you want Oracle to guarantee that an archive is copied to an alternate location the instant it is created, you need to let Oracle do this through it's own built-in mechanisms. If you don't want to use Oracle's built-in mechanisms which guarantee this copy, you will have to poll (either the database itself via v$archived_log or the OS via ls, etc.) on some interval. If you're suggesting that your interval would be on the order of 1 second, you're implying that you need a *guaranteed* copy the instant the archive is created. But that requires letting Oracle be in control. Can't have the cake and eat it too...

It might help matters if you could explain your multiple reasons for not wanting to use multiple archive destinations w/in Oracle (I assume this has something to do with security concerns), along with your reasons for needing the file copied so quickly in the first place. If you really can't use multiple archive destinations, then I'd suggest you back off your polling interval to something more reasonable, like every 10 minutes. I'd also suggest you be very careful about checking to be sure Oracle is done with the file before initiating your copy.

Regards,
Sean M Received on Tue Jun 25 2002 - 16:32:59 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US