This discussion is archived
6 Replies Latest reply: Nov 6, 2012 9:14 AM by Abhishek Jha - Oracle RSS

PURGEOLDEXTRATCS doesnt purge on remote host

grigorianvlad Newbie
Currently Being Moderated
Hi. I have the following parameters set in manager for source and destination:


-------------------------------------------------------------------
-- GoldenGate Manager --
-------------------------------------------------------------------
PORT 7809
USERID ggate, PASSWORD ***
AUTOSTART EXTRACT drprod1
AUTORESTART EXTRACT drprod1, RETRIES 3, WAITMINUTES 1, RESETMINUTES 60
PURGEOLDEXTRACTS /opt/app1/oracle/gg/dirdat/*, USECHECKPOINTS, MINKEEPDAYS 2

------------------------------------------------------------------
-- GoldenGate Manager --
------------------------------------------------------------------
PORT 7809
USERID ggate, PASSWORD ***
AUTORESTART REPLICAT RDRPROD1
AUTORESTART REPLICAT RDRPROD1, RETRIES 3, WAITMINUTES 1, RESETMINUTES 60
PURGEOLDEXTRACTS /opt/app/oracle/gg/dirdat/*, USECHECKPOINTS, MINKEEPDAYS 2

The extract puts trails directly on destination, but does not delete old ones. Some are week old. Why arent being deleted? Replication is working just fine, BTW.
There is no lag.

Thanks.
Vladimir Grigorian.
  • 1. Re: PURGEOLDEXTRATCS doesnt purge on remote host
    stevencallan Expert
    Currently Being Moderated
    GoldenGate has a forum over here:
    GoldenGate

    The purging will take place after both conditions have been met:
    At least 2 days have passed
    No other process needs the trail (with respect to checkpoints)

    Given that more than 2 days have passed, I would check for checkpoint dependency.

    From the Troubleshooting guide:
    ✔Are you using PURGEOLDEXTRACTS to manage the trail?
    ● If not, add PURGEOLDEXTRACTS to the Manager parameter file to prevent old files from
    accumulating.
    ● If you are using PURGEOLDEXTRACTS, make certain that the Manager user has the
    authority to purge trail files, and make certain that the PURGEOLDEXTRACTS options are
    used correctly. See the Oracle GoldenGate Windows and UNIX Reference Guide.

    ✔ Is there an obsolete Replicat group that is linked to the trail?
    ● A trail file will not be purged if another process has a checkpoint in it. Delete the
    obsolete group with the DELETE REPLICAT command, so that the checkpoint records are
    deleted.
    ● If a checkpoint table is being used for the group, log into the database with the DBLOGIN
    command first, so that the checkpoint will be removed from the table.
    DBLOGIN [TARGETDB <dsn>,] [USERID <user>, PASSWORD <pw>]
    DELETE REPLICAT <group>>

    Are you using a data pump? If not (but you should as a best practice), then why the purgeoldextracts for the manager on the source? Also, the path there is app1 versus app on the target, in case that is the difference (i.e., check the path on the target for where the manager is supposed to be looking).
  • 2. Re: PURGEOLDEXTRATCS doesnt purge on remote host
    grigorianvlad Newbie
    Currently Being Moderated
    Steven, thank you for your post.
    I found the error. I forgot to restart mgr after adding this:

    PURGEOLDEXTRACTS /opt/app1/oracle/gg/dirdat/*


    Once I restarted mgr all trail files older than 2 days were deleted in seconds.

    Appreciate your help.
    Vladimir Grigorian.
  • 3. Re: PURGEOLDEXTRATCS doesnt purge on remote host
    stevencallan Expert
    Currently Being Moderated
    Sorry, assumed that was running to begin with, or that if a change was made, it was stopped/re-started to pick up the change.
  • 4. Re: PURGEOLDEXTRATCS doesnt purge on remote host
    ppand002 Newbie
    Currently Being Moderated
    There is a manager refresh command that can be used.

    It can be used in place of manager re-start .

    thanks
    venkata
  • 5. Re: PURGEOLDEXTRATCS doesnt purge on remote host
    965978 Newbie
    Currently Being Moderated
    Can you please post the manager refresh command?
  • 6. Re: PURGEOLDEXTRATCS doesnt purge on remote host
    Abhishek Jha - Oracle Expert
    Currently Being Moderated
    The GGSCI REFRESH MANAGER command enables you to change any Manager parameter except the port number without stopping and restarting the Manager process.

    If you have previously put in a manager parameter and now remove it from the parameter file, the REFRESH MANAGER command WILL NOT revert back the missing parameter to its default value. This does not apply to the PORT parameter.

    It is recommended that instead of using the REFRESH MANAGER command, one should STOP and START the manager process. This will ensure that the manager parameter file reflects the actual manager environment.

    This command is now dropped from the Version 11g Oracle GoldenGate documentation.

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points