-
Notifications
You must be signed in to change notification settings - Fork 217
OWLS-76347 New sample scripts to manage DB service and RCU Schema #1217
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
0d357b0
dd3f313
44d210e
eddb4b4
6d77faa
71314c5
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,200 @@ | ||
# Creating Oracle DB service and RCU Schema for a Fusion Middleware domain | ||
|
||
This sample demonstrates how to create an Oracle DB service on Kubernetes cluster and create RCU schema on the Oracle DB being used by a Fusion Middleware domain. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. on Kubernetes -> in a Kubernetes There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Re-worded as follows ...
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The sample scripts in this directory demonstrates how to: |
||
|
||
The directory contains the following sample scripts to start an Oracle DB service in default namespace, stop the Oracle DB service, create an RCU schema and drop the RCU schema | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is confusing, I would turn this into a bulleted list so it is clearer that these are four separate examples |
||
|
||
``` | ||
$ ./start-db-service.sh | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. there is no explanation of what this is, what directory it is in, etc. ??? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. surely it needs some parameters or an imagePullSecret or something? you need to authenticate to pull that image don't you? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The scripts in the new directory create-rcu-schema is based on the document as described in https://oracle.github.io/weblogic-kubernetes-operator/userguide/managing-domains/fmw-infra/ Here we create convenient scripts out of the above document so that user has not to cut-n-paste the document every-time. I copied the db service/deployment yaml file from this document (which does not have imagePullSecret) The pre-requisite is that customer has to docker login into container-registry.oracle.com and download DB-slim and fmw-infra images. I can put this information on the main page w/o adding imagePullSecret in oradb.yaml Alternatively I can check the result for docker pull command and provide the suggested action as follows e.g. in start-db-service.sh ocr_pfx=container-registry.oracle.com |
||
Trying to pull repository container-registry.oracle.com/database/enterprise ... | ||
12.2.0.1-slim: Pulling from container-registry.oracle.com/database/enterprise | ||
Digest: sha256:25b0ec7cc3987f86b1e754fc214e7f06761c57bc11910d4be87b0d42ee12d254 | ||
Status: Image is up to date for container-registry.oracle.com/database/enterprise:12.2.0.1-slim | ||
deployment.extensions/oracle-db created | ||
service/oracle-db created | ||
[oracle-db-756f9b99fd-r6ghb] already initialized .. | ||
Checking Pod READY column for State [1/1] | ||
NAME READY STATUS RESTARTS AGE | ||
oracle-db-756f9b99fd-r6ghb 1/1 Running 0 3s | ||
NAME READY STATUS RESTARTS AGE | ||
oracle-db-756f9b99fd-r6ghb 1/1 Running 0 4s | ||
NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE | ||
kubernetes ClusterIP 10.96.0.1 <none> 443/TCP 16d | ||
oracle-db NodePort 10.100.148.17 <none> 1521:30011/TCP 3s | ||
Oracle DB service is RUNNING with external NodePort [30011] | ||
|
||
``` | ||
The parameters are as follows: | ||
|
||
``` | ||
-p external NodePort for the Service (default is 30011) | ||
``` | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. there are two code blocks right next to each other with no text between them, either combine them, or put some text in between There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. "external" is redunant - nodePorts are always external There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Remove the word external as follows .... $ ./start-db-service.sh -h |
||
``` | ||
The script create a Oracle DB Service in default Namesapce with default Credential that comes with the Oracle Database Slim image. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The script create a -> This script creates an There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The script creates an Oracle DB Service in default namespace with default credential that comes with the Oracle Database Slim image. |
||
$ kubectl get po | ||
NAME READY STATUS RESTARTS AGE | ||
oracle-db-756f9b99fd-ch7xt 1/1 Running 0 33m | ||
$ kubectl get svc | ||
NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE | ||
oracle-db NodePort 10.99.94.157 <none> 1521:30011/TCP 32m | ||
|
||
The DB Connection String is oracle-db.default.svc.cluster.local:1521/devpdb.k8s which can be used as rcuDatabaseURL parameter to domain.input.yaml file while creating a Fusion Middleware domain in Operator Environment | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. is this text part of the output of something? if not, it should not be in the code block |
||
|
||
The Database can be accessed thru external NodePort outside of Kubernates cluster using the URL String <hostmachine>:30011/devpdb.k8s | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. thru -> through |
||
|
||
Note : Domain-in-Image model need public DB url as rcuDatabaseURL parameter to configure Fusion Middleware domain in Operator Environment | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Note : Domain-in-Image -> Note: The domain-in-image |
||
|
||
``` | ||
|
||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. need text, or combine code blocks |
||
``` | ||
$ ./create-rcu-schema.sh -s <schemaPrefix> -d <dburl> | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. what is this? heading? explanatory text? |
||
|
||
|
||
``` | ||
The parameters are as follows: | ||
|
||
``` | ||
-s RCU Schema Prefix, Must be specified | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Must be specified -> required |
||
-d RCU Oracle Database URL (default oracle-db.default.svc.cluster.local:1521/devpdb.k8s) | ||
``` | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. two code blocks, no text between |
||
``` | ||
The script Generates the RCU schema based Schema Prefix and RCU DB URL | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The script Generates -> This script creates |
||
$ ./create-rcu-schema.sh -s domain1 | ||
[oracle-db-756f9b99fd-r6ghb] already initialized .. | ||
Checking Pod READY column for State [1/1] | ||
NAME READY STATUS RESTARTS AGE | ||
oracle-db-756f9b99fd-r6ghb 1/1 Running 0 109s | ||
Trying to pull repository container-registry.oracle.com/middleware/fmw-infrastructure ... | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. again, seems like authentication details are missing somewhere |
||
12.2.1.3: Pulling from container-registry.oracle.com/middleware/fmw-infrastructure | ||
Digest: sha256:215d05d7543cc5d500eb213fa661753ae420d53e704baabeab89600827a61131 | ||
Status: Image is up to date for container-registry.oracle.com/middleware/fmw-infrastructure:12.2.1.3 | ||
pod/rcu created | ||
[rcu] already initialized .. | ||
Checking Pod READY column for State [1/1] | ||
Pod [rcu] Status is Ready Iter [1/60] | ||
NAME READY STATUS RESTARTS AGE | ||
rcu 1/1 Running 0 7s | ||
NAME READY STATUS RESTARTS AGE | ||
oracle-db-756f9b99fd-r6ghb 1/1 Running 0 2m2s | ||
rcu 1/1 Running 0 12s | ||
CLASSPATH=/usr/java/jdk1.8.0_211/lib/tools.jar:/u01/oracle/wlserver/modules/features/wlst.wls.classpath.jar: | ||
|
||
PATH=/u01/oracle/wlserver/server/bin:/u01/oracle/wlserver/../oracle_common/modules/thirdparty/org.apache.ant/1.9.8.0.0/apache-ant-1.9.8/bin:/usr/java/jdk1.8.0_211/jre/bin:/usr/java/jdk1.8.0_211/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/java/default/bin:/u01/oracle/oracle_common/common/bin:/u01/oracle/wlserver/common/bin:/u01/oracle/container-scripts:/u01/oracle/wlserver/../oracle_common/modules/org.apache.maven_3.2.5/bin | ||
|
||
Your environment has been set. | ||
Check if the DB Service is Ready to accept Connection ? | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. are you asking them to do something? |
||
DB Connection URL [oracle-db.default.svc.cluster.local:1521/devpdb.k8s] and schemaPrefix is [domain1] | ||
[1/20] Retrying the DB Connection ... | ||
[2/20] Retrying the DB Connection ... | ||
[3/20] Retrying the DB Connection ... | ||
|
||
**** Success!!! **** | ||
|
||
You can connect to the database in your app using: | ||
|
||
java.util.Properties props = new java.util.Properties(); | ||
props.put("user", "scott"); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. these credentials have to be wrong, and we should not be printing them out anyway |
||
props.put("password", "tiger"); | ||
java.sql.Driver d = | ||
Class.forName("oracle.jdbc.OracleDriver").newInstance(); | ||
java.sql.Connection conn = | ||
Driver.connect("scott", props); | ||
|
||
RCU Logfile: /tmp/RCU2019-08-23_21-13_1202784079/logs/rcu.log | ||
|
||
Enter the database password(User:sys): | ||
|
||
|
||
Processing command line .... | ||
Repository Creation Utility - Checking Prerequisites | ||
Checking Global Prerequisites | ||
The selected Oracle database is not configured to use the AL32UTF8 character set. Oracle strongly recommends using the AL32UTF8 character set for databases that support Oracle Fusion Middleware. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. should fix the code page |
||
Enter the schema password. This password will be used for all schema users of following components:MDS,IAU,IAU_APPEND,IAU_VIEWER,OPSS,WLS,STB. | ||
|
||
|
||
Repository Creation Utility - Checking Prerequisites | ||
Checking Component Prerequisites | ||
Repository Creation Utility - Creating Tablespaces | ||
Validating and Creating Tablespaces | ||
Repository Creation Utility - Create | ||
Repository Create in progress. | ||
Percent Complete: 12 | ||
Percent Complete: 30 | ||
Percent Complete: 30 | ||
Percent Complete: 32 | ||
Percent Complete: 34 | ||
Percent Complete: 36 | ||
Percent Complete: 36 | ||
Percent Complete: 36 | ||
Percent Complete: 45 | ||
Percent Complete: 45 | ||
Percent Complete: 55 | ||
Percent Complete: 55 | ||
Percent Complete: 55 | ||
Percent Complete: 63 | ||
Percent Complete: 63 | ||
Percent Complete: 73 | ||
Percent Complete: 73 | ||
Percent Complete: 73 | ||
Percent Complete: 81 | ||
Percent Complete: 81 | ||
Percent Complete: 83 | ||
Percent Complete: 83 | ||
Percent Complete: 85 | ||
Percent Complete: 85 | ||
Percent Complete: 94 | ||
Percent Complete: 94 | ||
Percent Complete: 94 | ||
Percent Complete: 95 | ||
Percent Complete: 96 | ||
Percent Complete: 97 | ||
Percent Complete: 97 | ||
Percent Complete: 100 | ||
|
||
Repository Creation Utility: Create - Completion Summary | ||
|
||
Database details: | ||
----------------------------- | ||
Host Name : oracle-db.default.svc.cluster.local | ||
Port : 1521 | ||
Service Name : DEVPDB.K8S | ||
Connected As : sys | ||
Prefix for (prefixable) Schema Owners : DOMAIN1 | ||
RCU Logfile : /tmp/RCU2019-08-23_21-13_1202784079/logs/rcu.log | ||
|
||
Component schemas created: | ||
----------------------------- | ||
Component Status Logfile | ||
|
||
Common Infrastructure Services Success /tmp/RCU2019-08-23_21-13_1202784079/logs/stb.log | ||
Oracle Platform Security Services Success /tmp/RCU2019-08-23_21-13_1202784079/logs/opss.log | ||
Audit Services Success /tmp/RCU2019-08-23_21-13_1202784079/logs/iau.log | ||
Audit Services Append Success /tmp/RCU2019-08-23_21-13_1202784079/logs/iau_append.log | ||
Audit Services Viewer Success /tmp/RCU2019-08-23_21-13_1202784079/logs/iau_viewer.log | ||
Metadata Services Success /tmp/RCU2019-08-23_21-13_1202784079/logs/mds.log | ||
WebLogic Services Success /tmp/RCU2019-08-23_21-13_1202784079/logs/wls.log | ||
|
||
Repository Creation Utility - Create : Operation Completed | ||
[INFO] Modify the domain.input.yaml to use [oracle-db.default.svc.cluster.local:1521/devpdb.k8s] as rcuDatabaseURL and [domain1] as rcuSchemaPrefix | ||
|
||
``` | ||
|
||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. explanatory text? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. heading? |
||
``` | ||
$ ./drop-rcu-schema.sh -s <schemaPrefix> -d <dburl> | ||
``` | ||
The parameters are as follows: | ||
|
||
``` | ||
-s RCU Schema Prefix, Must be specified | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Must be specified -> required |
||
-d RCU Oracle Database URL (default oracle-db.default.svc.cluster.local:1521/devpdb.k8s) | ||
``` | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. text? |
||
``` | ||
The script drop RCU schema based Schema Prefix and RCU DB URL | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The script drop -> This script drops the |
||
``` | ||
|
||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. text? |
||
``` | ||
$ ./stop-db-service.sh | ||
``` | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. text? |
||
``` | ||
The script stop the DB service created thru start-db-service.sh | ||
``` |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
# Copyright 2018, 2019, Oracle Corporation and/or its affiliates. All rights reserved. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. this is a new file? should not have 2018 in the copyright notice |
||
# Licensed under the Universal Permissive License v 1.0 as shown at | ||
# http://oss.oracle.com/licenses/upl. | ||
# | ||
# Description | ||
# This sample script check if a given pod in a namespace is deleted | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. check -> checks |
||
|
||
#!/bin/bash | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. this has to be the first line |
||
|
||
function checkPodDelete(){ | ||
|
||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. indent the function body please |
||
pod=$1 | ||
ns=$2 | ||
|
||
status="Terminating" | ||
|
||
if [ -z ${1} ]; then | ||
echo "Either No Pod Name is provided or Pod has been Terminated ..." | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. can you work out which and give a more precise error message? |
||
exit -1 | ||
fi | ||
|
||
echo "Checking Status for Pod [$pod] in namesapce [${ns}]" | ||
|
||
max=10 | ||
count=1 | ||
while [ $count -le $max ] ; do | ||
sleep 5 | ||
pod=`kubectl get po/$1 -n ${ns} | grep -v NAME | awk '{print $1}'` | ||
if [ -z ${pod} ]; then | ||
status="Terminated" | ||
echo "Pod [$1] removed from nameSpace [${ns}]" | ||
break; | ||
fi | ||
count=`expr $count + 1` | ||
echo "Pod [$pod] Status [${status}]" | ||
done | ||
|
||
if [ $count -gt $max ] ; then | ||
echo "[ERROR] The Pod[$1] in namespace [$ns] could not be deleted in 50s"; | ||
exit 1 | ||
fi | ||
} | ||
|
||
pod=${1:-rcu} | ||
ns=${2:-default} | ||
|
||
checkPodDelete ${pod} ${ns} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,89 @@ | ||
# Copyright 2018, 2019, Oracle Corporation and/or its affiliates. All rights reserved. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. copyright has wrong year There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. shebang line missing |
||
# Licensed under the Universal Permissive License v 1.0 as shown at | ||
# http://oss.oracle.com/licenses/upl. | ||
# | ||
# Description | ||
# This sample script check the state of a given pod in a namespace | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. check -> checks |
||
# based on READY column String | ||
#NAME READY STATUS RESTARTS AGE | ||
#domain1-adminserver 1/1 Running 0 4m | ||
|
||
function checkPodState(){ | ||
|
||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. indent function body |
||
status="NotReady" | ||
max=60 | ||
count=1 | ||
|
||
pod=$1 | ||
ns=$2 | ||
state=${3:-1/1} | ||
|
||
echo "Checking Pod READY column for State [$state]" | ||
|
||
pname=`kubectl get po -n ${ns} | grep -w ${pod} | awk '{print $1}'` | ||
if [ -z ${pname} ]; then | ||
echo "No such pod [$pod] exists in NameSpace [$ns] " | ||
exit -1 | ||
fi | ||
|
||
rcode=`kubectl get po ${pname} -n ${ns} | grep -w ${pod} | awk '{print $2}'` | ||
[[ ${rcode} -eq "${state}" ]] && status="Ready" | ||
|
||
while [ ${status} != "Ready" -a $count -le $max ] ; do | ||
sleep 5 | ||
rcode=`kubectl get po/$pod -n ${ns} | grep -v NAME | awk '{print $2}'` | ||
[[ ${rcode} -eq "1/1" ]] && status="Ready" | ||
echo "Pod [$1] Status is ${status} Iter [$count/$max]" | ||
count=`expr $count + 1` | ||
done | ||
if [ $count -gt $max ] ; then | ||
echo "[ERROR] Unable to start the Pod [$pod] after 300s "; | ||
exit 1 | ||
fi | ||
|
||
pname=`kubectl get po -n ${ns} | grep -w ${pod} | awk '{print $1}'` | ||
kubectl -n ${ns} get po ${pname} | ||
} | ||
|
||
function checkPod(){ | ||
|
||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. indent |
||
max=20 | ||
count=1 | ||
|
||
pod=$1 | ||
ns=$2 | ||
|
||
pname=`kubectl get po -n ${ns} | grep -w ${pod} | awk '{print $1}'` | ||
if [ -z ${pname} ]; then | ||
echo "No such pod [$pod] exists in NameSpace [$ns]" | ||
sleep 10 | ||
#exit -1 | ||
fi | ||
|
||
rcode=`kubectl get po -n ${ns} | grep -w ${pod} | awk '{print $1}'` | ||
if [ ! -z ${rcode} ]; then | ||
echo "[$pod] already initialized .. " | ||
return 0 | ||
fi | ||
|
||
echo "The POD [${pod}] has not been initialized ..." | ||
while [ -z ${rcode} ]; do | ||
[[ $count -gt $max ]] && break | ||
echo "Pod[$pod] is being initialized ..." | ||
sleep 5 | ||
rcode=`kubectl get po -n ${ns} | grep $pod | awk '{print $1}'` | ||
count=`expr $count + 1` | ||
done | ||
|
||
if [ $count -gt $max ] ; then | ||
echo "[ERROR] Could not find Pod [$pod] after 120s"; | ||
exit 1 | ||
fi | ||
} | ||
|
||
pod=${1:-domain1-adminserver} | ||
ns=${2:-weblogic-domain} | ||
state=${3:-1/1} | ||
|
||
checkPod ${pod} ${ns} | ||
checkPodState ${pod} ${ns} ${state} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
# Copyright 2018, 2019, Oracle Corporation and/or its affiliates. All rights reserved. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. copyright wrong |
||
# Licensed under the Universal Permissive License v 1.0 as shown at | ||
# http://oss.oracle.com/licenses/upl. | ||
# | ||
|
||
. /u01/oracle/wlserver/server/bin/setWLSEnv.sh | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. how do you know weblogic is installed there? you need an argument |
||
|
||
echo "Check if the DB Service is Ready to accept Connection ?" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. get rid of question mark |
||
connectString=${1:-oracle-db.default.svc.cluster.local:1521/devpdb.k8s} | ||
schemaPrefix=${2:-domain1} | ||
echo "DB Connection URL [$connectString] and schemaPrefix is [${schemaPrefix}]" | ||
|
||
max=20 | ||
counter=0 | ||
while [ $counter -le ${max} ] | ||
do | ||
#java utils.dbping ORACLE_THIN "sys as sysdba" Oradoc_db1 ${connectString} | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. remove commented out code |
||
java utils.dbping ORACLE_THIN scott tiger ${connectString} > dbping.err 2>&1 | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. this wont work unless the db has the sample schemas installed |
||
[[ $? == 0 ]] && break; | ||
((counter++)) | ||
echo "[$counter/${max}] Retrying the DB Connection ..." | ||
sleep 10 | ||
done | ||
|
||
if [ $counter -gt ${max} ]; then | ||
echo "[ERRORR] Oracle DB Service is not ready after [${max}] iterations ..." | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. error spelled wrong |
||
exit -1 | ||
else | ||
java utils.dbping ORACLE_THIN scott tiger ${connectString} | ||
fi | ||
|
||
/u01/oracle/oracle_common/bin/rcu -silent -createRepository \ | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. hard coded path to oracle home |
||
-databaseType ORACLE -connectString ${connectString} \ | ||
-dbUser sys -dbRole sysdba -useSamePasswordForAllSchemaUsers true \ | ||
-selectDependentsForComponents true \ | ||
-schemaPrefix ${schemaPrefix} \ | ||
-component MDS -component IAU -component IAU_APPEND -component IAU_VIEWER \ | ||
-component OPSS -component WLS -component STB < /u01/oracle/pwd.txt | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. where does this pwd.txt come from? i don't recall reading about that in your readme? what's the format? |
Uh oh!
There was an error while loading. Please reload this page.