Oracle Linux 8.0 静默安装Oracle 19C(3)

/u01/app/oracle/product/19.3.0/dbhome_1/bin/dbca -silent -createDatabase \
    -templateName General_Purpose.dbc \
    -gdbname cdb1 -sid  cdb1 -responseFile NO_VALUE \
    -characterSet AL32UTF8 \
    -sysPassword oracle \
    -systemPassword oracle \
    -createAsContainerDatabase true \
    -numberOfPDBs 1 \
    -pdbName pdb1 \
    -pdbAdminPassword oracle \
    -databaseType MULTIPURPOSE \
    -automaticMemoryManagement false \
    -totalMemory 2000 \
    -storageType FS \
    -datafileDestination "/u01/app/oracle/oradata" \
    -redoLogFileSize 50 \
    -emConfiguration NONE \
    -ignorePreReqs

修改/etc/oratab中默认的N为Y,以便让数据库随系统的启动一起启动

[oracle@localhost ~]$ cat /etc/oratab |grep -v ^#|grep -v ^$
cdb1:/u01/app/oracle/product/19.3.0/dbhome_1:Y
[oracle@localhost ~]$
 

查看一下

[oracle@localhost ~]$ export ORACLE_SID=cdb1
[oracle@localhost ~]$ export ORACLE_HOME=/u01/app/oracle/product/19.3.0/dbhome_1
[oracle@localhost ~]$ export ORACLE_BASE=/u01/app/oracle/
[oracle@localhost ~]$ export PATH=$PATH:$ORACLE_HOME/bin
[oracle@localhost ~]$
[oracle@localhost ~]$ sqlplus / as sysdba
 
SQL*Plus: Release 19.0.0.0.0 - Production on Sat Aug 17 14:20:38 2019
Version 19.3.0.0.0
 
Copyright (c) 1982, 2019, Oracle.  All rights reserved.
 
 
Connected to:
Oracle Database 19c Enterprise Edition Release 19.0.0.0.0 - Production
Version 19.3.0.0.0
 
SQL> show pdbs;
 
    CON_ID CON_NAME                      OPEN MODE  RESTRICTED
---------- ------------------------------ ---------- ----------
        2 PDB$SEED                      READ ONLY  NO
        3 PDB1                          READ WRITE NO
SQL> alter system set db_create_file_dest='/u01/app/oracle/oradata';
 
System altered.
 
SQL> alter pluggable database pdb1 save state;
 
Pluggable database altered.
 
SQL> exit;
Disconnected from Oracle Database 19c Enterprise Edition Release 19.0.0.0.0 - Production
Version 19.3.0.0.0
[oracle@localhost ~]$ 

内容版权声明:除非注明,否则皆为本站原创文章。

转载注明出处:https://www.heiqu.com/e367fb885566651bb5af3c2c9d5675eb.html