Install Oracle Database 19c (19.3) in silent mode on AIX

Step 1. check /etc/hosts

>cat /etc/hosts
10.10.10.11     pp2a

Step 2. create group

>mkgroup -A id=54321 oinstall
>mkgroup -A id=54322 dba
>mkgroup -A id=54323 oper
>mkgroup -A id=54324 backupdba
3004-694 Error adding "backupdba" : Name is too long.
>mkgroup -A id=54324 bkdba
>mkgroup -A id=54325 dgdba
>mkgroup -A id=54326 kmdba
>mkgroup -A id=54327 racdba

Step 3. create oracle user

>useradd -u 54321 -g oinstall -G dba,oper,dgdba,kmdba,bkdba,racdba -d /home/oracle oracle 
>id oracle
uid=54321(oracle) gid=54321(oinstall) groups=54322(dba),54323(oper),54325(dgdba),54326(kmdba),54324(bkdba),54327(racdba)

>mkdir /home/oracle
>chown oracle.oinstall /home/oracle

Step 4. setting enviroment on AIX

/usr/sbin/no -p -o udp_sendspace=65536
/usr/sbin/no -p -o udp_recvspace=655360
/usr/sbin/no -p -o tcp_sendspace=65536
/usr/sbin/no -p -o tcp_recvspace=65536
/usr/sbin/no -p -o rfc1323=1
/usr/sbin/no -p -o sb_max=4194304
/usr/sbin/no -r -o ipqmaxlen=512

Step 5. setting security limit

>vi /etc/security/limits
oracle:
        fsize = -1
        core = 2097151
        cpu = -1
        data = -1
        rss = -1
        stack = -1
        nofiles = -1

Step 6. config oracle .profile

>su - oracle
>vi .profile
export ORACLE_BASE=/u01/app/oracle
export ORACLE_HOME=$ORACLE_BASE/product/19.3.0/dbhome_1
export ORACLE_SID=ORCL
export PATH=/usr/sbin:$ORACLE_HOME/bin:$ORACLE_HOME/OPatch:$HOME/bin:$PATH

>. ~/.profile

Step 7. unzip Oracle Install File

>mkdir -p $ORACLE_HOME
>unzip AIX.PPC64_193000_db_home.zip -d $ORACLE_HOME

Step 8. edit install response file (software only)

>cd $ORACLE_HOME/install/response/
>cp db_install.rsp db_install.rsp.bak
>vi db_install.rsp

oracle.install.option=INSTALL_DB_SWONLY
UNIX_GROUP_NAME=oinstall
INVENTORY_LOCATION=/u01/app/oraInventory
ORACLE_HOME=/u01/app/oracle/product/19.3.0/dbhome_1
ORACLE_BASE=/u01/app/oracle
oracle.install.db.InstallEdition=EE
oracle.install.db.isCustomInstall=true
oracle.install.db.OSDBA_GROUP=dba
oracle.install.db.OSOPER_GROUP=oper
oracle.install.db.OSBACKUPDBA_GROUP=bkdba
oracle.install.db.OSDGDBA_GROUP=dgdba
oracle.install.db.OSKMDBA_GROUP=kmdba
oracle.install.db.OSRACDBA_GROUP=racdba
oracle.install.db.rootconfig.executeRootScript=false

Step 9. execute rootpre.sh by root

>su -
>cd /u01/app/oracle/product/19.3.0/dbhome_1
>sh rootpre.sh
Checking if group services should be configured....
Nothing to configure.

Step 10. Install software only in silent mode

>su - oracle
>cd $ORACLE_HOME
>./runInstaller -silent -responseFile /u01/app/oracle/product/19.3.0/dbhome_1/install/response/db_install.rsp -ignorePrereqFailure

********************************************************************************

Your platform requires the root user to perform certain pre-installation
OS preparation.  The root user should run the shell script 'rootpre.sh' before
you proceed with Oracle installation. The rootpre.sh script can be found at:
/u01/app/oracle/product/19.3.0/dbhome_1/clone/rootpre.sh

Answer 'y' if root has run 'rootpre.sh' so you can proceed with Oracle
installation.
Answer 'n' to abort installation and then ask root to run 'rootpre.sh'.

********************************************************************************

Has 'rootpre.sh' been run by root in this machine? [y/n] (n)
y
Launching Oracle Database Setup Wizard...

[WARNING] [INS-32047] The location (/u01/app/oraInventory) specified for the central inventory is not empty.
   ACTION: It is recommended to provide an empty location for the inventory.
[WARNING] [INS-13013] Target environment does not meet some mandatory requirements.
   CAUSE: Some of the mandatory prerequisites are not met. See logs for details. /tmp/InstallActions2022-03-15_05-22-18PM/installActions2022-03-15_05-22-18PM.log
   ACTION: Identify the list of failed prerequisite checks from the log: /tmp/InstallActions2022-03-15_05-22-18PM/installActions2022-03-15_05-22-18PM.log. Then either from the log file or from installation manual find the appropriate configuration to meet the prerequisites and fix it manually.
The response file for this session can be found at:
 /u01/app/oracle/product/19.3.0/dbhome_1/install/response/db_2022-03-15_05-22-18PM.rsp

You can find the log of this install session at:
 /tmp/InstallActions2022-03-15_05-22-18PM/installActions2022-03-15_05-22-18PM.log


As a root user, execute the following script(s):
        1. /u01/app/oraInventory/orainstRoot.sh
        2. /u01/app/oracle/product/19.3.0/dbhome_1/root.sh

Execute /u01/app/oraInventory/orainstRoot.sh on the following nodes: 
[pp2a]
Execute /u01/app/oracle/product/19.3.0/dbhome_1/root.sh on the following nodes: 
[pp2a]


Successfully Setup Software with warning(s).
Moved the install session logs to:
 /u01/app/oraInventory/logs/InstallActions2022-03-15_05-22-18PM

Step 11. execute orainstRoot.sh & root.sh by root

>sh /u01/app/oraInventory/orainstRoot.sh
Changing permissions of /u01/app/oraInventory.
Adding read,write permissions for group.
Removing read,write,execute permissions for world.

Changing groupname of /u01/app/oraInventory to oinstall.
The execution of the script is complete.

>sh /u01/app/oracle/product/19.3.0/dbhome_1/root.sh
Check /u01/app/oracle/product/19.3.0/dbhome_1/install/root_pp2a_2022-03-15_17-28-14.log for the output of root script

Step 12. Install listener in silent mode

>netca -silent -responseFile /u01/app/oracle/product/19.3.0/dbhome_1/assistants/netca/netca.rsp

Parsing command line arguments:
    Parameter "silent" = true
    Parameter "responsefile" = /u01/app/oracle/product/19.3.0/dbhome_1/assistants/netca/netca.rsp
Done parsing command line arguments.
Oracle Net Services Configuration:
Profile configuration complete.
Oracle Net Listener Startup:
    Running Listener Control: 
      /u01/app/oracle/product/19.3.0/dbhome_1/bin/lsnrctl start LISTENER
    Listener Control complete.
    Listener started successfully.
Listener configuration complete.
Oracle Net Services configuration successful. The exit code is 0

Step 13. Install database in silent mode

dbca -silent -createDatabase \
-templateName General_Purpose.dbc \
-gdbname PB2BC -sid PB2BC -responseFile NO_VALUE \
-characterSet AL32UTF8 \
-sysPassword 1qaz%TGB6yhn \
-systemPassword 1qaz%TGB6yhn \
-createAsContainerDatabase false \
-numberOfPDBs 0 \
-databaseType MULTIPURPOSE \
-memoryMgmtType auto_sga \
-totalMemory 3072 \
-storageType FS \
-datafileDestination "/oracle/oradata/" \
-useOMF true \
-redoLogFileSize 1000 \
-emConfiguration NONE \
-ignorePreReqs

[WARNING] [DBT-11205] Specified shared pool size does not meet the recommended minimum size requirement. This might cause database creation to fail.
   ACTION: Specify at least (2,544 MB) for shared pool size.
Prepare for db operation
10% complete
Copying database files
40% complete
Creating and starting Oracle instance
42% complete
46% complete

50% complete
54% complete
60% complete
Completing Database Creation
66% complete
69% complete
70% complete
Executing Post Configuration Actions
100% complete
Database creation complete. For details check the logfiles at:
 /u01/app/oracle/cfgtoollogs/dbca/ORCL.
Database Information:
Global Database Name:ORCL
System Identifier(SID):ORCL
Look at the log file "/u01/app/oracle/cfgtoollogs/dbca/PB2BC/PB2BC0.log" for further details.

張貼留言

0 留言