ERROR:
After dropping and recreating the AWR, getting below error on creating snapshot.
SQL> exec dbms_workload_repository.create_snapshot;
BEGIN dbms_workload_repository.create_snapshot; END;
*
ERROR at line 1:
ORA-13518: Invalid database id (3834865236)
ORA-06512: at "SYS.DBMS_WORKLOAD_REPOSITORY", line 99
ORA-06512: at "SYS.DBMS_WORKLOAD_REPOSITORY", line 122
ORA-06512: at line 1
After dropping and recreating the AWR, getting below error on creating snapshot.
SQL> exec dbms_workload_repository.create_snapshot;
BEGIN dbms_workload_repository.create_snapshot; END;
*
ERROR at line 1:
ORA-13518: Invalid database id (3834865236)
ORA-06512: at "SYS.DBMS_WORKLOAD_REPOSITORY", line 99
ORA-06512: at "SYS.DBMS_WORKLOAD_REPOSITORY", line 122
ORA-06512: at line 1
Diag:
It looks there is no rows in WRM$_DATABASE_INSTANCE
SQL> select * from WRM$_DATABASE_INSTANCE ;
no rows selected
SQL>
Solution:
Restart the DB and check WRM$_DATABASE_INSTANCE table then run the snap.
SQL> shut immediate;
SQL> startup;
SQL> select DBID from WRM$_DATABASE_INSTANCE;
DBID
----------
XXXXXXX
SQL>
SQL> exec dbms_workload_repository.create_snapshot;
PL/SQL procedure successfully completed.
SQL>
1 comment:
Obrigado pelo post! Resolveu meu caso.
Post a Comment