Oracle Enterprise Manager (emctl Utility) Command
===================================== Oracle Management Agent is managing and administrating Oracle database in Grid environment. Using Oracle Management Agent you can run jobs, start listener, start instance, stop listener, stop instances. Oracle Management Agent resides at every Oracle instances, application servers. Hence Management Agent is key feature of Oracle Enterprise Manager Grid.
Usage of Enterprise Manager Control utility:
Emctl {start | stop| status} (dbconsole | oms | agent | iasconsole)
Using start; you can start dbconsole, oms, agent, iasconsoleUsing stop; you can stop dbconsole, oms, agent, iasconsole
Using status; you can check status of dbconsole, oms, agent, iasconsole.
Terminology:
Dbconsole is Database Control console.
OMS is Oracle Management Server.
Agent is Oracle Management Agent.
IASCONSOLE is Oracle Application Server Control console.
Example of Enterprise Manager Control utility:
# To start dbconsole
emctl start dbconsole
C:\>emctl start dbconsoleOracle Enterprise Manager 10g Database Control Release 10.2.0.3.0
Copyright (c) 1996, 2006 Oracle Corporation. All rights reserved.
http://it_mamun:1158/em/console/aboutApplication
Starting Oracle Enterprise Manager 10g Database Control ...The OracleDBConsoleORCL service is starting................
The OracleDBConsoleORCL service was started successfully.
# To Check status of dbconsole
emctl status dbconsole
C:\>emctl status dbconsoleOracle Enterprise Manager 10g Database Control Release 10.2.0.3.0
Copyright (c) 1996, 2006 Oracle Corporation. All rights reserved.
http://it_mamun:1158/em/console/aboutApplication
Oracle Enterprise Manager 10g is running.
------------------------------------------------------------------
Logs are generated in directory E:\oracle\product\10.2.0\db_1/it_mamun_orcl/sysman/log
C:\>
# To stop dbconsole
emctl stop dbconsole
C:\>emctl stop dbconsoleOracle Enterprise Manager 10g Database Control Release 10.2.0.3.0
Copyright (c) 1996, 2006 Oracle Corporation. All rights reserved.
http://it_mamun:1158/em/console/aboutApplication
The OracleDBConsoleORCL service is stopping........
The OracleDBConsoleORCL service was stopped successfully.
C:\>
# To start Management Agent
emctl start agent
** To start Management Agent in command line , it will may be not start and show given below following message:C:\>emctl start agent
Oracle Enterprise Manager 10g Database Control Release 10.2.0.3.0
Copyright (c) 1996, 2006 Oracle Corporation. All rights reserved.
The service name is invalid.
More help is available by typing NET HELPMSG 2185.
So you can do tricks for to start the dbconsole i.e start the dbconsole with managent agent
# To Check status of Management Agent
emctl status agent
C:\>emctl status agentOracle Enterprise Manager 10g Database Control Release 10.2.0.3.0
Copyright (c) 1996, 2006 Oracle Corporation. All rights reserved.
---------------------------------------------------------------
Agent Version : 10.1.0.5.1
OMS Version : 10.1.0.5.0
Protocol Version : 10.1.0.2.0
Agent Home : E:\oracle\product\10.2.0\db_1\it_mamun_ORCL
Agent binaries : E:\oracle\product\10.2.0\db_1
Agent Process ID : 4720
Agent Process ID : 4720
Agent URL : http://it_mamun:3938/emd/main
Started at : 2011-06-22 18:37:23
Started by user : SYSTEM
Last Reload : 2011-06-22 18:37:23
Last successful upload : 2011-06-22 18:37:41
Total Megabytes of XML files uploaded so far : 0.03
Number of XML files pending upload : 1
Size of XML files pending upload(MB) : 0.00
Available disk space on upload filesystem : 8.43%
---------------------------------------------------------------
Agent is Running and Ready
# To stop Management Agent
emctl stop agent
C:\>emctl stop agentOracle Enterprise Manager 10g Database Control Release 10.2.0.3.0
Copyright (c) 1996, 2006 Oracle Corporation. All rights reserved.
This will stop the Oracle Enterprise Manager 10g Database Control process. Continue [y/n] :y
The OracleDBConsoleORCL service is stopping............
The OracleDBConsoleORCL service was stopped successfully.
C:\>
# To start Oracle Application Server control console
emctl start iasconsole
# To Check status of iasconsoleemctl status iasconsole
# To stop Oracle Application Server control consoleemctl stop iasconsole
EMCTL is very useful command line of Oracle Enterprise Manager to manage all Oracle Enterprise Manager services. Specially when we are working in Remote Oracle Support and Remote database Monitoring and managing large number of critical production Oracle databases.