Create restore point


#!/bin/bash


# Set OUTPUT_DIRECTORY and SCRIPTS_DIRECTORY

OUTPUT_DIRECTORY="/path/to/your/output_directory"

SCRIPTS_DIRECTORY="/path/to/your/scripts_directory"


# Function to execute restore.sh

create_restore_point() {

    # Call restore.sh with arguments

    sh restore.sh "$OUTPUT_DIRECTORY" "$SCRIPTS_DIRECTORY"

}


# Call the function using log_output

log_output "Capture Listener Info" "create_restore_point"

********

#!/bin/bash


# Set OUTPUT_DIRECTORY and SCRIPTS_DIRECTORY from the first and second command-line arguments

OUTPUT_DIRECTORY="$1"

SCRIPTS_DIRECTORY="$2"


# ... (other code)


# Function to create a restore point

create_restore_point() {

    # Note: Not applicable for STANDBY's as it creates GRP on Primary if running any.

    echo "Note: Not applicable for STANDBY's as it creates GRP on Primary if running any."


    # Create Restore Point

    echo "CREATE RESTORE POINT <name> GUARANTEE FLASHBACK DATABASE;"


    # Execute dcli command

    echo "dcli -1 oracle -g /home/oracle/dbs_group --serial \"$SCRIPTS_DIRECTORY\"/create_rp.ksh -d \"$OUTPUT_DIRECTORY\"/RP_LOGS -r RP_23_PSU"

}


# Call the function

create_restore_point

Comments

Popular posts from this blog

SQL Loader V3

Db Unix

Standby redo log add