Tuesday 7 August 2018

Oracle and Linux - the gift that keeps on giving

Moving slowly forward, I was busy trying to create my database: -

dbca -silent -createDatabase \
>      -templateName General_Purpose.dbc \
>      -gdbname bpm856.uk.ibm.com -sid orcl -responseFile NO_VALUE \
>      -characterSet AL32UTF8 \
>      -sysPassword Qp455w0rd \
>      -systemPassword Qp455w0rd \
>      -createAsContainerDatabase true \
>      -numberOfPDBs 1 \
>      -pdbName pdb1 \
>      -pdbAdminPassword Qp455w0rd \
>      -databaseType MULTIPURPOSE \
>      -automaticMemoryManagement false \
>      -totalMemory 1536 \
>      -storageType FS \
>      -datafileDestination "/home/oracle/app/oracle/oradata" \
>      -redoLogFileSize 50 \
>      -emConfiguration NONE \
>      -ignorePreReqs


which got oh-so-far (!)

Copying database files
1% complete
2% complete
DBCA Operation failed.
Look at the log file "/home/oracle/app/oracle/cfgtoollogs/dbca/bpm856/bpm8560.log" for further details.


cat "/home/oracle/app/oracle/cfgtoollogs/dbca/bpm856/bpm8560.log" 

[ 2018-08-07 17:31:44.002 BST ] Copying database files
DBCA_PROGRESS : 1%
[ 2018-08-07 17:31:44.093 BST ] ORA-12547: TNS:lost contact

DBCA_PROGRESS : 2%
[ 2018-08-07 17:31:44.222 BST ] Error while cataloging RMAN Backups
[ 2018-08-07 17:31:44.313 BST ] DBCA_PROGRESS : DBCA Operation failed.


I re-ran the relink: -

relink all

and checked the log: -

cat /home/oracle/app/oracle/product/12.2.0/dbhome_1/install/relink.log

/home/oracle/app/oracle/product/12.2.0/dbhome_1/rdbms/lib/config.o: file not recognized: File truncated

make: *** [/home/oracle/app/oracle/product/12.2.0/dbhome_1/rdbms/lib/oracle] Error 1
Error in invoking target 'irman ioracle' of makefile '/home/oracle/app/oracle/product/12.2.0/dbhome_1/rdbms/lib/ins_rdbms.mk'. See '/home/oracle/app/oracle/product/12.2.0/dbhome_1/install/relinkActions2018-08-07_05-34-29-PM.log' for details.

which isn't wrong: -

ls -al $ORACLE_HOME/rdbms/lib/config.o

-rw-r--r-- 1 oracle oinstall 0 Aug  7 15:14 config.o

Following some random online advice (!), I moved the zero byte file out of the way: -

mv $ORACLE_HOME/rdbms/lib/config.o $ORACLE_HOME/rdbms/lib/config.bad

and re-ran the relink: -

relink all

and checked the output: -

cat /home/oracle/app/oracle/product/12.2.0/dbhome_1/install/relink.log

which looked OK …

and then checked the offending file: -

ls -al $ORACLE_HOME/rdbms/lib/config.o

-rw-r--r-- 1 oracle oinstall 1344 Aug  7 17:39 /home/oracle/app/oracle/product/12.2.0/dbhome_1/rdbms/lib/config.o

and now we're golden ……

One day I will understand all of this !

No comments:

Visual Studio Code - Wow 🙀

Why did I not know that I can merely hit [cmd] [p]  to bring up a search box allowing me to search my project e.g. a repo cloned from GitHub...