使用EMCA創建oracle10g dbconsole

【轉自】http://blog.sina.com.cn/s/blog_4b1c9e12010009cg.html


今天機器重新換了IP地址,EM的服務就啓動不起來了,所以重建了EM的資料檔案庫,重新配置了dbconsole。

步驟如下:
C:\Documents and Settings\new>set oracle_sid=ora10g
C:\Documents and Settings\new>emca -repos recreate

EMCA 開始於 2007-4-19 14:09:05
EM Configuration Assistant 10.2.0.1.0 正式版
版權所有 (c) 2003, 2005, Oracle。保留所有權利。

輸入以下信息:
數據庫 SID: ora10g
監聽程序端口號: 1521
SYS 用戶的口令:
SYSMAN 用戶的口令:

是否繼續? [yes(Y)/no(N)]: yes
2007-4-19 14:10:09 oracle.sysman.emcp.EMConfig perform
信息: 正在將此操作記錄到 d:\oracle\product\10.2.0\db_1\cfgtoollogs\emca\ora10g\e
mca_2007-04-19_02-09-05-下午.log。
2007-4-19 14:10:09 oracle.sysman.emcp.EMReposConfig dropRepository
信息: 正在刪除 EM 資料檔案庫 (此操作可能需要一段時間)...
2007-4-19 14:13:18 oracle.sysman.emcp.EMReposConfig invoke
信息: 已成功刪除資料檔案庫
2007-4-19 14:13:18 oracle.sysman.emcp.EMReposConfig createRepository
信息: 正在創建 EM 資料檔案庫 (此操作可能需要一段時間)...
2007-4-19 14:17:37 oracle.sysman.emcp.EMReposConfig invoke
信息: 已成功創建資料檔案庫
已成功完成 Enterprise Manager 的配置
EMCA 結束於 2007-4-19 14:17:37

C:\Documents and Settings\new>emca -config dbcontrol db

EMCA 開始於 2007-4-19 14:19:38
EM Configuration Assistant 10.2.0.1.0 正式版
版權所有 (c) 2003, 2005, Oracle。保留所有權利。

輸入以下信息:
數據庫 SID: ora10g
已爲數據庫 ora10g 配置了 Database Control
您已選擇配置 Database Control, 以便管理數據庫 ora10g
此操作將移去現有配置和默認設置, 並重新執行配置
是否繼續? [yes(Y)/no(N)]: yes
監聽程序端口號: 1521
SYS 用戶的口令:
DBSNMP 用戶的口令:
SYSMAN 用戶的口令:
通知的電子郵件地址 (可選):
通知的發件 (SMTP) 服務器 (可選):
-----------------------------------------------------------------

已指定以下設置

數據庫 ORACLE_HOME ................ d:\oracle\product\10.2.0\db_1

數據庫主機名 ................ MICROSOF-029
監聽程序端口號 ................ 1521
數據庫 SID ................ ora10g
通知的電子郵件地址 ...............
通知的發件 (SMTP) 服務器 ...............

-----------------------------------------------------------------
是否繼續? [yes(Y)/no(N)]: yes
2007-4-19 14:20:02 oracle.sysman.emcp.EMConfig perform
信息: 正在將此操作記錄到 d:\oracle\product\10.2.0\db_1\cfgtoollogs\emca\ora10g\e
mca_2007-04-19_02-19-38-下午.log。
2007-4-19 14:20:03 oracle.sysman.emcp.DatabaseChecks performReposChecks
警告: 'shared_pool_size' 必須大於等於 80 MB。
2007-4-19 14:20:05 oracle.sysman.emcp.util.DBControlUtil stopOMS
信息: 正在停止 Database Control (此操作可能需要一段時間)...
2007-4-19 14:20:16 oracle.sysman.emcp.util.DBControlUtil startOMS
信息: 正在啓動 Database Control (此操作可能需要一段時間)...
2007-4-19 14:21:10 oracle.sysman.emcp.EMDBPostConfig performConfiguration
信息: 已成功啓動 Database Control
2007-4-19 14:21:17 oracle.sysman.emcp.EMDBPostConfig performConfiguration
警告: 無法創建 Database Control 快捷方式
2007-4-19 14:21:17 oracle.sysman.emcp.EMDBPostConfig performConfiguration
信息: >>>>>>>>>>> Database Control URL 爲 http://MICROSOF-029:5501/em <<<<<<<<<<
<
已成功完成 Enterprise Manager 的配置
EMCA 結束於 2007-4-19 14:21:18

C:\Documents and Settings\new>emctl start dbconsole
Oracle Enterprise Manager 10g Database Control Release 10.2.0.1.0
Copyright (c) 1996, 2005 Oracle Corporation.  All rights reserved.
http://MICROSOF-029:5501/em/console/aboutApplication
Agent Version     : 10.1.0.4.1
OMS Version       : 10.1.0.4.0
Protocol Version  : 10.1.0.2.0
Agent Home        : d:\oracle\product\10.2.0\db_1\MICROSOF-029_ora10g
Agent binaries    : d:\oracle\product\10.2.0\db_1
Agent Process ID  : 3836
Agent Process ID  : 3836
Agent URL         : http://MICROSOF-029:3938/emd/main
Started at        : 2007-04-19 14:21:56
Started by user   : SYSTEM
Last Reload       : 2007-04-19 14:21:56
Last successful upload                       : (none)
Last attempted upload                        : 2007-04-19 14:22:51
Total Megabytes of XML files uploaded so far :     0.00
Number of XML files pending upload           :        5
Size of XML files pending upload(MB)         :     2.31
Available disk space on upload filesystem    :    59.92%
Agent is already started. Will restart the agent
This will stop the Oracle Enterprise Manager 10g Database Control process. Conti
nue [y/n] :y
OracleDBConsoleora10g 服務正在停止.............
OracleDBConsoleora10g 服務已成功停止。


C:\Documents and Settings\new>emctl start dbconsole
Oracle Enterprise Manager 10g Database Control Release 10.2.0.1.0
Copyright (c) 1996, 2005 Oracle Corporation.  All rights reserved.
http://MICROSOF-029:5501/em/console/aboutApplication
Starting Oracle Enterprise Manager 10g Database Control ...OracleDBConsoleora10g
 服務正在啓動 ..............
OracleDBConsoleora10g 服務已經啓動成功。

附上EMCA的常用命令:
創建一個EM資料庫
emca -repos create
重建一個EM資料庫
emca -repos recreate
刪除一個EM資料庫
emca -repos drop
配置數據庫的 Database Control
emca -config dbcontrol db
刪除數據庫的 Database Control配置
emca -deconfig dbcontrol db
重新配置db control的端口,默認端口在1158
emca -reconfig ports
emca -reconfig ports -dbcontrol_http_port 1160
emca -reconfig ports -agent_port 3940
先設置ORACLE_SID環境變量後,啓動EM console服務
emctl start dbconsole
先設置ORACLE_SID環境變量後,停止EM console服務
emctl stop dbconsole
先設置ORACLE_SID環境變量後,查看EM console服務的狀態
emctl status dbconsole

配置dbconsole的步驟
emca -repos create
emca -config dbcontrol db
emctl start dbconsole
重新配置dbconsole的步驟
emca -repos drop
emca -repos create
emca -config dbcontrol db
emctl start dbconsole

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章