Oracle Database resources protect an Oracle database instance by managing the Oracle service during failover and failback. When the primary server fails, LifeKeeper starts the Oracle instance on a standby server and brings it in-service.

Resource Type: database/oraapp
Aliases: oraapp, oracle

Preconditions

  • Oracle Database must be installed on the server.
  • The Oracle SID and Oracle home must be configured and accessible.
  • A valid Oracle administrative account (DBA) with “sysdba” privileges must be provided.

Subcommands

Oracle Database resources are managed by commands of the form:

lkcli resource database/oraapp <subcommand> [flags]

Subcommand Description Required Role
create Create a new Oracle Database resource admin
extend Extend to a standby server admin
get-property Read a resource property guest
set-property Update an editable resource property admin

create

lkcli resource database/oraapp create \
  --oracle-home-name=<string> --oracle-sid=<string> \
  --oracle-username=<string> --oracle-password=<string> [flags]

Flag Short Type Required Default Constraints Description
--oracle-home-name string Yes Oracle home name
--oracle-sid string Yes Oracle System ID (SID)
--oracle-username string Yes Oracle DBA username
--oracle-password string Yes Oracle DBA password
--optional-services array No Comma-separated list of additional Oracle services to manage
--control-listener boolean No true Whether to control the database listener
--listener-resource string No LifeKeeper Oracle Listener resource tag
--tag string No Auto-generated Resource tag name
--switchback enum No INTELLIGENT INTELLIGENT, AUTOMATIC Switchback type
--deepcheck-interval int No 300 min: 0, max: 604800 Deepcheck interval in seconds
--quickcheck-interval int No 180 min: 0, max: 604800 Quickcheck interval in seconds
--local-recovery enum No enabled enabled, disabled Enable local recovery

extend

lkcli resource database/oraapp extend --primary-sys=<string> --primary-tag=<string> [flags]

Flag Short Type Required Default Constraints Description
--primary-sys string Yes Hostname of the server the existing resource is extended from
--primary-tag string Yes Tag of the existing resource to extend
--standby-sys string No Value of --host (defaults to localhost) Hostname of the standby server
--switchback enum No INTELLIGENT INTELLIGENT, AUTOMATIC Switchback type
--primary-priority int No Defaults to the current priority of the --primary-sys server, or 1 if the resource has not yet been extended min: 1, max: 999 Failover priority for the primary server
--standby-priority int No Defaults to an unused value which is computed dynamically based on the priority values currently in-use min: 1, max: 999 Failover priority for the standby server

get-property / set-property

lkcli resource database/oraapp get-property --tag=<string> --property=<string>
lkcli resource database/oraapp set-property --tag=<string> --property=<string> --value=<string>

Flag Short Type Required Description
--tag -t string Yes Resource tag name
--property -p string Yes Property name (see Properties table below)
--value -v string Yes (set-property only) New property value

Properties

Property Type Constraints Editable Description
oracle-home string No Oracle home directory path
oracle-home-name string No Oracle home name
oracle-sid string No Oracle System ID (SID)
oracle-version string No Oracle version string
oracle-db-auth object Yes Oracle database authentication credentials object
optional-services array Yes Additional Oracle-related services to manage
deepcheck-interval int min: 0, max: 604800 Yes Deepcheck interval in seconds (default: 300)
quickcheck-interval int min: 0, max: 604800 Yes Quickcheck interval in seconds (default: 180)
local-recovery enum enabled, disabled Yes Enable local recovery
switchback enum INTELLIGENT, AUTOMATIC Yes Switchback type

Example Usage

# Create an Oracle Database resource
lkcli resource database/oraapp create \
  --host=server1 \
  --oracle-home-name=OraDB19Home1 \
  --oracle-sid=ORCL \
  --oracle-username=sys \
  --oracle-password=oracle \
  --control-listener=false \
  --listener-resource=listener.0 \
  --tag=oraapp.ORCL

# Extend to server2
lkcli resource database/oraapp extend \
  --primary-sys=server1 \
  --primary-tag=oraapp.ORCL \
  --standby-sys=server2

Feedback

Was this helpful?

Yes No
You indicated this topic was not helpful to you ...
Could you please leave a comment telling us why? Thank you!
Thanks for your feedback.

Post your comment on this topic.

Post Comment