Discovery - Oracle CBD & PDBs

Tim80
Tera Expert

Hello - 

We are having an issue that we are working through with support but I wanted to ask if anyone has run into the same issue as us and if you were able to find a workaround. 

We are trying to discover Oracle CDBs and PDBs and have found that we are only able to capture 1 CDB and their PDBs per host. Apparently this is by design and the pattern only expects to find one set (CDB and PDBs) per host.

But we have more than 1 set of CDB/PDBs per host. Meaning on one server we have CDBDB1, PDBDB1 - CDBDB2, PDBDB2 - CDBDB3, PDBDB3.

Support has suggested that we make an enhancement request but before I do that I wanted to see if anyone has run into this issue. I wasn't able to find an Oracle doc that stated that best practice was to only have one set per host, and would have thought this is common across customers but I am not an Oracle expert.

For reference we have applicative credentials in addition SSH creds to access the servers and can discover them wo issue.

1 ACCEPTED SOLUTION

RolandW1
Tera Expert

Hi Tim,

 

We have the same problem. Only 1 PDB is discovered. The problem is step 10 in the "Get Oracle instance Size info" extension section.

It uses the command:

 

"export TNS_ADMIN=" + $ora_home_exe + "/network/admin;export ORACLE_HOME=" + $ora_home_exe + "; echo  \"select name from v\$pdbs;\" |" + "\"" + $ora_home_exe + "/bin/sqlplus\" -s " + "$$username$$/'$$password$$'@" + $computer_system.primaryHostname + ":" + $connect_sql[1].listener_port + "/" + $connect_sql[1].service_name

 

The connect_sql table is filled with multiple PDB's but the above command uses connect_sql[1] as this means only the first item in the connect_sql table is being queried and not the rest. This is why only 1 PDB has been discovered.

 

The rest of the pattern seems to be able handle multiple PDB's but the above command is wrong.

We have also a case running, but to me this is a bug in the pattern and not an enhancement request. This should have been working from the beginning. Otherwise we would still be discovering Oracle 11 and lower as there is a 1:1 relation between db and instance. This is what is changed in Oracle 12.2 so this pattern has no use when only discovering just one PDB as if there was still a 1:1 relation which is no longer true.

 

 

View solution in original post

14 REPLIES 14

Tim80
Tera Expert

Anyone?

Maybe a better question: Is anyone discovering multiple CDBs on a single host? cmdb_ci_db_ora_instance

Venky VA
ServiceNow Employee
ServiceNow Employee

Hi Tim,

IP range discovery should be able to discover multiple CDBs and PDBs.

Right now it discovers multiple PDBs per CDB.

In the IP range you mention all CDB IPs it should discover all CDBs and related PDBs.[make sure mid is reachable from all hosts]

 

Hi Venky - 

Thanks for the response. 

I have the IP Addresses and can discover the individual servers with no issues.

My issue is when there is more than 1 CBD on a single host. Support said this was by design, it only expects to find one per host. We are on Orlando and using Patterns.

Just to confirm, you have discovered multiple CDBs on a single host? Did you have to make any modifications to the pattern to do so?

 

Venky VA
ServiceNow Employee
ServiceNow Employee

Hi Tim,

Yes i have discovered multiple CDBs in host.

If there are multiple CDBs in host and each CDB has different PID.

It will run oracle pattern for each of PID.

you can do quick discovery on host.

FYI:

there is issue OOB version was using SID for DB connection it will fail tnsora file is missing or doesn't have SID.

it should use ServiceName in case SID is unavailable.

check with support they have to give you latest oracle pattern + shared library files