Ora-1031 - emca -config dbcontrol db

Hi,
I had an instance that was running fine with a fully functioning EM installation.
We needed to move the database onto a different domain which meant that I needed to drop the repository and console and recreate them.
The repository recreated without issue, however, when I tried recreate the console, entering the same information, I get an ora-1031 insufficient privileges error.
I have looked on line for various solutions, but always hit the same error.
N.B. it is running on windows and I am running the command as the domain administrator.
any ideas?
Thanks.

Hi,
Resolved by following the forum post
Re: Enterprise Manager error
Thanks.
Edited by: cleme1a on Aug 12, 2012 11:07 PM

Similar Messages

  • Emca -config dbcontrol db -repos create -dbcontrol_http_port 1555

    Hi,
    I am openeing a new Thread for the same issue. Please help me to resolve this issue.
    Oracle:10.2.0.1.0
    OS:Windows XP SP2
    Net work adaptor: looback - 192.168.1.1
    C:\WINDOWS\system32\drivers\etc\hosts
    192.168.1.1 mcollinschoo-1.company.net mcollinschoo
    lsnrctl start listener
    C:\>lsnrctl start LISTENER
    LSNRCTL for 32-bit Windows: Version 10.2.0.1.0 - Production on 13-MAY-2009 11:31:24
    Copyright (c) 1991, 2005, Oracle. All rights reserved.
    Starting tnslsnr: please wait...
    TNSLSNR for 32-bit Windows: Version 10.2.0.1.0 - Production
    System parameter file is D:\oracle\product\10.2.0\db_1\network\admin\listener.ora
    Log messages written to D:\oracle\product\10.2.0\db_1\network\log\listener.log
    Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=mcollinschoo-1.asiapac.globalcsc.net)(PORT=1
    521)))
    Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=mcollinschoo)(PORT=1521)))
    STATUS of the LISTENER
    Alias LISTENER
    Version TNSLSNR for 32-bit Windows: Version 10.2.0.1.0 - Production
    Start Date 13-MAY-2009 11:31:27
    Uptime 0 days 0 hr. 0 min. 1 sec
    Trace Level off
    Security ON: Local OS Authentication
    SNMP OFF
    Listener Parameter File D:\oracle\product\10.2.0\db_1\network\admin\listener.ora
    Listener Log File D:\oracle\product\10.2.0\db_1\network\log\listener.log
    Listening Endpoints Summary...
    (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=mcollinschoo-1.company.net)(PORT=1521)))
    Services Summary...
    Service "SAM" has 1 instance(s).
    Instance "SAM", status UNKNOWN, has 1 handler(s) for this service...
    The command completed successfully
    Configuring dbconsole
    =================
    C:\>set ORACLE_HOME=D:\oracle\product\10.2.0\db_1
    C:\>set ORACLE_SID=SAM
    C:\>set ORACLE_HOSTNAME=mcollinschoo
    Also I have set ORACLE_HOSTNAME=mcollinschoo in environment variable settings.
    c:>emca -config dbcontrol db -repos create -dbcontrol_http_port 1555
    STARTED EMCA at May 13, 2009 11:32:51 AM
    EM Configuration Assistant, Version 10.2.0.1.0 Production
    Copyright (c) 2003, 2005, Oracle. All rights reserved.
    Enter the following information:
    Database SID: SAM
    Listener port number: 1521
    Password for SYS user:
    Password for DBSNMP user:
    Password for SYSMAN user:
    Email address for notifications (optional):
    Outgoing Mail (SMTP) server for notifications (optional):
    You have specified the following settings
    Database ORACLE_HOME ................ D:\oracle\product\10.2.0\db_1
    Database hostname ................ MCOLLINSCHOO
    Listener port number ................ 1521
    Database SID ................ SAM
    Email address for notifications ...............
    Outgoing Mail (SMTP) server for notifications ...............
    Do you wish to continue? [yes(Y)/no(N)]: y
    May 13, 2009 11:33:17 AM oracle.sysman.emcp.EMConfig perform
    INFO: This operation is being logged at D:\oracle\product\10.2.0\db_1\cfgtoollogs\emca\SAM\emca_2009
    -05-13_11-32-51-AM.log.
    May 13, 2009 11:33:20 AM oracle.sysman.emcp.EMReposConfig createRepository
    INFO: Creating the EM repository (this may take a while) ...
    May 13, 2009 11:35:02 AM oracle.sysman.emcp.EMReposConfig invoke
    INFO: Repository successfully created
    May 13, 2009 11:35:07 AM oracle.sysman.emcp.util.DBControlUtil startOMS
    INFO: Starting Database Control (this may take a while) ...
    May 13, 2009 11:40:07 AM oracle.sysman.emcp.EMConfig perform
    SEVERE: Error starting Database Control
    Refer to the log file at D:\oracle\product\10.2.0\db_1\cfgtoollogs\emca\SAM\emca_2009-05-13_11-32-51
    -AM.log for more details.
    Could not complete the configuration. Refer to the log file at D:\oracle\product\10.2.0\db_1\cfgtool
    logs\emca\SAM\emca_2009-05-13_11-32-51-AM.log for more details.
    End of emca_repos_create_2009-05-13_11-33-20-AM.log
    ======================================
    Commit complete.
    Registering target types
    Commit complete.
    Registering job types
    Create MGMT_VIEW user..
    No errors.
    No errors.
    Set repository version
    ============== End of creation ==============
    End of emca_2009-05-13_11-32-51-AM.log
    ============================
    CONFIG: Waiting for service 'OracleDBConsoleSAM' to fully start
    May 13, 2009 11:39:37 AM oracle.sysman.emcp.util.PlatformInterface serviceCommand
    CONFIG: Waiting for service 'OracleDBConsoleSAM' to fully start
    May 13, 2009 11:39:47 AM oracle.sysman.emcp.util.PlatformInterface serviceCommand
    CONFIG: Waiting for service 'OracleDBConsoleSAM' to fully start
    May 13, 2009 11:39:57 AM oracle.sysman.emcp.util.PlatformInterface serviceCommand
    CONFIG: Waiting for service 'OracleDBConsoleSAM' to fully start
    May 13, 2009 11:40:07 AM oracle.sysman.emcp.EMConfig perform
    SEVERE: Error starting Database Control
    Refer to the log file at D:\oracle\product\10.2.0\db_1\cfgtoollogs\emca\SAM\emca_2009-05-13_11-32-51-AM.log for more details.
    May 13, 2009 11:40:07 AM oracle.sysman.emcp.EMConfig perform
    CONFIG: Stack Trace:
    oracle.sysman.emcp.exception.EMConfigException: Error starting Database Control
         at oracle.sysman.emcp.EMDBPostConfig.performConfiguration(EMDBPostConfig.java:569)
         at oracle.sysman.emcp.EMDBPostConfig.invoke(EMDBPostConfig.java:181)
         at oracle.sysman.emcp.EMDBPostConfig.invoke(EMDBPostConfig.java:150)
         at oracle.sysman.emcp.EMConfig.perform(EMConfig.java:155)
         at oracle.sysman.emcp.EMConfigAssistant.invokeEMCA(EMConfigAssistant.java:479)
         at oracle.sysman.emcp.EMConfigAssistant.performConfiguration(EMConfigAssistant.java:1123)
         at oracle.sysman.emcp.EMConfigAssistant.statusMain(EMConfigAssistant.java:463)
         at oracle.sysman.emcp.EMConfigAssistant.main(EMConfigAssistant.java:412)
    Regards,
    Mat

    user505933 wrote:
    Hi,
    I am openeing a new Thread for the same issue. Please help me to resolve this issue.
    So why are you starting a new thread?
    <snip>
    May 13, 2009 11:40:07 AM oracle.sysman.emcp.EMConfig perform
    SEVERE: Error starting Database Control
    Refer to the log file at D:\oracle\product\10.2.0\db_1\cfgtoollogs\emca\SAM\emca_2009-05-13_11-32-51-AM.log for more details.<snip>
    >
    Regards,
    MatJust as before, what did you discover when you looked at
    Refer to the log file at D:\oracle\product\10.2.0\db_1\cfgtoollogs\emca\SAM\emca_2009-05-13_11-32-51-AM.log for more details.

  • Emca -config dbcontrol db fails with grid control error

    hi friends
    i am using oracle 11.2.0.2.0 in windows xp 32 bit
    while i was trying to config the EM with the command
    emca -config dbcontrol db
    i am getting the following error
    The existing database you have specified has Grid Control repository.This operation is not supported.
    what should i do as i tried everything like i stopped the gridcontrol services already
    with regards
    saugat

    Jul 28, 2011 6:23:23 PM oracle.sysman.emcp.EMReposConfig invoke
    INFO: Repository successfully dropped
    Jul 28, 2011 6:23:23 PM oracle.sysman.emcp.ParamsManager getHost
    CONFIG: Host having instnces running for database orcl : accessdba
    Jul 28, 2011 6:23:23 PM oracle.sysman.emcp.ParamsManager setParam
    CONFIG: Setting param: REP_DB_RUNNING_HOST value: accessdba
    Jul 28, 2011 6:23:23 PM oracle.sysman.emcp.ParamsManager getRepDbPort
    CONFIG: Listener Port: 1521
    Jul 28, 2011 6:23:23 PM oracle.sysman.emcp.util.GeneralUtil isLocalConnectionRequired
    CONFIG: isLocalConnectionRequired: true
    Jul 28, 2011 6:23:23 PM oracle.sysman.emcp.util.GeneralUtil initSQLEngine
    CONFIG: isLocalConnectionRequired: true. Connecting to database instance locally.
    Jul 28, 2011 6:23:23 PM oracle.sysman.emcp.util.GeneralUtil initSQLEngineLoacly
    CONFIG: SQLEngine connecting with SID: orcl, oracleHome: D:\app\saugat\product\11.2.0\dbhome_1, and user: SYS
    Jul 28, 2011 6:23:27 PM oracle.sysman.emcp.util.GeneralUtil initSQLEngineLoacly
    CONFIG: SQLEngine created successfully and connected
    Jul 28, 2011 6:23:27 PM oracle.sysman.emcp.EMReposConfig createRepository
    CONFIG: Spooling to D:\app\saugat\cfgtoollogs\emca\orcl\emca_repos_create_2011_07_28_18_23_27.log
    Jul 28, 2011 6:23:27 PM oracle.sysman.emcp.EMReposConfig createRepository
    INFO: Creating the EM repository (this may take a while) ...
    Jul 28, 2011 6:34:32 PM oracle.sysman.emcp.EMReposConfig createRepository
    WARNING: ORA-25153: Temporary Tablespace is Empty
    ORA-06512: at line 37
    Jul 28, 2011 6:34:32 PM oracle.sysman.emcp.EMReposConfig invoke
    SEVERE: Error creating the repository
    Jul 28, 2011 6:34:32 PM oracle.sysman.emcp.EMReposConfig invoke
    INFO: Refer to the log file at D:\app\saugat\cfgtoollogs\emca\orcl\emca_repos_create_<date>.log for more details.
    Jul 28, 2011 6:34:32 PM oracle.sysman.emcp.EMConfig perform
    SEVERE: Error creating the repository
    Refer to the log file at D:\app\saugat\cfgtoollogs\emca\orcl\emca_2011_07_28_18_15_19.log for more details.
    Jul 28, 2011 6:34:32 PM oracle.sysman.emcp.EMConfig perform
    CONFIG: Stack Trace:
    oracle.sysman.emcp.exception.EMConfigException: Error creating the repository
         at oracle.sysman.emcp.EMReposConfig.invoke(EMReposConfig.java:252)
         at oracle.sysman.emcp.EMReposConfig.invoke(EMReposConfig.java:160)
         at oracle.sysman.emcp.EMConfig.perform(EMConfig.java:253)
         at oracle.sysman.emcp.EMConfigAssistant.invokeEMCA(EMConfigAssistant.java:599)
         at oracle.sysman.emcp.EMConfigAssistant.performConfiguration(EMConfigAssistant.java:1482)
         at oracle.sysman.emcp.EMConfigAssistant.statusMain(EMConfigAssistant.java:583)
         at oracle.sysman.emcp.EMConfigAssistant.main(EMConfigAssistant.java:529)
    Jul 28, 2011 6:34:32 PM oracle.sysman.emcp.EMConfig restoreOuiLoc
    CONFIG: Restoring oracle.installer.oui_loc to D:\app\saugat\product\11.2.0\dbhome_1\oui
    it shows thaat temp tablespace is empty

  • ./emca -config dbcontrol db -repos create

    Hi,
    i would like to configure the EM and i get the following message
    Jul 20, 2010 10:37:19 AM oracle.sysman.emcp.EMConfig perform
    INFO: This operation is being logged at /oracle/db1/102_64/cfgtoollogs/emca/db1/emca_2010-07-20_10-36-36-AM.log.
    Jul 20, 2010 10:37:20 AM oracle.sysman.emcp.util.DBControlUtil stopOMS
    INFO: Stopping Database Control (this may take a while) ...
    Jul 20, 2010 10:37:23 AM oracle.sysman.emcp.EMReposConfig createRepository
    INFO: Creating the EM repository (this may take a while) ...
    Jul 20, 2010 10:37:23 AM oracle.sysman.emcp.EMReposConfig invoke
    SEVERE: Error creating the repository
    Jul 20, 2010 10:37:23 AM oracle.sysman.emcp.EMReposConfig invoke
    INFO: Refer to the log file at /oracle/db1/102_64/cfgtoollogs/emca/db1/emca_repos_create_<date>.log for more details.
    Jul 20, 2010 10:37:23 AM oracle.sysman.emcp.EMConfig perform
    SEVERE: Error creating the repository
    Refer to the log file at /oracle/db1/102_64/cfgtoollogs/emca/db1/emca_2010-07-20_10-36-36-AM.log for more details.
    Could not complete the configuration. Refer to the log file at /oracle/db1/102_64/cfgtoollogs/emca/db1/emca_2010-07-20_10-36-36-AM.log for more details.
    Can anybody help me
    Thanks

    aix014:oradb1 43> ./emca -config dbcontrol db -repos recreate
    STARTED EMCA at Jul 20, 2010 12:51:53 PM
    EM Configuration Assistant, Version 10.2.0.1.0 Production
    Copyright (c) 2003, 2005, Oracle. All rights reserved.
    Enter the following information:
    Database SID: db1
    Database Control is already configured for the database db1
    You have chosen to configure Database Control for managing the database db1
    This will remove the existing configuration and the default settings and perform a fresh configuration
    Do you wish to continue? [yes(Y)/no(N)]: y
    Listener port number: 1563
    Password for SYS user:
    Password for DBSNMP user:
    Password for SYSMAN user:
    Email address for notifications (optional):
    Outgoing Mail (SMTP) server for notifications (optional):
    You have specified the following settings
    Database ORACLE_HOME ................ /oracle/db1/102_64
    Database hostname ................ aix014
    Listener port number ................ 1563
    Database SID ................ db1
    Email address for notifications ...............
    Outgoing Mail (SMTP) server for notifications ...............
    Do you wish to continue? [yes(Y)/no(N)]: y
    Jul 20, 2010 12:52:22 PM oracle.sysman.emcp.EMConfig perform
    INFO: This operation is being logged at /oracle/db1/102_64/cfgtoollogs/emca/db1/emca_2010-07-20_12-51-53-PM.log.
    Jul 20, 2010 12:52:24 PM oracle.sysman.emcp.util.DBControlUtil stopOMS
    INFO: Stopping Database Control (this may take a while) ...
    Jul 20, 2010 12:52:27 PM oracle.sysman.emcp.EMReposConfig dropRepository
    INFO: Dropping the EM repository (this may take a while) ...
    Jul 20, 2010 12:52:27 PM oracle.sysman.emcp.util.PlatformInterface executeCommand
    WARNING: Error executing /oracle/db1/102_64/sysman/admin/emdrep/bin/RepManager -connect (DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=aix014)(PORT=1563)))(CONNECT_DATA=(SERVICE_NAME=db1))) -repos_user SYSMAN -action drop -verbose -output_file /oracle/db1/102_64/cfgtoollogs/emca/db1/emca_repos_drop_2010-07-20_12-52-27-PM.log
    Jul 20, 2010 12:52:27 PM oracle.sysman.emcp.EMReposConfig invoke
    SEVERE: Error dropping the repository
    Jul 20, 2010 12:52:27 PM oracle.sysman.emcp.EMReposConfig invoke
    INFO: Refer to the log file at /oracle/db1/102_64/cfgtoollogs/emca/db1/emca_repos_drop_<date>.log for more details.
    Jul 20, 2010 12:52:27 PM oracle.sysman.emcp.EMConfig perform
    SEVERE: Error dropping the repository
    Refer to the log file at /oracle/db1/102_64/cfgtoollogs/emca/db1/emca_2010-07-20_12-51-53-PM.log for more details.
    Could not complete the configuration. Refer to the log file at /oracle/db1/102_64/cfgtoollogs/emca/db1/emca_2010-07-20_12-51-53-PM.log for more details.
    aix014:oradb1 44> more /oracle/db1/102_64/cfgtoollogs/emca/db1/emca_repos_drop_2010-07-20_12-52-27-PM.log
    [20-07-2010 12:52:27] Enter SYS user's password :
    [20-07-2010 12:52:27]
    [20-07-2010 12:52:27] Enter repository user password :
    [20-07-2010 12:52:27]
    [20-07-2010 12:52:27] Getting temporary tablespace from database...
    [20-07-2010 12:52:27] Could not connect to SYS/(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=aix014)(PORT=156
    3)))(CONNECT_DATA=(SERVICE_NAME=db1))): ORA-12541: TNS:no listener (DBD ERROR: OCIServerAttach)
    lsnrctl status seem as follow
    aix014:oradb1 45> lsnrctl status
    LSNRCTL for IBM/AIX RISC System/6000: Version 10.2.0.4.0 - Production on 20-JUL-2010 12:54:55
    Copyright (c) 1991, 2007, Oracle. All rights reserved.
    Connecting to (ADDRESS=(PROTOCOL=IPC)(KEY=db1.WORLD))
    STATUS of the LISTENER
    Alias LISTENER
    Version TNSLSNR for IBM/AIX RISC System/6000: Version 10.2.0.4.0 - Production
    Start Date 19-JUL-2010 14:40:24
    Uptime 0 days 22 hr. 14 min. 30 sec
    Trace Level off
    Security ON: Local OS Authentication
    SNMP ON
    Listener Parameter File /oracle/db1/102_64/network/admin/listener.ora
    Listener Log File /oracle/db1/102_64/network/log/listener.log
    Listening Endpoints Summary...
    (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=db1.WORLD)))
    (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=db1)))
    (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=172.16.8.167)(PORT=1563)))
    Services Summary...
    Service "db1" has 2 instance(s).
    Instance "db1", status UNKNOWN, has 1 handler(s) for this service...
    Instance "db1", status READY, has 1 handler(s) for this service...
    Service "db1_XPT" has 1 instance(s).
    Instance "db1", status READY, has 1 handler(s) for this service...
    The command completed successfully
    log file at /oracle/db1/102_64/cfgtoollogs/emca/db1/emca_repos_drop_<date>.log:
    aix014:oradb1 43> more emca_repos_drop_2010-07-20_12-52-27-PM.log
    [20-07-2010 12:52:27] Enter SYS user's password :
    [20-07-2010 12:52:27]
    [20-07-2010 12:52:27] Enter repository user password :
    [20-07-2010 12:52:27]
    [20-07-2010 12:52:27] Getting temporary tablespace from database...
    [20-07-2010 12:52:27] Could not connect to SYS/(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=aix01
    4)(PORT=1563)))(CONNECT_DATA=(SERVICE_NAME=db1))): ORA-12541: TNS:no listener (DBD ERROR: OCIServerAttach)
    more emca_2010-07-20_12-51-53-PM.log
    Jul 20, 2010 12:52:27 PM oracle.sysman.emcp.util.PlatformInterface executeCommand
    WARNING: Error executing /oracle/db1/102_64/sysman/admin/emdrep/bin/RepManager -connect (DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=aix01
    4)(PORT=1563)))(CONNECT_DATA=(SERVICE_NAME=db1))) -repos_user SYSMAN -action drop -verbose -output_file /oracle/db1/102_64/cfgtoollogs/emca/db1/emca_rep
    os_drop_2010-07-20_12-52-27-PM.log
    Jul 20, 2010 12:52:27 PM oracle.sysman.emcp.EMReposConfig invoke
    SEVERE: Error dropping the repository
    Jul 20, 2010 12:52:27 PM oracle.sysman.emcp.EMReposConfig invoke
    INFO: Refer to the log file at /oracle/db1/102_64/cfgtoollogs/emca/db1/emca_repos_drop_<date>.log for more details.
    Jul 20, 2010 12:52:27 PM oracle.sysman.emcp.EMConfig perform
    SEVERE: Error dropping the repository
    Refer to the log file at /oracle/db1/102_64/cfgtoollogs/emca/db1/emca_2010-07-20_12-51-53-PM.log for more details.
    Jul 20, 2010 12:52:27 PM oracle.sysman.emcp.EMConfig perform
    CONFIG: Stack Trace:
    oracle.sysman.emcp.exception.EMConfigException: Error dropping the repository
    at oracle.sysman.emcp.EMReposConfig.invoke(EMReposConfig.java:183)
    at oracle.sysman.emcp.EMReposConfig.invoke(EMReposConfig.java:134)
    at oracle.sysman.emcp.EMConfig.perform(EMConfig.java:171)
    at oracle.sysman.emcp.EMConfigAssistant.invokeEMCA(EMConfigAssistant.java:486)
    at oracle.sysman.emcp.EMConfigAssistant.performConfiguration(EMConfigAssistant.java:1142)
    at oracle.sysman.emcp.EMConfigAssistant.statusMain(EMConfigAssistant.java:470)
    at oracle.sysman.emcp.EMConfigAssistant.main(EMConfigAssistant.java:419)
    ...skipping...
    Jul 20, 2010 12:52:27 PM oracle.sysman.emcp.util.PlatformInterface executeCommand
    WARNING: Error executing /oracle/db1/102_64/sysman/admin/emdrep/bin/RepManager -connect (DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=aix014)(
    PORT=1563)))(CONNECT_DATA=(SERVICE_NAME=db1))) -repos_user SYSMAN -action drop -verbose -output_file /oracle/db1/102_64/cfgtoollogs/emca/db1/emca_repos_dro
    p_2010-07-20_12-52-27-PM.log
    Jul 20, 2010 12:52:27 PM oracle.sysman.emcp.EMReposConfig invoke
    SEVERE: Error dropping the repository
    Jul 20, 2010 12:52:27 PM oracle.sysman.emcp.EMReposConfig invoke
    INFO: Refer to the log file at /oracle/db1/102_64/cfgtoollogs/emca/db1/emca_repos_drop_<date>.log for more details.
    Jul 20, 2010 12:52:27 PM oracle.sysman.emcp.EMConfig perform
    SEVERE: Error dropping the repository
    Refer to the log file at /oracle/db1/102_64/cfgtoollogs/emca/db1/emca_2010-07-20_12-51-53-PM.log for more details.
    Jul 20, 2010 12:52:27 PM oracle.sysman.emcp.EMConfig perform
    CONFIG: Stack Trace:
    oracle.sysman.emcp.exception.EMConfigException: Error dropping the repository
    at oracle.sysman.emcp.EMReposConfig.invoke(EMReposConfig.java:183)
    at oracle.sysman.emcp.EMReposConfig.invoke(EMReposConfig.java:134)
    at oracle.sysman.emcp.EMConfig.perform(EMConfig.java:171)
    at oracle.sysman.emcp.EMConfigAssistant.invokeEMCA(EMConfigAssistant.java:486)
    at oracle.sysman.emcp.EMConfigAssistant.performConfiguration(EMConfigAssistant.java:1142)
    at oracle.sysman.emcp.EMConfigAssistant.statusMain(EMConfigAssistant.java:470)
    at oracle.sysman.emcp.EMConfigAssistant.main(EMConfigAssistant.java:419)

  • Emca -config dbcontrol db  -repos create problem

    Hello,
    I have created database on Windows Server 2008, 11g R2 64 bit. Everything went good, but it didn't create the EM console.
    I drop the repository console and tried to create it again, but, I got this error:
    C:\Windows\system32>emca -config dbcontrol db -repos create -SID SPKDB -PORT 1521 -ORACLE_HOME C:\Or
    acle\Ora11g\dbhome_1
    STARTED EMCA at 2011.02.03 16:21:15
    EM Configuration Assistant, Version 11.2.0.0.2 Production
    Copyright (c) 2003, 2005, Oracle. All rights reserved.
    Enter the following information:
    Exception in thread "main" oracle.sysman.emcp.exception.DatabaseUnavailableException: Database insta
    nce unavailable.
    at oracle.sysman.emcp.DatabaseChecks.throwDBUnavailableException(DatabaseChecks.java:151)
    at oracle.sysman.emcp.DatabaseChecks.checkDbAvailabilityImpl(DatabaseChecks.java:144)
    at oracle.sysman.emcp.DatabaseChecks.checkDbAvailability(DatabaseChecks.java:163)
    at oracle.sysman.emcp.DatabaseChecks.getDbServiceName(DatabaseChecks.java:582)
    at oracle.sysman.emcp.EMConfigAssistant.performConfiguration(EMConfigAssistant.java:1272)
    at oracle.sysman.emcp.EMConfigAssistant.statusMain(EMConfigAssistant.java:574)
    at oracle.sysman.emcp.EMConfigAssistant.main(EMConfigAssistant.java:522)
    Listener is UP.
    Database service is up.
    Did anybody have the same problem?
    Regards,
    E.

    C:\Windows\system32>lsnrctl status
    LSNRCTL for 64-bit Windows: Version 11.2.0.1.0 - Production on 03-VEL-2011 16:47:43
    Copyright (c) 1991, 2010, Oracle. All rights reserved.
    Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=server12)(PORT=1521)))
    STATUS of the LISTENER
    Alias LISTENER
    Version TNSLSNR for 64-bit Windows: Version 11.2.0.1.0 - Production
    Start Date 03-VEL-2011 14:01:56
    Uptime 0 days 2 hr. 45 min. 51 sec
    Trace Level off
    Security ON: Local OS Authentication
    SNMP OFF
    Listener Parameter File C:\Oracle\Ora11g\dbhome_1\NETWORK\ADMIN\listener.ora
    Listener Log File c:\oracle\diag\tnslsnr\server12\listener\alert\log.xml
    Listening Endpoints Summary...
    (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=server12)(PORT=1521)))
    (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(PIPENAME=\\.\pipe\EXTPROC1521ipc)))
    (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=server12)(PORT=8080))(Presentation=HTTP)(Session=RAW))
    Services Summary...
    Service "CLRExtProc" has 1 instance(s).
    Instance "CLRExtProc", status UNKNOWN, has 3 handler(s) for this service...
    Service "spkdb" has 1 instance(s).
    Instance "spkdb", status READY, has 1 handler(s) for this service...
    Service "spkdbXDB" has 1 instance(s).
    Instance "spkdb", status READY, has 1 handler(s) for this service...
    The command completed successfully
    C:\Windows\system32>lsnrctl service
    LSNRCTL for 64-bit Windows: Version 11.2.0.1.0 - Production on 03-VEL-2011 16:48:01
    Copyright (c) 1991, 2010, Oracle. All rights reserved.
    Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=server12)(PORT=1521)))
    Services Summary...
    Service "CLRExtProc" has 1 instance(s).
    Instance "CLRExtProc", status UNKNOWN, has 3 handler(s) for this service...
    Handler(s):
    "DEDICATED" established:0 refused:0
    LOCAL SERVER
    "DEDICATED" established:0 refused:0
    LOCAL SERVER
    "DEDICATED" established:0 refused:0
    LOCAL SERVER
    Service "spkdb" has 1 instance(s).
    Instance "spkdb", status READY, has 1 handler(s) for this service...
    Handler(s):
    "DEDICATED" established:47 refused:0 state:ready
    LOCAL SERVER
    Service "spkdbXDB" has 1 instance(s).
    Instance "spkdb", status READY, has 1 handler(s) for this service...
    Handler(s):
    "D000" established:278 refused:0 current:3 max:1022 state:ready
    DISPATCHER <machine: SERVER12, pid: 2244>
    (ADDRESS=(PROTOCOL=tcp)(HOST=server12)(PORT=58758))
    The command completed successfully
    C:\Windows\system32>

  • Emca -config dbcontrol db + Can't find file emoms.properties

    HI,
    Recently we upgradated the database from oracle 11.2.0 to 11.2.0.3 afte that i am unable to start the oem
    now i am configuring the dbcontrol by the following command:
    emca -config dbcontrol db
    but getting the error
    Please enter repository password:
    Exception caught
    Feb 13, 2013 12:04:54 PM oracle.sysman.emcp.util.PlatformInterface executeCommandExitValue
    CONFIG: stty: standard input: Invalid argument
    stty: standard input: Invalid argument
    Can't find file /orahome/oracle/product/11.2.0.3/db_1/youtele_pindb/sysman/config/emoms.properties
    java.lang.IllegalStateException: Can't find file /orahome/oracle/product/11.2.0.3/db_1/youtele_pindb/sysman/config/emoms.properties
            at oracle.sysman.emSDK.conf.ConfigManager.processProperties(ConfigManager.java:1154)
            at oracle.sysman.emSDK.conf.ConfigManager.processProperties(ConfigManager.java:1127)
            at oracle.sysman.eml.sec.rep.EmKeyUtil.<init>(EmKeyUtil.java:111)
            at oracle.sysman.eml.sec.rep.EmKeyUtil.main(EmKeyUtil.java:507)
    log4j:WARN No appenders could be found for logger (sec.rep.EmKeyUtil).
    log4j:WARN Please initialize the log4j system properly.
    Feb 13, 2013 12:04:54 PM oracle.sysman.emcp.util.DBControlUtil copyEmkeyToRepos
    SEVERE: Error copying Em Key to Management Repository. The Em Key is not configured properly or is corrupted in the file system and does not exist in the Management Repository. To correct the problem:
    1) Copy the emkey.ora file from another OMS or backup machine to the /orahome/oracle/product/11.2.0.3/db_1/sysman/config and run following commands:
    i) /orahome/oracle/product/11.2.0.3/db_1/bin/emctl config emkey -emkeyfile /orahome/oracle/product/11.2.0.3/db_1/sysman/config/emkey.ora  -force
    ii) /orahome/oracle/product/11.2.0.3/db_1/bin/emctl  config emkey -copy_to_repos
    iii) Run EM Configuration Assistant again
    2) If emkey.ora is not available from backup, run /orahome/oracle/product/11.2.0.3/db_1/bin/emca with -repos create optionAppreciated inputs on the above errors
    Thanks

    actually the above error provide with solutions also.

  • Error running emca -config dbcontrol db -repos create

    G:\app\testuser\product\11.2.0\dbhome_1\bin>emca -deconfig dbcontrol db
    STARTED EMCA at 13-Sep-2012 11:12:40
    EM Configuration Assistant, Version 11.2.0.3.0 Production
    Copyright (c) 2003, 2011, Oracle. All rights reserved.
    Enter the following information:
    Database SID: TESTDATA
    Do you wish to continue? [yes(Y)/no(N)]: Y
    13-Sep-2012 11:12:46 oracle.sysman.emcp.util.GeneralUtil initSQLEngineLoacly
    WARNING: ORA-01031: insufficient privileges
    13-Sep-2012 11:12:46 oracle.sysman.emcp.DatabaseChecks throwDBUnavailableException
    SEVERE:
    Database instance is unavailable. Fix the ORA error thrown and run EM Configuration Assistant again.
    Some of the possible reasons may be :
    1) Database may not be up.
    2) Database is started setting environment variable ORACLE_HOME with trailing '/'. Reset ORACLE_HOME
    and bounce the database.
    For eg. Database is started setting environment variable ORACLE_HOME=/scratch/db/ . Reset ORACLE_HOM
    E=/scratch/db and bounce the database.
    G:\app\testuser\product\11.2.0\dbhome_1\bin>cd ..
    G:\app\testuser\product\11.2.0\dbhome_1\install>emca -config dbcontrol db -repos create
    STARTED EMCA at 13-Sep-2012 11:16:05
    EM Configuration Assistant, Version 11.2.0.3.0 Production
    Copyright (c) 2003, 2011, Oracle. All rights reserved.
    Enter the following information:
    Database SID: TESTDATA
    Exception in thread "main" java.lang.NoClassDefFoundError: HTTPClient/ProtocolNotSuppException
    at oracle.sysman.emd.targetIntg.agent.AgentTargetInstaller.<clinit>(AgentTargetInstaller.jav
    a:235)
    at oracle.sysman.emcp.target.TargetManager.getAgentTargetInstaller(TargetManager.java:1074)
    at oracle.sysman.emcp.target.TargetManager.getLocalHost(TargetManager.java:1099)
    at oracle.sysman.emcp.ParamsManager.getLocalHost(ParamsManager.java:1043)
    at oracle.sysman.emcp.ParamsManager.getHost(ParamsManager.java:3076)
    at oracle.sysman.emcp.DatabaseChecks.checkDbAvailabilityImpl(DatabaseChecks.java:124)
    at oracle.sysman.emcp.DatabaseChecks.checkDbAvailability(DatabaseChecks.java:178)
    at oracle.sysman.emcp.DatabaseChecks.getDbServiceName(DatabaseChecks.java:692)
    at oracle.sysman.emcp.EMConfigAssistant.performConfiguration(EMConfigAssistant.java:1292)
    at oracle.sysman.emcp.EMConfigAssistant.statusMain(EMConfigAssistant.java:583)
    at oracle.sysman.emcp.EMConfigAssistant.main(EMConfigAssistant.java:529)
    G:\app\testuser\product\11.2.0\dbhome_1\install>
    I have set the oracle_home and oracle_sid

    13-Sep-2012 11:12:46 oracle.sysman.emcp.util.GeneralUtil initSQLEngineLoacly
    WARNING: ORA-01031: insufficient privileges
    13-Sep-2012 11:12:46 oracle.sysman.emcp.DatabaseChecks throwDBUnavailableException
    SEVERE:
    Database instance is unavailable. Fix the ORA error thrown and run EM Configuration Assistant again.The Errors says it all, make sure your db is up and running and the ORACLE_SID and ORACLE_HOME is set to correct SID and PATH.
    ref doc : How To Drop, Create And Recreate DB Control In A 10g/11g Database [ID 278100.1]
    Edited by: Veeresh.S on Sep 13, 2012 4:04 PM

  • An issue in "emca -config dbcontrol db -repos create"

    Hi All,
    Collected following data from log file, log file is generated when trying to run "emca -config dbcontrol db -repos create" from command mode
    Aug 13, 2009 9:00:01 PM oracle.sysman.emcp.util.PlatformInterface executeCommand
    CONFIG: '\regedit.exe' is not recognized as an internal or external command,
    operable program or batch file.
    Creating registry entries failed. Aborting...
    what is an error and unable to bring up EM due to same issue.
    Log file in detail,
    C:\ORACLE\PRODUCT>emca -config dbcontrol db -repos create
    STARTED EMCA at Aug 17, 2009 10:48:26 PM
    EM Configuration Assistant, Version 10.2.0.1.0 Production
    Copyright (c) 2003, 2005, Oracle. All rights reserved.
    Enter the following information:
    Database SID: RADHA
    Listener port number: 1521
    Password for SYS user:
    Password for DBSNMP user:
    Password for SYSMAN user:
    Password for SYSMAN user: Email address for notifications (optional):
    Outgoing Mail (SMTP) server for notifications (optional):
    You have specified the following settings
    Database ORACLE_HOME ................ C:\oracle\product\10.2.0\db_1
    Database hostname ................ AsishChowdary
    Listener port number ................ 1521
    Database SID ................ RADHA
    Email address for notifications ...............
    Outgoing Mail (SMTP) server for notifications ...............
    Do you wish to continue? [yes(Y)/no(N)]: Y
    Aug 17, 2009 10:48:58 PM oracle.sysman.emcp.EMConfig perform
    INFO: This operation is being logged at C:\oracle\product\10.2.0\db_1\cfgtool
    s\emca\RADHA\emca_2009-08-17_10-48-26-PM.log.
    Aug 17, 2009 10:49:01 PM oracle.sysman.emcp.EMReposConfig createRepository
    INFO: Creating the EM repository (this may take a while) ...
    Aug 17, 2009 10:51:27 PM oracle.sysman.emcp.EMReposConfig invoke
    INFO: Repository successfully created
    Aug 17, 2009 10:51:34 PM oracle.sysman.emcp.util.PlatformInterface executeCom
    d
    WARNING: Error executing CMD /C C:\oracle\product\10.2.0\db_1\bin\emctl.bat d
    oy dbconsole C:\oracle\product\10.2.0\db_1\AsishChowdary_RADHA AsishChowdary:
    8 AsishChowdary RADHA
    Aug 17, 2009 10:51:34 PM oracle.sysman.emcp.EMConfig perform
    SEVERE: Error instantiating EM configuration files
    Refer to the log file at C:\oracle\product\10.2.0\db_1\cfgtoollogs\emca\RADHA
    ca_2009-08-17_10-48-26-PM.log for more details.
    Could not complete the configuration. Refer to the log file at C:\oracle\prod
    \10.2.0\db_1\cfgtoollogs\emca\RADHA\emca_2009-08-17_10-48-26-PM.log for more
    ails.
    Edited by: user7511349 on Aug 17, 2009 10:33 AM

    user7511349 wrote:
    Hi,
    Noticed following an error when executed from command mode regedit
    regedit.exe' is not recognized as an internal or external command.
    do have any solution.Get a good antivirus and scan the entire system. Make sure you backup your important data first (including database) and hope there is no corruption.
    You could try copying regedit.exe from another server and see if it helps in first place. But in any case, I would suggest you take a backup of your system.

  • Doing emca -config dbcontrol db -repos recreate

    hello,
    I'm doing the following:
    emca -config dbcontrol db -repos recreate
    but on the process I'm getting the following warnings:
    27-may-2010 14:48:31 oracle.sysman.emcp.util.PortManager isPortInUse
    WANING: port 5540 is in use
    27-may-2010 14:48:31 oracle.sysman.emcp.util.PortManager isPortInUse
    WANING: port 5520 is in use
    27-may-2010 14:48:31 oracle.sysman.emcp.util.PortManager isPortInUse
    WANING: port 1158 is in use
    27-may-2010 14:48:31 oracle.sysman.emcp.util.PortManager isPortInUse
    WANING: port 3938 is in use
    27-may-2010 14:48:31 oracle.sysman.emcp.util.DBControlUtil stopOMS
    INFO: Stopping Database Control. Can be some minutes...
    27-may-2010 14:48:37 oracle.sysman.emcp.EMReposConfig dropRepository
    INFO: Dropping the repository of EM. Can be some minutes...
    should I have to stop the process, check why are in use the ports, and changed those ports in use?
    Somebody can help me, please?
    Regards,
    Bea.

    I've check and is the following:
    [27-05-2010 14:48:39] Enter SYS user's password :
    [27-05-2010 14:48:39]
    [27-05-2010 14:48:39] Enter repository user password :
    [27-05-2010 14:48:40]
    [27-05-2010 14:48:40] Getting temporary tablespace from database...
    [27-05-2010 14:48:40] Found temporary tablespace: TEMP2
    [27-05-2010 14:48:40] Environment :
    [27-05-2010 14:48:40] ORACLE HOME = E:\oracle\product\10.2.0\db_1
    [27-05-2010 14:48:40] SQLPLUS = E:\oracle\product\10.2.0\db_1/bin/sqlplus
    [27-05-2010 14:48:40] EXPORT = E:\oracle\product\10.2.0\db_1/bin/exp
    [27-05-2010 14:48:40] IMPORT = E:\oracle\product\10.2.0\db_1/bin/imp
    [27-05-2010 14:48:40] LOADJAVA = E:\oracle\product\10.2.0\db_1/bin/loadjava
    [27-05-2010 14:48:40] Arguments :
    [27-05-2010 14:48:40] Connect String = (DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=coolcsenew.solmelia.corp)(PORT=1521)))(CONNECT_DATA=(SERVICE_NAME=ENCYNEW)))
    [27-05-2010 14:48:40] Script Home = E:\oracle\product\10.2.0\db_1
    [27-05-2010 14:48:40] SQL SCRIPT ROOT = E:\oracle\product\10.2.0\db_1/sysman/admin/emdrep/sql
    [27-05-2010 14:48:40] JAR FILE ROOT = E:\oracle\product\10.2.0\db_1/sysman/admin/emdrep/lib
    [27-05-2010 14:48:40] JOB TYPES ROOT = E:\oracle\product\10.2.0\db_1/sysman/admin/emdrep/bin
    [27-05-2010 14:48:40] Action = drop
    [27-05-2010 14:48:40] Repos User = SYSMAN
    [27-05-2010 14:48:40] Default tablespace = MGMT_TABLESPACE
    [27-05-2010 14:48:40] Default Data file = mgmt.dbf
    [27-05-2010 14:48:40] Dflt Dfile Init size = 20m
    [27-05-2010 14:48:40] Dflt Dfile Ext size = 20m
    [27-05-2010 14:48:40] ECM tablespace = MGMT_ECM_DEPOT_TS
    [27-05-2010 14:48:40] ECM Data file = mgmt_ecm_depot1.dbf
    [27-05-2010 14:48:40] ECM Dfile Init size = 100m
    [27-05-2010 14:48:40] ECM Dfile Ext size = 100m
    [27-05-2010 14:48:40] TEMP tablespace = TEMP2
    [27-05-2010 14:48:40] Create options = 3
    [27-05-2010 14:48:40] Verbose output = 1
    [27-05-2010 14:48:40] Output File = E:\oracle\product\10.2.0\db_1\cfgtoollogs\emca\ENCYNEW\emca_repos_drop_2010-05-27_02-48-37-PM.log
    [27-05-2010 14:48:40] Repos creation mode = CENTRAL
    [27-05-2010 14:48:40] MetaLink user name = NOTAVAILABLE_
    [27-05-2010 14:48:40] MetaLink URL = http://updates.oracle.com
    [27-05-2010 14:48:40] Export Directory = E:\oracle\product\10.2.0\db_1/sysman/log
    [27-05-2010 14:48:40] Import Directory = E:\oracle\product\10.2.0\db_1/sysman/log
    [27-05-2010 14:48:40] Checking SYS Credentials ...
    [27-05-2010 14:48:40] File - D:\Temp\7A0it518wq\ksEQ0a1Oqf.sql.
    SQL*Plus: Release 10.2.0.4.0 - Production on Thu May 27 14:48:41 2010
    Copyright (c) 1982, 2007, Oracle. All Rights Reserved.
    Enter user-name:
    Connected to:
    Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - Production
    With the Partitioning, OLAP, Data Mining and Real Application Testing options
    SQL> SQL> SQL> Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - Production
    With the Partitioning, OLAP, Data Mining and Real Application Testing options
    [27-05-2010 14:48:42] Return code = 0.
    [27-05-2010 14:48:42] OK.
    [27-05-2010 14:48:42] Dropping the repository..
    [27-05-2010 14:48:42] Quiescing DB ...
    [27-05-2010 14:48:42] File - D:\Temp\lguthWQwBy\yizlkHewMw.sql.
    [27-05-2010 14:48:58] Return code = 0.
    [27-05-2010 14:48:58] Done.
    [27-05-2010 14:48:58] Checking for Repos User ...
    [27-05-2010 14:48:58] File - D:\Temp\2bwoIjXoS8\mmZSYktShc.sql.
    [27-05-2010 14:48:59] Return code = 0.
    [27-05-2010 14:48:59] Exists.
    [27-05-2010 14:48:59] Repos User exists..
    [27-05-2010 14:48:59] Clearing EM Contexts ...
    [27-05-2010 14:48:59] Clearing contexts. File - D:\Temp\vPfpjgrlXm\uqrPLwC8ww.sql.
    SQL*Plus: Release 10.2.0.4.0 - Production on Thu May 27 14:48:59 2010
    Copyright (c) 1982, 2007, Oracle. All Rights Reserved.
    Enter user-name:
    Connected to:
    Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - Production
    With the Partitioning, OLAP, Data Mining and Real Application Testing options
    SQL> SQL> SQL> SQL> SQL>
    PL/SQL procedure successfully completed.
    SQL> Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - Production
    With the Partitioning, OLAP, Data Mining and Real Application Testing options
    [27-05-2010 14:49:01] Clearing contexts. Return code = 0.
    [27-05-2010 14:49:01] OK.
    [27-05-2010 14:49:01] Dropping EM users ...
    [27-05-2010 14:49:01] Drop EM Users. File - D:\Temp\d6TFHQp0to\JnneBa8hCr.sql.
    SQL*Plus: Release 10.2.0.4.0 - Production on Thu May 27 14:49:02 2010
    Copyright (c) 1982, 2007, Oracle. All Rights Reserved.
    Enter user-name:
    Connected to:
    Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - Production
    With the Partitioning, OLAP, Data Mining and Real Application Testing options
    SQL> SQL> SQL> SQL> SQL> SQL> SQL> Rem
    SQL> Rem $Header: admin_drop_users.sql 26-mar-2003.12:48:27 rpinnama Exp $
    SQL> Rem
    SQL> Rem admin_drop_users.sql
    SQL> Rem
    SQL> Rem Copyright (c) 2002, 2003, Oracle Corporation.     All rights reserved.
    SQL> Rem
    SQL> Rem NAME
    SQL> Rem     admin_drop_users.sql - <one-line expansion of the name>
    SQL> Rem
    SQL> Rem DESCRIPTION
    SQL> Rem     <short description of component this file declares/defines>
    SQL> Rem
    SQL> Rem NOTES
    SQL> Rem     <other useful comments, qualifications, etc.>
    SQL> Rem
    SQL> Rem MODIFIED (MM/DD/YY)
    SQL> Rem rpinnama     03/26/03 - Remove references to DropRep
    SQL> Rem rpinnama     03/25/03 - Parameterize repos user
    SQL> Rem rpinnama     06/03/02 - rpinnama_reorg_rep_scripts_3
    SQL> Rem rpinnama     05/20/02 - Created
    SQL> Rem
    SQL>
    SQL> Rem
    SQL> Rem This SQL script requires the following arguments
    SQL> Rem 1. Name of the repository user
    SQL> Rem
    SQL> DEFINE EM_REPOS_USER ="&1"
    SQL>
    SQL>
    SQL>
    SQL> Rem Generate Drop users script
    SQL> Rem Error 1918 is received if the repository user does not exist - we simply exit and continue
    SQL> Rem Error 1940 is received if there is an active session - we continue the loop
    SQL> Rem Error 30 is received if the session we are killing no longer exists - we continue the loop
    SQL> Rem NOTE:     The 1940 will be returned until the other end of the session re-accesses it.
    SQL> Rem     This may take up to several minutes, so we ignore these errors completely.
    SQL> Rem     If we trace in this loop, we will exit with a buffer overflow,
    SQL> Rem     so tracing is not done in this loop
    SQL>
    SQL>
    SQL> declare
    2 l_username varchar2(30);
    3 l_sid number;
    4 l_serial number;
    5 err number;
    6 c number;
    7 begin
    8
    9      -- First, drop all users, except SYSMAN who have MGMT_USER role and
    10      -- are created by EM. All users created by EM will have a record
    11      -- in MGMT_CREATED_USERS table
    12      --
    13      c := 0;
    14      begin
    15      loop
    16      BEGIN
    17      l_username := '';
    18      select grantee into l_username
    19           from sys.dba_role_privs
    20           where granted_role = 'MGMT_USER'
    21           AND grantee IN (SELECT user_name
    22                     FROM &EM_REPOS_USER..MGMT_CREATED_USERS
    23                     WHERE SYSTEM_USER=0)
    24           AND ROWNUM=1;
    25
    26      l_username := upper(l_username);
    27
    28      LOOP
    29
    30           BEGIN
    31           FOR crec in (SELECT sid, serial#
    32                     FROM v$session
    33                     WHERE username=l_username
    34                     AND status NOT IN('KILLED'))
    35           LOOP
    36           BEGIN
    37
    38                DBMS_OUTPUT.PUT_LINE('Killing session for user ' ||
    39                     l_username || ' Session : ' ||
    40                     crec.sid || ',' || crec.serial# );
    41
    42                EXECUTE IMMEDIATE 'ALTER SYSTEM KILL SESSION ''' ||
    43                          crec.sid || ',' || crec.serial# || '''';
    44                EXCEPTION
    45                WHEN OTHERS THEN
    46                err := SQLCODE;
    47                IF err != -30 THEN
    48                     EXIT;
    49                END IF;
    50           END;
    51           COMMIT;
    52           END LOOP; -- END OF KILLING SESSION LOOP
    53
    54           EXCEPTION
    55           WHEN OTHERS THEN
    56           err := SQLCODE;
    57           IF err != -30 THEN
    58                EXIT;
    59           END IF;
    60           END;
    61
    62           IF SQL%NOTFOUND THEN
    63           EXIT;
    64           END IF;
    65
    66      COMMIT;
    67
    68      END LOOP;
    69
    70      DBMS_OUTPUT.PUT_LINE('Dropping user ' || l_username);
    71
    72      EXECUTE IMMEDIATE 'drop user ' || l_username || ' cascade';
    73
    74      EXCEPTION
    75           WHEN NO_DATA_FOUND THEN
    76           EXIT;
    77           WHEN OTHERS THEN
    78           err := SQLCODE;
    79           IF err = -1918 THEN
    80           EXIT;
    81           ELSE
    82           IF err = -1940 THEN
    83           NULL;
    84           ELSE
    85           DBMS_OUTPUT.PUT_LINE('not 1940 Error ' || err);
    86           c := c+1;
    87           IF c > 50 THEN
    88                RAISE;
    89           END IF;
    90           END IF;
    91           END IF;
    92      END;
    93      end loop;
    94      end;
    95 end;
    96 /
    old 22:                    FROM &EM_REPOS_USER..MGMT_CREATED_USERS
    new 22:                    FROM SYSMAN.MGMT_CREATED_USERS
    Dropping user MGMT_VIEW
    PL/SQL procedure successfully completed.
    SQL>
    SQL> Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - Production
    With the Partitioning, OLAP, Data Mining and Real Application Testing options
    [27-05-2010 14:49:08] Drop EM Users. Return code = 0.
    [27-05-2010 14:49:08] Done.
    [27-05-2010 14:49:08] Dropping Repos User ...
    [27-05-2010 14:49:08] Drop Repos User. File - D:\Temp\l8DOrBVrQQ\4cvYQrsrBc.sql.
    SQL*Plus: Release 10.2.0.4.0 - Production on Thu May 27 14:49:09 2010
    Copyright (c) 1982, 2007, Oracle. All Rights Reserved.
    Enter user-name:
    Connected to:
    Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - Production
    With the Partitioning, OLAP, Data Mining and Real Application Testing options
    SQL> SQL> SQL> SQL> SQL> SQL> SQL> Rem
    SQL> Rem $Header: admin_drop_repos_user.sql 26-mar-2003.12:49:29 rpinnama Exp $
    SQL> Rem
    SQL> Rem admin_drop_repos_user.sql
    SQL> Rem
    SQL> Rem Copyright (c) 2002, 2003, Oracle Corporation.     All rights reserved.
    SQL> Rem
    SQL> Rem NAME
    SQL> Rem     admin_drop_repos_user.sql - <one-line expansion of the name>
    SQL> Rem
    SQL> Rem DESCRIPTION
    SQL> Rem     <short description of component this file declares/defines>
    SQL> Rem
    SQL> Rem NOTES
    SQL> Rem     <other useful comments, qualifications, etc.>
    SQL> Rem
    SQL> Rem MODIFIED (MM/DD/YY)
    SQL> Rem rpinnama     03/26/03 - Remove references to DropRep
    SQL> Rem rpinnama     03/25/03 - Parameterize repository user
    SQL> Rem rpinnama     06/03/02 - rpinnama_reorg_rep_scripts_3
    SQL> Rem rpinnama     05/20/02 - Created
    SQL> Rem
    SQL>
    SQL> Rem
    SQL> Rem This SQL script requires the following arguments
    SQL> Rem 1. Name of the repository user
    SQL> Rem
    SQL> DEFINE EM_REPOS_USER ="&1"
    SQL>
    SQL>
    SQL> declare
    2 l_username varchar2(30);
    3 l_sid number;
    4 l_serial number;
    5 err number;
    6 c number;
    7 begin
    8      -- Now, drop the SYSMAN user
    9      c := 0;
    10      l_username := upper('&EM_REPOS_USER');
    11      begin
    12      loop
    13      BEGIN
    14      LOOP
    15           BEGIN
    16           FOR crec in (SELECT sid, serial#
    17                     FROM v$session
    18                WHERE upper(username)=l_username
    19                     AND status NOT IN('KILLED'))
    20           LOOP
    21           BEGIN
    22                EXECUTE IMMEDIATE 'ALTER SYSTEM KILL SESSION ''' ||
    23                          crec.sid || ',' || crec.serial# || '''';
    24           EXCEPTION
    25                WHEN OTHERS THEN
    26                err := SQLCODE;
    27                IF err != -30 THEN
    28                     EXIT;
    29                END IF;
    30           END;
    31           commit;
    32           END LOOP;
    33           EXCEPTION
    34           WHEN OTHERS THEN
    35           err := SQLCODE;
    36           IF err != -30 THEN
    37                EXIT;
    38           END IF;
    39           END;
    40           IF SQL%NOTFOUND THEN
    41           EXIT;
    42           END IF;
    43           commit;
    44      END LOOP;
    45      execute immediate 'drop user ' || l_username || ' cascade';
    46      exit;
    47      EXCEPTION
    48           WHEN NO_DATA_FOUND THEN
    49           exit;
    50           WHEN OTHERS THEN
    51           err := SQLCODE;
    52           IF err = -1918 THEN
    53           EXIT;
    54           ELSE
    55           IF err = -1940 THEN
    56                NULL;
    57           ELSE
    58                DBMS_OUTPUT.PUT_LINE('not 1940 err' || err);
    59                c := c+1;
    60                IF c > 50 THEN
    61                RAISE;
    62                END IF;
    63           END IF;
    64           END IF;
    65      END;
    66      end loop;
    67      end;
    68      commit;
    69
    70 end;
    71 /
    old 10: l_username := upper('&EM_REPOS_USER');
    new 10: l_username := upper('SYSMAN');

  • Problem when "emca -config dbcontrol db -repos create" windows 2008 32 bit

    my emca_2011-09-15_12-12-23-PM.log
    2011-09-15 12:12:32 oracle.sysman.emcp.util.PlatformInterface executeCommand
    CONFIG: Starting execution: CMD /C C:\oracle\product\10.2.0\db_1\sysman\admin\scripts\emca\emcaDbUtil.bat "C:\oracle\product\10.2.0\db_1\sysman\admin\scripts;C:\oracle\product\10.2.0\db_1\bin;" C:/oracle/product/10.2.0/db_1/perl/5.8.3/bin/MSWin32-IA64-multi-thread\perl.exe C:\oracle\product\10.2.0\db_1\sysman\admin\scripts\emca\emcaDbUtil.pl C:\oracle\product\10.2.0\db_1 kbit SYS SYSDBA declare repos_pwd varchar2(30); view_user varchar2(30); view_user_pwd varchar2(30); view_user_acc_status varchar2(30); begin repos_pwd := ?; sysman.mgmt_view_priv.get_view_user(view_user); select account_status into view_user_acc_status from sys.dba_users where upper(username) = upper ( view_user ); IF view_user_acc_status like '%LOCKED%' THEN execute immediate 'alter user ' || view_user || ' account unlock'; END IF; IF view_user_acc_status like '%EXPIRED%' THEN sysman.mgmt_view_priv.set_view_user_creds ( repos_pwd ); sysman.mgmt_view_priv.GET_VIEW_USER_CREDS ( view_user, view_user_pwd ); execute immediate 'alter user ' || view_user || ' identified by ' || view_user_pwd || ''; END IF; end; 1 SYSMAN_PWD
    Edited by: john1212 on 2011-09-15 14:34

    John,
    So much information provided!! Luckily, you gave the command line in the title of the thread
    Instead of
    emca -config dbconsole db -repos createTry
    emca -config DBCONTROL db -repos createAnd if still failing, then post the 4 digits of DB version, OS details, and more info from the logfile!
    HTH,
    Thierry

  • Problem run emca -config dbcontrol db -repos create

    when tried to run emca -config dbcontrol db -repos create i choose oracle database SID: ORCL but when i write DBSNMP user pass: it shows me Invalid password.
    When i have tried to login in sqlplus with the same user: DBSNMP and my password it login me without porblem.
    I don't know where is the problem
    Details:
    OS: WIndows Server 2003
    Database version: Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production With the Partitioning, OLAP and Data Mining options
    Thanks

    Hi,
    The possible cause for this issue are like,
    1. The 11g Database has a restricted password policy enforced. Passwords must be 8+ characters and are case sensitive during database creation.
    2. Invalid password provided
    3. Password file created with wrong password.
    As you said you are able to login from sqlplus, so please check with the 1st & 3rd options.
    Best Regards,
    Venkat

  • Execute "emca -config dbcontrol db -repos create" exception

    Hi,
    I want to recreate OEM configuration, so I execute the above command.
    The following is the exception:
    Exception in thread "main" java.lang.NoClassDefFoundError: HTTPClient/ProtocolNo
    tSuppException
    at oracle.sysman.emd.targetIntg.agent.AgentTargetInstaller.<clinit>(Agen
    tTargetInstaller.java:235)
    at oracle.sysman.emcp.target.TargetManager.getAgentTargetInstaller(Targe
    tManager.java:1008)
    at oracle.sysman.emcp.target.TargetManager.getLocalHost(TargetManager.ja
    va:1033)
    at oracle.sysman.emcp.ParamsManager.getLocalHost(ParamsManager.java:1037
    at oracle.sysman.emcp.ParamsManager.getHost(ParamsManager.java:3020)
    at oracle.sysman.emcp.DatabaseChecks.checkDbAvailabilityImpl(DatabaseChe
    cks.java:118)
    at oracle.sysman.emcp.DatabaseChecks.checkDbAvailability(DatabaseChecks.
    java:163)
    at oracle.sysman.emcp.DatabaseChecks.getDbServiceName(DatabaseChecks.jav
    a:582)
    at oracle.sysman.emcp.EMConfigAssistant.performConfiguration(EMConfigAss
    istant.java:1272)
    at oracle.sysman.emcp.EMConfigAssistant.statusMain(EMConfigAssistant.jav
    a:574)
    at oracle.sysman.emcp.EMConfigAssistant.main(EMConfigAssistant.java:522)
    How to fix the problem?
    thank a lot

    Hi,
    I want to recreate OEM configuration, so I execute the above command.If you already have create the repository, then maybe you could check / try to drop the repository before firing the "-repos create" command?
    emca -config dbcontrol db -repos recreateor
    emca -repos drop
    emca -config dbcontrol db -repos createPS: not a good idea to do this in a production database during working hours, since your DB will go in quiesce mode while dropping the repository.
    HTH,
    Thierry

  • Emca -config dbcontrol db -repos create  TAKE LONG TIME

    hi,
    i want to create Enterprise Manager by the following command:
    emca -config dbcontrol db -repos create
    this work take long time ,how could i decrease time of creation enterprise manager?

    user498843 wrote:
    if i have some active session the emca will hang.
    Metalink says the database going to QUISEC mode.and thats better u havent any active session.
    then could i kill all active session or open database in resetlog.
    which is better?
    Do not open resetlog! What makes you think that has anything at all to do with this?
    >
    my memory is:
    total used free shared buffers cached
    Mem: 3951 3924 27 0 2 2670
    -/+ buffers/cache: 1252 2699
    Swap: 8191 2333 5858
    Edited by: user498843 on Oct 28, 2009 1:27 AM

  • Emca -config emkey error running on windows 2003 r2

    Hello
    I have recreate EM using ...
    Step One:-
    SHUTDOWN IMMEDIATE;
    STARTUP RESTRICT;
    DROP USER sysman CASCADE;
    DROP ROLE mgmt_user;
    DROP USER mgmt_view;
    DECLARE
    CURSOR c1 IS
    SELECT owner, synonym_name name FROM dba_synonyms WHERE table_owner = 'SYSMAN';
    BEGIN
    FOR r1 IN c1 LOOP
    IF r1.owner = 'PUBLIC' THEN
    EXECUTE IMMEDIATE 'DROP PUBLIC SYNONYM '||r1.name;
    ELSE
    EXECUTE IMMEDIATE 'DROP SYNONYM '||r1.owner||'.'||r1.name;
    END IF;
    END LOOP;
    END;
    ALTER SYSTEM DISABLE RESTRICTED SESSION;
    Step two:-
    emca -config dbcontrol db -repos create
    While the processes run ok untill I get an EMKEY error:-
    SEVERE: Error copying Em Key to Management Repository. The Em Key is not configu
    red properly or is corrupted in the file system and does not exist in the Manage
    ment Repository. To correct the problem:
    1) Copy the emkey.ora file from another OMS or backup machine to the G:\app\Adm
    inistrator\product\11.2.0\dbhome_1/sysman/config and run following commands:
    i) G:\app\Administrator\product\11.2.0\dbhome_1/bin/emctl config emkey -emkeyfi
    le G:\app\Administrator\product\11.2.0\dbhome_1/sysman/config/emkey.ora -force
    ii) G:\app\Administrator\product\11.2.0\dbhome_1/bin/emctl config emkey -copy_
    to_repos
    iii) Run EM Configuration Assistant again
    2) If emkey.ora is not available from backup, run G:\app\Administrator\product\
    11.2.0\dbhome_1/bin/emca with -repos create option.
    I tried running emctl config and getting error:-
    C:\>G:\app\Administrator\product\11.2.0\dbhome_1/bin/emctl config emkey -emkeyfi
    le G:\app\Administrator\product\11.2.0\dbhome_1\c100795_orcl\sysman\config/emkey
    .ora -force
    Oracle Enterprise Manager 11g Database Control Release 11.2.0.1.0
    Copyright (c) 1996, 2010 Oracle Corporation. All rights reserved.
    Please enter repository password:
    Exception caught
    3
    java.lang.ArrayIndexOutOfBoundsException: 3
    at oracle.sysman.util.crypt.DataHolder.getSet(Crypt.java:780)
    at oracle.sysman.util.crypt.Crypt.decryptAsByteArray(Crypt.java:256)
    at oracle.sysman.util.crypt.Crypt.decrypt(Crypt.java:227)
    at oracle.sysman.emSDK.conf.ConfigManager.processSensitiveProperties(Con
    figManager.java:1225)
    at oracle.sysman.emSDK.conf.ConfigManager.processProperties(ConfigManage
    r.java:1150)
    at oracle.sysman.emSDK.conf.ConfigManager.processProperties(ConfigManage
    r.java:1127)
    at oracle.sysman.eml.sec.rep.EmKeyUtil.<init>(EmKeyUtil.java:105)
    at oracle.sysman.eml.sec.rep.EmKeyUtil.main(EmKeyUtil.java:478)
    What am I doing wrong?
    All help very welcome
    Thanks, Pete

    Dear Deebee
    Still seeing the same problem
    This is what I have done (incorrectly I believe) ...
    1) Removed (after taking a back up) file and folders from
    ORACLE_HOME/host_sid/
    ORACLE_HOME/oc4j/j2ee/OC4J_DBConsole_host_sid
    2) run emca -config dbcontrol db -repos create
    3) run
    G:\app\Administrator\product\11.2.0\dbhome_1/bin/emctl config emkey -emkeyfile G:\app\Administrator\product\11.2.0\dbhome_1/sysman/config/emkey.ora -force
    got follwoing error ...
    Can't find file G:\app\Administrator\product\11.2.0\dbhome_1/c100795_orcl/sysman/config/emoms.properties
    4) Replaced the G:\app\Administrator\product\11.2.0\dbhome_1/c100795_orcl/sysman/config/emoms.properties from the back up
    5) rerun G:\app\Administrator\product\11.2.0\dbhome_1/bin/emctl config emkey -emkeyfile G:\app\Administrator\product\11.2.0\dbhome_1/sysman/config/emkey.ora -force
    got the same error as before ...
    C:\>G:\app\Administrator\product\11.2.0\dbhome_1/bin/emctl config emkey -emkeyfi
    le G:\app\Administrator\product\11.2.0\dbhome_1/sysman/config/emkey.ora -force
    Oracle Enterprise Manager 11g Database Control Release 11.2.0.1.0
    Copyright (c) 1996, 2010 Oracle Corporation. All rights reserved.
    Please enter repository password:
    Exception caught
    3
    java.lang.ArrayIndexOutOfBoundsException: 3
    at oracle.sysman.util.crypt.DataHolder.getSet(Crypt.java:780)
    at oracle.sysman.util.crypt.Crypt.decryptAsByteArray(Crypt.java:256)
    at oracle.sysman.util.crypt.Crypt.decrypt(Crypt.java:227)
    at oracle.sysman.emSDK.conf.ConfigManager.processSensitiveProperties(Con
    figManager.java:1225)
    at oracle.sysman.emSDK.conf.ConfigManager.processProperties(ConfigManage
    r.java:1150)
    at oracle.sysman.emSDK.conf.ConfigManager.processProperties(ConfigManage
    r.java:1127)
    at oracle.sysman.eml.sec.rep.EmKeyUtil.<init>(EmKeyUtil.java:105)
    at oracle.sysman.eml.sec.rep.EmKeyUtil.main(EmKeyUtil.java:478)
    Hope this makes sense?
    Regards
    Pete

  • EMCA config dbconsole creates DB Console configuration using localhost.

    Configured a repository and dbcontrol using emca (emca -config dbcontrol db -repos create).
    However, it uses the Local hostname as localhost, instead of using the actual hostname of the server.
    Server box OS: Linux.
    Portion of /etc/hosts (topmost portion)
    # Do not remove the following line, or various programs
    # that require network functionality will fail.
    127.0.0.1 localhost.localdomain loghost
    10.184.133.162 localhost.in.oracle.com localhost
    10.184.133.162 ofss220210.in.oracle.com ofss220210
    How to change this URL to reflect the actual name of the host in the URL instead of using the localhost?

    Found answer on my own: You can export variable ORACLE_HOSTNAME to the server name or the name which is accessible from any machine.

Maybe you are looking for

  • Watermarking with Photoshop Elements 10

    I am trying to watermark some of my photos, I have learned to do them individually. I have also learned to do them with the "process multiple files" , however I have tried over half of the fonts, and even at 72 they are too small. Some of them you ca

  • BOMM 3.0: ClassCastExeption

    Hi, We have installed BOMM 3.0 and BOE 3.0 (FP1) on a windowsserver 2003 64bit, and with an Oracle 10.2.0.1 32 bit client software. Our repos (AUDIT,BOMM,CMS) are placed in an Oracle 10.2.0.2 64 bit database (on different schemas) on a Solaris server

  • Tiles and transtions not loading

    When I attempt to put a title or transition into my film, it shows up as a glitchy/buggy black screen. I have restarted iMovie and tried starting new projects but I cannot use any title or transition effects as it just shows up as a black frame on my

  • Printing on small sheets

    using p;hotosmart 8200 I want to print on paper that is 8.5 x 3.5 feeding the 3.5 edge first

  • Template problem on Intel Mac

    Hi All, I just jumped ship,and have started developing on and working with Mac's, so go easy on me! I am trying to use the "Wedding Classic Cover" template (First of three) and when I drag an asset to the "Content Here 1" area on the menu, it will no