Assigning values to variables, using ECHO and reading a file. Assigning Variables Name the variable on the left. Variables names are case sensitive. No spaces around the equals sign in the middle. The value is on the right side of the equals sign. When using the variable afterwards, precede the variable name with a $. … Continue reading Linux Echo and Reading Files
Tag: Linux
Run an Unattended SQL Script from Linux using nohup
Some scripts take a long time to run. If they are interrupted, you will lose all your work. To get around that, create a bash file to run the script for you, then run the script file with the NOHUP option so it won't hang up. Scripts and Running with NOHUP Make sure you have access … Continue reading Run an Unattended SQL Script from Linux using nohup
Using Oracle’s srvctl to Complete a RAC Flashback
A flashback restore point is handy for deployments of new code and testing. Remember: You cannot properly shutdown a RAC database using sqlplus command. Use srvctl commands instead. Flashback to Restore Point (RAC) >$ srvctl stop database -d myDB -o immediate >$ srvctl start instance -d myDB -i myDB1 -o mount SQL> flashback database to restore … Continue reading Using Oracle’s srvctl to Complete a RAC Flashback
Oracle’s SRVCTL: Enable an Instance. Make an Instance Preferred. Check a Service’s Status.
How to use the Oracle Server Control (srvctl) to enable instances, and see configurations and statuses. Enabling an Instance # srvctl enable instance -d [unique database name] -i "[instance1],[instance2]" Enables instances. If repeated, get messages, PRCC-1011: [db] was already enabled on [server name 1], [server name 2] PRCR-1002: Resource [resource name] is already enabled See … Continue reading Oracle’s SRVCTL: Enable an Instance. Make an Instance Preferred. Check a Service’s Status.
Oracle srvctl Basics – Listener and Database Commands
When a database is getting started, generally the listener control service (lsnrctl) is started and the database is started by logging into the database and executing the startup command. If you're in a RAC configuration, you should be using srvctl; this command knows your configuration and works on the entire RAC environment instead of just … Continue reading Oracle srvctl Basics – Listener and Database Commands