Manually purging trail files from OCI GoldenGate Service
Oracle GoldenGate Service is Oracle’s cloud offering to quickly use GoldenGate to move data within OCI as well as other clouds. Now network connection and bandwidth has a bit to do with the speed of data being processed, but it a quick service over all.
One thing that any GoldenGate Administrator has to get use to is the lack of access to the underlying host where GoldenGate is running. As my friends, the PMs, have told me this is due to GoldenGate Service being a “SERVICE”. This basically means you do not need or will get access to the underlying filesystem of GGS. For many GoldenGate Administrators this will be frustrating from a troubleshooting aspect – How do you confirm or make sure that trail files are being written to or read from? Well, the answer is in OCI GoldenGate Service, but that is not the point of this post.
The item that needs to be discussed is how to clean up trail files in GGS? Cleaning up trail files is important because they do take space and if you don’t have a task enabled to clean up trail files, then space will be consumed and eventually used up. How do you take care of this issue then manually? The answer is simple and what is built into Oracle GoldenGate and Oracle GoldenGate Service – REST APIs.
To purge a single set of trail files (all trail files) that begin with a specific name, the below code can be used in Microsoft Visual Studio Code (VSCode).
@url = <url>
###
POST {{url}}/services/v2/commands/execute
Authorization: Basic Z2dhZG1pbjphbHRlY0dHUE9DYWRtaW4yMyE
Content-Type: text/plain
{
"name": "purge",
"purgeType": "trails",
"trails": [
{
"name": “AL"
}
],
"useCheckpoints": false,
"keep": [
{
"type": "min”,
"units": "files”,
"value": 0
}
]
}
###
In the above example code, we are removing all the trail files that being with “AL”. If you want to remove more than one series of trail files, we can simply add more trail file names to the code as follows:
@url = <url>
###
POST {{url}}/services/v2/commands/execute
Authorization: Basic Z2dhZG1pbjphbHRlY0dHUE9DYWRtaW4yMyE
Content-Type: text/plain
{
"name": "purge",
"purgeType": "trails",
"trails": [
{
"name": “AL”
},
{
“name”:”AB”
}
],
"useCheckpoints": false,
"keep": [
{
"type": "min”,
"units": "files”,
"value": 0
}
]
}
###
If you are curious how this would look in a written cURL command, the below would do the same thing:
curl --request POST \
--url <url>/services/v2/commands/execute \
--header 'authorization: Basic Z2dhZG1pbjphbHRlY0dHUE9DYWRtaW4yMyE' \
--header 'content-type: text/plain' \
--header 'user-agent: vscode-restclient' \
--data '{"name": "purge","purgeType": "trails","trails": [{"name": "AL"}],"useCheckpoints": false,"keep": [{"type": "min","units": "files","value": 0}]}'
Enjoy!
Current Oracle Certs
Bobby Curtis
I’m Bobby Curtis and I’m just your normal average guy who has been working in the technology field for awhile (started when I was 18 with the US Army). The goal of this blog has changed a bit over the years. Initially, it was a general blog where I wrote thoughts down. Then it changed to focus on the Oracle Database, Oracle Enterprise Manager, and eventually Oracle GoldenGate.
If you want to follow me on a more timely manner, I can be followed on twitter at @dbasolved or on LinkedIn under “Bobby Curtis MBA”.
Muchas gracias. ?Como puedo iniciar sesion?
priligy where to buy Br J Clin Pharmacol 2010; 69 656 62
The number of twin births has increased by nearly 75 percent in the past 30 years precio priligy 30 mg
The maximum daily dose of 500 mg see section 4 priligy walgreens However, if you look at this collection of information much of it referenced to the OB GYN
Review from Jakeb14 cialis and priligy Furthermore, when we evaluated the effect of various definitions of gout, our findings appeared to be robust, and the magnitude of the associations tended to increase with increasing specificity of the case definition