Your CDB has two regular PDBs as well as one application container with two application PDBs and an application seed. No changes have been made to the standard PDB$SEED. How many default temporary tablespaces can be assigned in the CDB?
We can verify that, by default, neither PDB$SEED nor APP SEED create temporary tablespace (at least that's how it seems to work in 19.3.0)
SQL> show pdbs
CON_ID CON_NAME OPEN MODE RESTRICTED
---------- ------------------------------ ---------- ----------
2 PDB$SEED READ ONLY NO
3 TOYS_ROOT READ WRITE NO
4 TOYS_ROOT$SEED READ WRITE NO
5 PDB1 READ WRITE NO
6 HR_ROOT READ WRITE NO
7 OPERATIONS READ WRITE NO
8 RESEARCH READ WRITE NO
SQL> select name from v$pdbs where con_id not in (select con_id from cdb_temp_files);
NAME
---------------
PDB$SEED
TOYS_ROOT$SEED
I think A is correct (CDB$ROOT + pdb1 + pdb2 + app_root + app_pdb1 + app_pdb2 = 6)
PDB$SEED has a emporary tablespace. Test:
alter session set container=pdb$seed;
select name from v$tempfile;
/u02/oradata/CDB1/pdbseed/temp012024-03-19_22-14-16-931-PM.dbf
Agree, i dont see any tempfiles in 19c.
SQL> select con_id, file_name from cdb_temp_files;
CON_ID
----------
FILE_NAME
--------------------------------------------------------------------------------
1
E:\ORADATA\CEQTESTDB\DATAFILE\O1_MF_TEMP_JKT0HX3S_.TMP
3
E:\ORADATA\CEQTESTDB\0D866E7293684B4AB3DFA708272C5DB4\DATAFILE\O1_MF_TEMP_JKT2N9
BQ_.DBF
SQL> show pdbs;
CON_ID CON_NAME OPEN MODE RESTRICTED
---------- ------------------------------ ---------- ----------
2 PDB$SEED READ ONLY NO
3 EQTESTDB READ WRITE NO
So common sense is that 8 temporary tablespaces can exist. The question asks how many DEFAULT temporary tablespaces can be ASSIGNED. Not sure if this is also 8?
There are 8 temp tablespaces. You can generate the PDBs locally and confirm the result with this query:
$ sql / as sysdba
SQL> COL con_id FORMAT a6
COL con_name FORMAT a20
COL open_mode FORMAT a20
COL ts_name FORMAT a20
COL app_root FORMAT a20
COL app_pdb FORMAT a20
COL app_seed FORMAT a20
COL app_root_con_id FORMAT a20
SELECT
c.con_id
, c.name AS con_name
, c.open_mode AS con_name
, ts.name AS ts_name
, c.application_root AS app_root
, c.application_pdb AS app_pdb
, c.application_seed AS app_seed
, c.application_root_con_id app_root_con_id
FROM v$tablespace ts
INNER JOIN v$containers c
ON c.con_id = ts.con_id
WHERE ts.name = 'TEMP'
ORDER BY ts.con_id;
/
The correct answer is 8 tempfile. If you want to see tempfiles of SEED then you should set session parameter alter session set "_EXCLUDE_SEED_CDB_VIEW" = FALSE ;
D, 8 tested.
show pdbs
CON_ID CON_NAME OPEN MODE RESTRICTED
---------- ------------------------------ ---------- ----------
2 PDB$SEED READ ONLY NO
3 APP1 READ WRITE NO
4 APP1$SEED READ WRITE NO
5 PDB2 READ WRITE NO
6 APPPDB1 READ WRITE NO
7 APPPDB2 READ WRITE NO
8 PDB1 READ WRITE NO
select count(1) from v$datafile where name like '%undo%';
COUNT(1)
----------
8
Did you try alter session to PDB$SEED then query for the temp file? The following is what I found in version 19.14.0.0
SQL> alter session set container=PDB$SEED;
Session altered.
SQL> SELECT con_id, name FROM v$containers;
CON_ID NAME
---------- ----
2 PDB$SEED
SQL> SELECT con_id,tablespace_name,file_name FROM cdb_temp_files ORDER BY con_id;
CON_ID TABLESPACE_NAME FILE_NAME
---------- ------------------------------ ---------
2 TEMP /dbbssdev_data/oradata/CBSSDEV/datafile/temp012022-05-04_18-20-27-034-PM.dbf
I think the SEED's temp tablespace is hidden from CDB, but it's still existed.
I will choose D, eight for this.
B is the right answer. pdb$seed and app seed can also have their own tempfiles as shown below from lab output. So the correct answer is 8 .
SQL> select TABLESPACE_NAME,file_name from dba_temp_files;
TABLESPACE_NAME
------------------------------
FILE_NAME
--------------------------------------------------------------------------------
TEMP
C:\USERS\APP\ORACLE\ORADATA\ORCL\PDBSEED\TEMP012021-03-08_15-37-15-070-PM.DBF
B is correct
A default temporary tablespace exists for every container in the CDB. Therefore, the CDB root and every PDB, application root, and application PDB has its own default temporary tablespace.
I recheck and agree with @mporislav. CDB$ROOT, PDB$SEED, Two PDBs, Application Root, Application Seed, 2 Application PDBs. So 8 is correct.
upvoted 4 times
...
...
Log in to ExamTopics
Sign in:
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.
Upvoting a comment with a selected answer will also increase the vote count towards that answer by one.
So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.
Rogazan
Highly Voted 3 years, 7 months ago[Removed]
9 months, 1 week agoarpz
3 years, 4 months agomporislav
Highly Voted 3 years, 8 months agodf404e2
Most Recent 1 month, 2 weeks agoacesonly
7 months, 3 weeks agoavrely
7 months, 3 weeks agoantonica
9 months, 2 weeks agokaka321
1 year, 5 months agoGuhborges
1 year, 5 months ago_gio_
1 year, 6 months agoScottL
1 year, 8 months agovkra
1 year, 10 months agojackymak
1 year, 12 months agoABAJ
3 years, 7 months agoegore0496
2 years, 11 months agoABAJ
3 years, 6 months agoABAJ
3 years, 6 months agoRinD
3 years, 8 months agoegore0496
2 years, 11 months agoRinD
3 years, 7 months ago