首页 > 数据库 > Oracle > Oracle 19C 静默标准化安装
Shell> su - oracle Shell> unzip LINUX.X64_193000_db_home.zip -d $ORACLE_HOME
早期版本的常用做法是编辑响应文件( database/response/db_install.rsp ),然后在调用响应文件进行静默安装。
Shell> export ORACLE_HOSTNAME=ora19c
Shell> export ORA_INVENTORY=/oracle/oraInventory
Shell> cd $ORACLE_HOME
Shell> ./runInstaller -ignorePrereq -waitforcompletion -silent \
oracle.install.option=INSTALL_DB_SWONLY \
ORACLE_HOSTNAME=${ORACLE_HOSTNAME} \
UNIX_GROUP_NAME=oinstall \
INVENTORY_LOCATION=${ORA_INVENTORY} \
ORACLE_HOME=${ORACLE_HOME} \
ORACLE_BASE=${ORACLE_BASE} \
oracle.install.db.InstallEdition=EE \
oracle.install.db.OSDBA_GROUP=dba \
oracle.install.db.OSBACKUPDBA_GROUP=dba \
oracle.install.db.OSDGDBA_GROUP=dba \
oracle.install.db.OSKMDBA_GROUP=dba \
oracle.install.db.OSRACDBA_GROUP=dba \
SECURITY_UPDATES_VIA_MYORACLESUPPORT=false \
DECLINE_SECURITY_UPDATES=true
[oracle@ora19c db_1]$ ./runInstaller -ignorePrereq -waitforcompletion -silent \
> oracle.install.option=INSTALL_DB_SWONLY \
> ORACLE_HOSTNAME=${ORACLE_HOSTNAME} \
> UNIX_GROUP_NAME=oinstall \
> INVENTORY_LOCATION=${ORA_INVENTORY} \
> ORACLE_HOME=${ORACLE_HOME} \
> ORACLE_BASE=${ORACLE_BASE} \
> oracle.install.db.InstallEdition=EE \
> oracle.install.db.OSDBA_GROUP=dba \
> oracle.install.db.OSBACKUPDBA_GROUP=dba \
> oracle.install.db.OSDGDBA_GROUP=dba \
> oracle.install.db.OSKMDBA_GROUP=dba \
> oracle.install.db.OSRACDBA_GROUP=dba \
> SECURITY_UPDATES_VIA_MYORACLESUPPORT=false \
> DECLINE_SECURITY_UPDATES=true
Launching Oracle Database Setup Wizard...
[WARNING] [INS-32055] The Central Inventory is located in the Oracle base.
ACTION: Oracle recommends placing this Central Inventory in a location outside the Oracle base directory.
[WARNING] [INS-13014] Target environment does not meet some optional requirements.
CAUSE: Some of the optional prerequisites are not met. See logs for details. installActions2023-03-03_02-05-27PM.log
ACTION: Identify the list of failed prerequisite checks from the log: installActions2023-03-03_02-05-27PM.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:
/oracle/app/product/19.3.0/db_1/install/response/db_2023-03-03_02-05-27PM.rsp
You can find the log of this install session at:
/tmp/InstallActions2023-03-03_02-05-27PM/installActions2023-03-03_02-05-27PM.log
As a root user, execute the following script(s):
1. /oracle/app/oraInventory/orainstRoot.sh
2. /oracle/app/product/19.3.0/db_1/root.sh
Execute /oracle/app/oraInventory/orainstRoot.sh on the following nodes:
[ora19c]
Execute /oracle/app/product/19.3.0/db_1/root.sh on the following nodes:
[ora19c]
Successfully Setup Software with warning(s).
Moved the install session logs to:
/oracle/app/oraInventory/logs/InstallActions2023-03-03_02-05-27PM
Shell> su - oracle Shell> cd $ORACLE_HOME/network/admin Shell> vi listener.ora LISTENER = (DESCRIPTION_LIST = (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = ora19c)(PORT = 1521)) (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521)) ) )
Shell> dbca -help Shell> dbca -silent -createDatabase
Shell> export ORACLE_SID=prod
Shell> export DATA_DIR=/oracle/app/product/oradata
Shell> dbca -silent -createDatabase \
-templateName General_Purpose.dbc \
-gdbname ${ORACLE_SID} -sid ${ORACLE_SID} \
-characterSet AL32UTF8 \
-sysPassword Abcd321# \
-systemPassword Abcd321# \
-databaseType MULTIPURPOSE \
-memoryMgmtType AUTO \
-totalMemory 1024 \
-storageType FS \
-datafileDestination "${DATA_DIR}" \
-redoLogFileSize 500 \
-emConfiguration NONE \
-ignorePreReqs
[oracle@ora19c ~]$ dbca -silent -createDatabase \
> -templateName General_Purpose.dbc \
> -gdbname ${ORACLE_SID} -sid ${ORACLE_SID} \
> -characterSet AL32UTF8 \
> -sysPassword Abcd321# \
> -systemPassword Abcd321# \
> -databaseType MULTIPURPOSE \
> -memoryMgmtType AUTO \
> -totalMemory 1024 \
> -storageType FS \
> -datafileDestination "${DATA_DIR}" \
> -redoLogFileSize 500 \
> -emConfiguration NONE \
> -ignorePreReqs
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:
/oracle/app/cfgtoollogs/dbca/prod.
Database Information:
Global Database Name:prod
System Identifier(SID):prod
Look at the log file "/oracle/app/cfgtoollogs/dbca/prod/prod.log" for further details.
Shell> dbca -help Shell> dbca -silent -createDatabase
Shell> export ORACLE_SID=orcl
Shell> export PDB_NAME=orclpdb
Shell> export DATA_DIR=/oracle/app/product/oradata
Shell> dbca -silent -createDatabase \
-templateName General_Purpose.dbc \
-gdbname ${ORACLE_SID} -sid ${ORACLE_SID} \
-characterSet AL32UTF8 \
-sysPassword Abcd321# \
-systemPassword Abcd321# \
-createAsContainerDatabase true \
-pdbName ${PDB_NAME} \
-numberOfPDBs 1 \
-pdbAdminPassword Abcd321# \
-databaseType MULTIPURPOSE \
-memoryMgmtType AUTO \
-totalMemory 1024 \
-storageType FS \
-useOMF true \
-datafileDestination "${DATA_DIR}" \
-redoLogFileSize 500 \
-emConfiguration NONE \
-ignorePreReqs
[oracle@ora19c ~]$ dbca -silent -createDatabase \
> -templateName General_Purpose.dbc \
> -gdbname ${ORACLE_SID} -sid ${ORACLE_SID} \
> -characterSet AL32UTF8 \
> -sysPassword Abcd321# \
> -systemPassword Abcd321# \
> -createAsContainerDatabase true \
> -pdbName ${PDB_NAME} \
> -numberOfPDBs 1 \
> -pdbAdminPassword Abcd321# \
> -databaseType MULTIPURPOSE \
> -memoryMgmtType AUTO \
> -totalMemory 1024 \
> -storageType FS \
> -datafileDestination "${DATA_DIR}" \
> -redoLogFileSize 50 \
> -emConfiguration NONE \
> -ignorePreReqs
Prepare for db operation
8% complete
Copying database files
31% complete
Creating and starting Oracle instance
32% complete
36% complete
40% complete
43% complete
46% complete
Completing Database Creation
51% complete
53% complete
54% complete
Creating Pluggable Databases
58% complete
77% complete
Executing Post Configuration Actions
100% complete
Database creation complete. For details check the logfiles at:
/oracle/app/cfgtoollogs/dbca/orcl.
Database Information:
Global Database Name:orcl
System Identifier(SID):orcl
Look at the log file "/oracle/app/cfgtoollogs/dbca/orcl/orcl.log" for further details.
来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/30310891/viewspace-2976773/ ,如需转载,请注明出处,否则将追究法律责任。