IBM Support

Oracle populate osagents command fails with ORA-06512: at line 2

Technical Blog Post


Abstract

Oracle populate osagents command fails with ORA-06512: at line 2

Body

image

Oracle populate osagent command fails with ORA-06512: at line 2

If your site runs the Tivoli Data Warehouse, each time you install one or more monitoring agents, you must update the warehouse's ManagedSystem table, the populate_agents.sql script is provided for this purpose.

The details are in the manual here:

https://www.ibm.com/support/knowledgecenter/SSTFXA_6.3.0/com.ibm.itm.doc_6.3/install/tdwmngdsys.htm

However after the initial run of this script, if it is run again due to more agents being added,
on an Oracle database the following errors are sometimes seen:


POPULATE_OSAGENTS('ITMUSER');

  ERROR at line 1:
    ORA-00001: unique constraint (ITMUSER.IXMANAGEDSYSTEM) violated
    ORA-06512: at "ITMUSER.POPULATE_OSAGENTS", line 124
    ORA-06512: at "ITMUSER.POPULATE_OSAGENTS", line 143
    ORA-06512: at line 2

The result of this is the new agents are not added to the MANAGEDSYSTEM table.

This can be because the name of the tablespace is not correct.

When you run the setup_populate_agents.sql the tablespace name is required,
if this is not the correct tablespace name you will get the described behavior.

To fix this;

 
Drop the MANAGEDSYSTEM table

Then re-run the setup_populate_agents.sql with the current tablespace, this will then populate the table with all the agents.

  Start an SQL *Plus session if it is not already running.

        Create the ITMUSER.ManagedSystem table.

The script must be called by the Tivoli Data Warehouse user, which is ITMUSER by default.

If you used a different user name, modify the script for the correct name.


        @MY_PATH\create_table.sql

Create the procedure to populate the table:

        @MY_PATH\create_procedure.sql

 Start the procedure to populate the ManagedSystem table:

 begin

POPULATE_OSAGENTS('ITMUSER');

end;

To find out the current tablespace name, go into the Oracle Enterprise Management Console and see what tablespace name the ITMUser is using:

image

Tutorials Point

Subscribe and follow us for all the latest information directly on your Social feeds:

image

image

image

  

Check out all our other posts and updates:

Academy Blogs: https://goo.gl/U7cYYY
Academy Videos: https://goo.gl/TLfMoF
Academy Google+: https://goo.gl/HnTs0w
Academy Twitter : https://goo.gl/HnTs0w


image

[{"Business Unit":{"code":"BU053","label":"Cloud & Data Platform"},"Product":{"code":"","label":""},"Component":"","Platform":[{"code":"","label":""}],"Version":"","Edition":"","Line of Business":{"code":"","label":""}},{"Business Unit":{"code":"BU053","label":"Cloud & Data Platform"},"Product":{"code":"SSTFXA","label":"Tivoli Monitoring"},"Component":"","Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"All Versions","Edition":"","Line of Business":{"code":"LOB45","label":"Automation"}}]

UID

ibm11083255