My Headlines
HowTo: Create a universal UDM report page in OEM
PROBLEM:
PROBLEM:
- You have a bunch of User Defined Metrics (UDM) setup in OEM, and you want to know the staus of each of them.
- OEM does not provide a single page to show the status of UDMs - users must navigate to each instance and look at the UDM page.
- Create a standard OEM Report to display all of your UDMs in one place!
- First, if you have not already discovered this the hard way, you cannot create a Report against a non-EMREP/non-Repository tables. Why, i'll never know. But, whatever. The thing is, if you try to create a report using something easy like showing how many records are in an Target Database table, it will return the error "ORA-00942: table or view does not exist"
- In this case, we are actually hitting an OEM Repository table, but it's not one of the objects we are allowed to query via the "Table From SQL" report element type.
- Fortunately, "bwolter" found a work-around for this sorry situation and published how to it in this Oracle OEM Forum post.
- Follow his 3 easy steps, then continue with my Step 5 below.
- Create a new Report and choose whatever you want for Category, etc.
- Set the "Targets" value to the "Use the specified target" radio-button and select your Repository SID
- Set the "Privileges" value to "Run report using target privileges of the report owner (SYSTEM)"
- Click the "Elements" sub-tab, then Add a new element using the new "target_user_table_from_sql" type.
- Click the "Set Parameters" icon and enter your SQL. Note that your value of KEY_VALUE will be different than mine!
SELECT DISTINCT UPPER(target_name) "Target Name", key_value || '__' "Metric Name", TO_CHAR(collection_timestamp, 'MM-DD-YYYY HH24:MI') "Last Collected_____", string_value "Metric Value" FROM sysman.em$current_metrics WHERE metric_name = 'SQLUDM' AND UPPER(key_value) LIKE 'ENSURE%' AND string_value IS NOT NULL ORDER BY 1, 2
- My KEY_VALUE (the "Name" you used for the UDM) is "Ensure PMON is running as MST", so obviously you will set your value to whatever the Name of your UDM is.
- Rinse-and-repeat Steps 8-10 for each UDM type or gorup you want to show on the Report.
- I use underscore in my column alias names to stretch the columns out for easy reading.
- During this project I found a UDM which had encountered errors and stopped running! OEM showed no indication outside of a small icon on the Instance's UDM page (nor did it send a notification). This report will save you from that potential embarrasement!!
- Here is what my final UDM Report looks like:
Subscribe to:
Post Comments (Atom)
Popular Posts
-
What is ENUM? ENUM is short for enumeration. Its a useful programming type that contains an ordered list of string values. The program...
-
A colleague asked me some questions about FIRST_ROWS and ALL_ROWS, but I'm hesitant to blog about it because it's already been done...
-
Dear Blog Readers, Every now and then I do receive e-mails from the novice DBAs saying that: “We could not perform well at the interview...
-
HowTo: Create a universal UDM report page in OEM PROBLEM: You have a bunch of User Defined Metrics (UDM) setup in OEM, and you want to kn...
-
Have you run the new Oracle 11g installer on *NIX and received a nasty message? It happened to me this week! So, let's say you downloa...
-
REM:********************************************************************************************** REM: Script : Max 50 I/O Informations R...
-
What is NOCOPY? 'NOCOPY' is an optional 'hint' to tell the PL/SQL 'compiler' not to go through the overhead of ma...
-
This blog post is for them; those who are desperately looking for free Oracle Certification dumps. Well, you might be surprised to see the...
-
I was browsing the Oracle Forums earlier today and this post with a bit of SQL to clear OEM alerts from mnazim , who always has good advice...
-
Having chosen Oracle SQL Developer as your preferred Oracle database tool, do you have to install and learn a new technology for supporting...
0 comments:
Post a Comment