Tuesday, June 19, 2012

Failed to unlock all EM related accounts

This problem can occur if the default Profile settings have been modified and are no longer the "default" settings..

The following query will reveal the profile:

        SQL> select profile, resource_name, limit

        from dba_profiles

        where resource_type='PASSWORD' order by 1,2;
 
The default 10.2.0.1.0 profile for SYSMAN has the following parameters:

PROFILE...........RESOURCE_NAME................                LIMIT
-----------------------------------------------------------------------------------
DEFAULT...........FAILED_LOGIN_ATTEMPTS........    10
DEFAULT...........PASSWORD_GRACE_TIME..........    UNLIMITED
DEFAULT...........PASSWORD_LIFE_TIME...........         UNLIMITED
DEFAULT...........PASSWORD_LOCK_TIME...........      UNLIMITED
DEFAULT...........PASSWORD_REUSE_MAX.......... .    UNLIMITED
DEFAULT...........PASSWORD_REUSE_TIME.........       UNLIMITED
DEFAULT...........PASSWORD_VERIFY_FUNCTION.....NULL

DBSNMP uses the MONITORING_PROFILE, which is defined the same except for the FAILED_LOGIN_ATTEMPTS, which is set to UNLIMITED.
The failing instance, in one case, showed the following for the DEFAULT profile:

PROFILE...........RESOURCE_NAME........LIMIT
------------------------------ -------------------------------------------
DEFAULT...........FAILED_LOGIN_ATTEMPTS.........         4
DEFAULT...........PASSWORD_GRACE_TIME...........         1
DEFAULT...........PASSWORD_LIFE_TIME............             60
DEFAULT...........PASSWORD_LOCK_TIME........... .         0138
DEFAULT...........PASSWORD_REUSE_MAX............        100
DEFAULT...........PASSWORD_REUSE_TIME...........         UNLIMITED
DEFAULT...........PASSWORD_VERIFY_FUNCTION......  NULL

Solution :

1.  In SQL*Plus, logon as SYS and change DBSNMP's MONITORING_PROFILE, for example:

ALTER PROFILE MONITORING_PROFILE 

LIMIT FAILED_LOGIN_ATTEMPTS UNLIMITED 

PASSWORD_GRACE_TIME UNLIMITED

PASSWORD_LIFE_TIME UNLIMITED

PASSWORD_LOCK_TIME UNLIMITED

PASSWORD_REUSE_MAX UNLIMITED

PASSWORD_REUSE_TIME UNLIMITED

PASSWORD_VERIFY_FUNCTION NULL;

2.  Then modify SYSMAN's DEFAULT:

ALTER PROFILE DEFAULT 

LIMIT FAILED_LOGIN_ATTEMPTS 10 

PASSWORD_GRACE_TIME UNLIMITED

PASSWORD_LIFE_TIME UNLIMITED

PASSWORD_LOCK_TIME UNLIMITED

PASSWORD_REUSE_MAX UNLIMITED

PASSWORD_REUSE_TIME UNLIMITED

PASSWORD_VERIFY_FUNCTION NULL;

After this Drop with following Steps : 

 SQL> drop role mgmt_user;
SQL> drop user sysman cascade;
SQL> drop user MGMT_VIEW cascade;
SQL> drop public synonym mgmt_target_blackouts;
SQL> drop public synonym setemviewusercontext;

 -Recreate EM 

 emca -dbcontrol db -repos create ;

Thank you
Osama mustafa
 

4 comments:

  1. I tried following the above steps, but i got the same error again while recreating EM. "Failed to unlock all EM related components". I then checked the default and monitoring profile, it gave the values as expected. Please help.. I am trying to install Oracle 11g R2 on my laptop with Win 7 64-bit OS.

    ReplyDelete
    Replies
    1. Please check
      EMCA on RAC Fails with "SEVERE: FAILED TO UNLOCK ALL EM-RELATED ACCOUNTS" [ID 831224.1]

      Delete
  2. checked.. and followed the steps but didnt help.. My OS is Windows 7 Home Premium 64-bit. And since Oracle 11gR2 is not certified for home editions, i think there lies the problem.. Any idea?

    ReplyDelete
    Replies
    1. Home Edition ? Oracle is not certified with any home editions you need to install vmware software and choose certified OS

      Delete