database:oracle:pluggable-database
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
database:oracle:pluggable-database [2019/01/09 12:46] – odefta | database:oracle:pluggable-database [2023/07/04 19:36] (current) – external edit 127.0.0.1 | ||
---|---|---|---|
Line 3: | Line 3: | ||
===== Auto start a pluggable database when Oracle starts ===== | ===== Auto start a pluggable database when Oracle starts ===== | ||
- | | + | < |
- | export PATH=$PATH: | + | export ORACLE_HOME=/ |
- | export ORACLE_SID=GDB_SID - SID of the global database name to connect to the main database - CDB (not pluggable - PDB) | + | export PATH=$PATH: |
+ | export ORACLE_SID=GDB_SID - SID of the global database name to connect to the main database - CDB (not pluggable - PDB) | ||
- | | + | sqlplus / as sysdba |
+ | </ | ||
Next, to open a single PDB: | Next, to open a single PDB: | ||
- | | + | <code sql> |
+ | alter pluggable database PDB_NAME open; | ||
+ | </ | ||
To open all PDBs: | To open all PDBs: | ||
- | | + | <code sql> |
+ | alter pluggable database all open; | ||
+ | </ | ||
To keep the PDBs opened after Oracle restart, we need to save their actual opened state: | To keep the PDBs opened after Oracle restart, we need to save their actual opened state: | ||
Line 21: | Line 27: | ||
For just one PDB: | For just one PDB: | ||
- | | + | <code sql> |
+ | alter pluggable database PDB_NAME save state; | ||
+ | </ | ||
For more PDBs: | For more PDBs: | ||
- | | + | <code sql> |
+ | alter pluggable database all except PDB_NAME1, PDB_NAME2 save state; | ||
+ | </ | ||
For all PDBs: | For all PDBs: | ||
- | | + | <code sql> |
+ | alter pluggable database all save state; | ||
+ | </ | ||
| | ||
===== Show all pluggable databases status ===== | ===== Show all pluggable databases status ===== | ||
Line 44: | Line 56: | ||
</ | </ | ||
- | |||
- | |||
- |
database/oracle/pluggable-database.1547030817.txt.gz · Last modified: 2023/07/04 19:36 (external edit)