AWR snapshot taken for TPROC-C results #296
-
For Oracle 21c , when we are running latest HammerDB for a TPROC-C run using one hammerdb client per PDB and provide the PDB name as service name for each hammerDB instance. While the results are being collected we see that the AWR snapshot is being taken for the CDB database SID. How can we make sure that the results derived from awr snapshots are from individual PDB and not CDB within which multiple PDBs are running in parallel? |
Beta Was this translation helpful? Give feedback.
Replies: 5 comments 3 replies
-
Hi, There was an Issue for exactly this problem in 19c that was correctly resolved by a Pull Request. So the PDB shows both the CDB and PDB snapshots and HammerDB takes the most recent time interval (this was the change from previously ordering by snap id) - the assumption is that the PDB being tested gives the most recent one by time. If you take a look at Issue #189, it provides detailed troubleshooting information to help diagnose the cause further. Please take a look at it and provide some further information on exactly what snapshots are showing and HammerDB is retrieving. The behaviour has changed on a number of occasions in Oracle releases, so it could be entirely possible that something has changed between 19c and 21c that requires this to be revisited. |
Beta Was this translation helpful? Give feedback.
-
In the driver script in the script editor window is both the systemconnect and user set to the PDB?
If yes, please take a look at Issue #189 and provide output of some of the troubleshooting queries shown there that show the contents of DBA_HIST_SNAPSHOT. This is the best way to diagnose the issue and see if something has changed in Oracle 21c. |
Beta Was this translation helpful? Give feedback.
-
You can see the query used here 8748981 this is the commit that updated to the current functionality to list snapshots by time. |
Beta Was this translation helpful? Give feedback.
-
OK - thanks for confirming 'DBA_HIST_SNAPSHOT' = AWR_CDB_SNAPSHOT - this will need looking at again as both the snapshot is taken in the CDB and the query. Feel free to submit a pull request with an update to resolve the issue. Otherwise, it will be looked into when time permits. I will create an issue from the discussion to tracke it. |
Beta Was this translation helpful? Give feedback.
-
Having revisited this, the underlying AWR is the same, ie. there is only one:
So if we run an example workload against a pluggable database it reports the snaphots as 60 to 61. If we then run awrrpt then this shows the snapshots we have taken. If we then specify "Location of AWR Data Specified: AWR_PDB" then this gives us a report on the PDB as required. e.g. Container Name= RAZPDB1
So this is working as intended in Issue #189 and should be sufficient for most use cases. |
Beta Was this translation helpful? Give feedback.
Having revisited this, the underlying AWR is the same, ie. there is only one: