<rt id="bn8ez"></rt>
<label id="bn8ez"></label>

  • <span id="bn8ez"></span>

    <label id="bn8ez"><meter id="bn8ez"></meter></label>

    Decode360's Blog

    業精于勤而荒于嬉 QQ:150355677 MSN:decode360@hotmail.com

      BlogJava :: 首頁 :: 新隨筆 :: 聯系 ::  :: 管理 ::
      397 隨筆 :: 33 文章 :: 29 評論 :: 0 Trackbacks
    Oracle10g中OEM相關問題

    ??? 最近要用到OEM,發現在Linux下面裝的Oracle默認沒有打開console,所以需要手動開啟一下。找了點資料,也遇到了一些困難,就順便學習一下相關的知識。把要記錄的東西都記下來,也把錯誤貼出來,希望可以對別人有所幫助。
    ?
    ?
    一、啟動和關閉

    以下是啟動過程:

    [oracle@wxq?~]$ emctl start dbconsole
    TZ set to PRC
    Oracle Enterprise Manager 10g Database Control Release 10.2.0.3.0?
    Copyright (c) 1996, 2006 Oracle Corporation.? All rights reserved.
    http://wxq.mydomain:1158/em/console/aboutApplication
    Starting Oracle Enterprise Manager 10g Database Control ................................. started.
    ------------------------------------------------------------------
    Logs are generated in directory /opt/oracle/product/10.2.0/db_1/wxq.mydomain_devMISowb/sysman/log

    ?
    以下是關閉過程:
    ?
    [oracle@wxq ~]$ emctl stop dbconsole
    TZ set to PRC
    Oracle Enterprise Manager 10g Database Control Release 10.2.0.3.0?
    Copyright (c) 1996, 2006 Oracle Corporation.? All rights reserved.
    http://wxq.mydomain:1158/em/console/aboutApplication
    Stopping Oracle Enterprise Manager 10g Database Control ......? Stopped.
    ?
    ?
    在第一次啟動的時候,遇到了一個問題,就是報錯
    [oracle@wxq?~]$ emctl start dbconsole
    TZ set to PRC
    OC4J Configuration issue. /opt/oracle/product/10.2.0/db_1/oc4j/j2ee/OC4J_DBConsole_wxq.mydomain_devMISowb not found.
    [oracle@wxq?~]$ emctl start dbconsole
    TZ set to PRC
    EM Configuration issue. /opt/oracle/product/10.2.0/db_1/wxq.mydomain_devMISowb not found.
    ?
    原因是在安裝Oracle的時候是使用localhost.localdomain作為機器名的,所以以上兩個目錄都是用了這個機器名來創建。之后修改了機器名之后,OEM啟動時就無法找到對應的文件夾了,需要手動修改一下名稱:
    [oracle@wxq j2ee]$ mv OC4J_DBConsole_localhost.localdomain_devMISowb/ OC4J_DBConsole_wxq.mydomain_devMISowb
    [oracle@wxq db_1]$ mv localhost.localdomain_devMISowb/ wxq.mydomain_devMISowb
    ?
    ?
    二、登錄OEM問題
    ?
    啟動的時候會有提示登錄地址,只要按照這個登錄地址就可以了。例如我的地址就是:
    http://wxq.mydomain:1158/em/
    ?
    ?
    如果OEM已經啟動了,可以通過emctl status dbconsole命令來查看:
    ?
    [oracle@wxq ~]$ emctl status dbconsole
    TZ set to PRC
    Oracle Enterprise Manager 10g Database Control Release 10.2.0.3.0?
    Copyright (c) 1996, 2006 Oracle Corporation.? All rights reserved.
    http://wxq.mydomain:1158/em/console/aboutApplication
    Oracle Enterprise Manager 10g is running.
    ------------------------------------------------------------------
    Logs are generated in directory /opt/oracle/product/10.2.0/db_1/wxq.mydomain_devMISowb/sysman/log

    ?
    還可以通過以下文件查看Oracle的所有端口設置:
    ?
    [oracle@wxq ~]$ cat /opt/oracle/product/10.2.0/db_1/install/portlist.ini
    iSQL*Plus HTTP port number =5560
    Enterprise Manager Console HTTP Port (devMISowb) = 1158
    Enterprise Manager Agent Port (devMISowb) = 1831

    ?
    三、emctl的其他操作
    ?
    直接輸入emctl命令來查看emctl可以做的所有操作:
    ?
    [oracle@wxq ~]$ emctl
    TZ set to PRC
    Oracle Enterprise Manager 10g Database Control Release 10.2.0.3.0?
    Copyright (c) 1996, 2006 Oracle Corporation.? All rights reserved.
    Invalid arguments
    ?
    Unknown command option
    Usage::
    ?? Oracle Enterprise Manager 10g Database Control commands:
    ?????? emctl start| stop| status| setpasswd dbconsole
    ?????? emctl secure <options>
    ?
    ?????? emctl set ssl test|off|on em
    ?????? emctl set ldap <host> <port> <user dn> <user pwd> <context dn>
    emctl blackout options can be listed by typing "emctl blackout"
    emctl config options can be listed by typing "emctl config"
    emctl secure options can be listed by typing "emctl secure"
    emctl ilint? options can be listed by typing "emctl ilint"
    emctl deploy? options can be listed by typing "emctl deploy"

    具體的操作等以后有空的時候嘗試一下。
    ?

    四、遇到的問題
    ?
    開啟之后發現部分按鈕的名稱在本地顯示亂碼,而且無法連接到OEM
    ?
    OEM
    ?
    亂碼問題具體的解決辦法可以參考:http://www.eygle.com/archives/2006/03/oracle10g_em_font_change.html
    ?
    無法連接的問題可以參見:http://space.itpub.net/161195/viewspace-501482
    ?
    ?
    ?
    ?
    ?
    ?
    ?
    ?
    以下轉貼以上兩個鏈接,以防失效:
    *******************************************************************************************
    Oracle10g EM亂碼之快速解決
    作者:eygle |English Version 【轉載時請以超鏈接形式標明文章出處和作者信息及本聲明】
    鏈接:
    http://www.eygle.com/archives/2006/03/oracle10g_em_font_change.html
    --------------------------------------------------------------------------------
    一直沒怎么用10g的EM工具,今天打開來看看,發現也有相傳已久的亂碼問題.網上也流傳著N種解決方案,仔細看一下,其實這個問題很好解決.
    ?
    如果安裝時,我們系統環境變量設置的是中文環境,那么就不會有這個問題.這個問題根本原因在于安裝時,JDK/JRE字符集的自動選擇.
    ?
    在 $ORACLE_HOME/jdk/jre/lib 和 $ORACLE_HOME/jre/1.4.2/lib/ 目錄下都有多種字符集字體配置文件:
    ?
    [oracle@danaly ~]$ cd $ORACLE_HOME/jdk/jre/lib[oracle@danaly lib]$ ls font*zh_CN*font.properties.zh_CN.Redhat? font.properties.zh_CN.Redhat2.1? font.properties.zh_CN.Sun? font.properties.zh_CN_UTF8.Sun[oracle@danaly lib]$ cd $ORACLE_HOME/jre/1.4.2/lib/[oracle@danaly lib]$ ls font*zh_CN*font.properties.zh_CN.Redhat? font.properties.zh_CN.Redhat2.1? font.properties.zh_CN.Sun? font.properties.zh_CN_UTF8.Sun?
    ?
    我們只要用合適的中文字符集文件替換缺省文件即可,我選擇使用font.properties.zh_CN.Redhat來替換缺省字體定義文件:
    ?
    [oracle@danaly lib]$ cp font.properties.zh_CN.Redhat font.properties?
    ?
    替換之后需要清理一下Cache,重啟EM即可.
    ?
    Cache路徑通常位于:
    ?
    $ORACLE_HOME/oc4j/j2ee/oc4j_applications/applications/em/em/cabo/images/cache/zhs?
    ?
    清除所有gif文件即可.然后重新啟動EM:
    ?
    [oracle@danaly zhs]$ emctl stop dbconsoleTZ set to PRCoracle Enterprise Manager 10g Database Control Release 10.2.0.1.0? Copyright (c) 1996, 2005 oracle Corporation.? All rights reserved.http://danaly.hurrray.com.cn:1158/em/console/aboutApplicationStopping oracle Enterprise Manager 10g Database Control ...? ...? Stopped. [oracle@danaly zhs]$ emctl start dbconsoleTZ set to PRCoracle Enterprise Manager 10g Database Control Release 10.2.0.1.0? Copyright (c) 1996, 2005 oracle Corporation.? All rights reserved.http://danaly.hurrray.com.cn:1158/em/console/aboutApplicationStarting oracle Enterprise Manager 10g Database Control .............. started. ------------------------------------------------------------------Logs are generated in directory /opt/oracle/product/10.2.0/danaly.hurrray.com.cn_danaly/sysman/log??
    ?
    現在登陸Web頁面,EM顯示就可以正常顯示中文了.
    ?
    注意:如果經過以上處理仍然不能正確顯示中文,請參考以下說明:
    ?
    打開剛替換好的font.properties,或者查看原有的中文字體文件:
    ?

    [oracle@smsdbrac1 lib]$ tail -2 font.properties.zh_CN.Redhat
    filename.-misc-zysong18030-medium-r-normal--*-%d-*-*-c-*-iso10646-1=/usr/share/fonts/zh_CN/TrueType/zysong.ttf
    注意其中包含了filename指向中文字體文件,請確認該文件在你的服務器上是否存在,如果不存在,改換一個存在的中文字體文件即可,也可以自行下載安裝新的字體文件:
    ?
    ?
    ?
    [oracle@smsdbrac1 lib]$ ls -al /usr/share/fonts/zh_CN/TrueType/zysong.ttf
    -rw-r--r--? 1 root root 9249332 Mar 29? 2002 /usr/share/fonts/zh_CN/TrueType/zysong.ttf
    ?
    *******************************************************************************************
    ?
    主機名改名后oracle database control 無法啟動的問題
    上一篇 / 下一篇? 2008-11-23 12:13:33 / 個人分類:oracle管理
    ?
    查看( 366 ) / 評論( 2 ) / 評分( 0 / 0 )
    一、簡介:
    ?
    1.概念
    ?
    Oracle10G的EM(企業管理器)采用了web方式,也就是直接打開ie瀏覽器,輸入網址就可以訪問oracle,進而可以管理oracle.
    ?
    Oracle10G的EM 分成了2個產品,database control(用于一個database的)和grid contro(用于多個database的)。這里遇到的問題是在database control(用于一個database的)。Grid control據說需要下載單獨的光盤安裝,這一點也我只是看到其他高手這么說的,我并沒有做過。
    ?
    下面一段話摘自http://www.cublog.cn/u/25565/showart_268270.html,十分感謝這位高手。
    ?
    在用DBCA建庫的時候,可以選擇是否啟用dbcontrol,啟用的話需要在數據庫中建立一個sysman的schema,用于保存EM的一些數據,這個就是EM的資料庫(repository)。
    ?
    ---摘錄完畢。
    ?
    2.本機的環境
    ?
    裝oralce 10g之前,忘記了改主機名,這樣一來,是在裝完oracle后,去改的主機名,改完主機名后,還需要去改E:\oracle\product\10.2.0\db_1\network\admin\listener.ora? 這個文件,將其中的老主機名改為新主機名。這是個老問題了,不知道oracle為什么不解決呢?呵呵。
    ?
    二、解決過程:
    ?
    Microsoft Windows XP [版本 5.1.2600]
    (C) 版權所有 1985-2001 Microsoft Corp.
    ?
    C:\Documents and Settings\Administrator>emctl
    Environment variable ORACLE_SID not defined. Please define it.
    ?
    C:\Documents and Settings\Administrator>set oracle_sid=oracle
    ?
    C:\Documents and Settings\Administrator>emctl
    Oracle Enterprise Manager 10g Database Control Release 10.2.0.1.0
    Copyright (c) 1996, 2005 Oracle Corporation.? All rights reserved.
    Invalid arguments
    ?
    Unknown command option
    Usage::
    ?? Oracle Enterprise Manager 10g Database Control commands:
    ?????? emctl start| stop| status| setpasswd dbconsole
    ?????? emctl secure <options>
    ?
    ?????? emctl set ssl test|off|on em
    ?????? emctl set ldap <host> <port> <user dn> <user pwd> <context dn>
    emctl blackout options can be listed by typing "emctl blackout"
    emctl config options can be listed by typing "emctl config"
    emctl secure options can be listed by typing "emctl secure"
    emctl ilint? options can be listed by typing "emctl ilint"
    emctl deploy? options can be listed by typing "emctl deploy"
    ?
    C:\Documents and Settings\Administrator>emctl start dbconsole
    Unable to determine local host from URL REPOSITORY_URL=http://shleiyanliang:%EM_
    UPLOAD_PORT%/em/upload/
    .
    ?
    C:\Documents and Settings\Administrator>emca -config dbcontrol db
    ?
    EMCA 開始于 2008-11-23 12:07:02
    EM Configuration Assistant 10.2.0.1.0 正式版
    版權所有 (c) 2003, 2005, Oracle。保留所有權利。
    ?
    輸入以下信息:
    數據庫 SID: oracle
    已為數據庫 oracle 配置了 Database Control
    您已選擇配置 Database Control, 以便管理數據庫 oracle
    此操作將移去現有配置和默認設置, 并重新執行配置
    是否繼續? [yes(Y)/no(N)]: y
    監聽程序端口號: 1521
    SYS 用戶的口令:
    DBSNMP 用戶的口令:
    SYSMAN 用戶的口令:
    SYSMAN 用戶的口令: 通知的電子郵件地址 (可選):leiyanliang@inspur.com
    通知的發件 (SMTP) 服務器 (可選):
    -----------------------------------------------------------------
    ?
    已指定以下設置
    ?
    數據庫 ORACLE_HOME ................ E:\oracle\product\10.2.0\db_1
    ?
    數據庫主機名 ................ shleiyanliang
    監聽程序端口號 ................ 1521
    數據庫 SID ................ oracle
    通知的電子郵件地址
    ...............leiyanliang@inspur.com
    通知的發件 (SMTP) 服務器 ...............
    ?
    -----------------------------------------------------------------
    是否繼續? [yes(Y)/no(N)]: y
    2008-11-23 12:07:43 oracle.sysman.emcp.EMConfig perform
    信息: 正在將此操作記錄到 E:\oracle\product\10.2.0\db_1\cfgtoollogs\emca\oracle\e
    mca_2008-11-23_12-07-01-下午.log。
    2008-11-23 12:07:47 oracle.sysman.emcp.util.DBControlUtil stopOMS
    信息: 正在停止 Database Control (此操作可能需要一段時間)...
    2008-11-23 12:07:56 oracle.sysman.emcp.util.DBControlUtil startOMS
    信息: 正在啟動 Database Control (此操作可能需要一段時間)...
    2008-11-23 12:08:36 oracle.sysman.emcp.EMDBPostConfig performConfiguration
    信息: 已成功啟動 Database Control
    2008-11-23 12:08:36 oracle.sysman.emcp.EMDBPostConfig performConfiguration
    警告: 無法創建 Database Control 快捷方式
    2008-11-23 12:08:36 oracle.sysman.emcp.EMDBPostConfig performConfiguration
    信息: >>>>>>>>>>> Database Control URL 為
    http://shleiyanliang:1158/em<<<<<<<<<
    <<
    已成功完成 Enterprise Manager 的配置
    EMCA 結束于 2008-11-23 12:08:36
    ?
    C:\Documents and Settings\Administrator>emctl status dbconcole
    Oracle Enterprise Manager 10g Database Control Release 10.2.0.1.0
    Copyright (c) 1996, 2005 Oracle Corporation.? All rights reserved.
    Invalid arguments
    ?
    Unknown command option status
    Usage::
    ?? Oracle Enterprise Manager 10g Database Control commands:
    ?????? emctl start| stop| status| setpasswd dbconsole
    ?????? emctl secure <options>
    ?
    ?????? emctl set ssl test|off|on em
    ?????? emctl set ldap <host> <port> <user dn> <user pwd> <context dn>
    emctl blackout options can be listed by typing "emctl blackout"
    emctl config options can be listed by typing "emctl config"
    emctl secure options can be listed by typing "emctl secure"
    emctl ilint? options can be listed by typing "emctl ilint"
    emctl deploy? options can be listed by typing "emctl deploy"
    ?
    C:\Documents and Settings\Administrator>emctl status dbconsole
    Oracle Enterprise Manager 10g Database Control Release 10.2.0.1.0
    Copyright (c) 1996, 2005 Oracle Corporation.? All rights reserved.
    http://shleiyanliang:1158/em/console/aboutApplication
    Oracle Enterprise Manager 10g is running.
    ------------------------------------------------------------------
    Logs are generated in directory E:\oracle\product\10.2.0\db_1/shleiyanliang_oracle/sysman/log
    ?
    C:\Documents and Settings\Administrator>
    ?
    ------------------到此完畢!------------------
    ?
    最后一句話:
    ?
    Logs are generated in directory E:\oracle\product\10.2.0\db_1/shleiyanliang_oracle/sysman/log
    ?
    應該可以理解成database control的日志文件的所在位置吧?呵呵
    ?
    ?
    ?
    這個完成之后,當時我寫的郵箱:leiyanliang@inspur.com馬上就收到到郵件了,郵件主題如下:
    EM_預警:_嚴重:_shleiyanliang_-_Filesystem_C:\_has_only_3.35%_available...
    郵件內容如下:
    ?
    shleiyanliang
    類型=Host
    主機=shleiyanliang
    度量=Filesystem Space Available (%)
    Mount Point=C:\
    時間戳=2008-11-23 下午12時23分23秒 CST
    嚴重性=嚴重
    消息=Filesystem C:\ has only 3.35% available space
    規則名=Host Availability and Critical States
    規則所有者=SYSMAN
    ?
    實話說,這一點倒是挺好的,可以實時收到oracle自動監控的警告信息。
    *******************************************************************************************
    ?
    ?
    ?
    ?
    posted on 2009-08-28 21:56 decode360 閱讀(1850) 評論(0)  編輯  收藏 所屬分類: 07.Oracle
    主站蜘蛛池模板: 亚洲视频在线观看免费| 亚洲av色福利天堂| 国产成人精品亚洲精品| 亚洲国产美女在线观看| 国产情侣久久久久aⅴ免费| 免费夜色污私人影院在线观看| 亚洲乱码一区av春药高潮| 99久热只有精品视频免费看 | 男人扒开添女人下部免费视频| 毛片a级毛片免费观看免下载| 亚洲一级二级三级不卡| 特级aaaaaaaaa毛片免费视频| 好男人视频社区精品免费| 亚洲天堂中文字幕在线观看| 久久精品无码专区免费青青| 久久久亚洲欧洲日产国码农村| 国产在线精品观看免费观看| 久久精品国产亚洲| 曰批视频免费40分钟试看天天| 亚洲AV成人影视在线观看| 国产精品va无码免费麻豆 | 中文字幕无码免费久久9一区9| 亚洲av一综合av一区| 无码国产精品一区二区免费| 亚洲AV成人精品日韩一区| 亚洲精品WWW久久久久久| 国产精品免费观看调教网| 亚洲六月丁香六月婷婷蜜芽 | 在线观看亚洲精品福利片| 999任你躁在线精品免费不卡| 2020年亚洲天天爽天天噜| 亚洲国产精品专区在线观看| 丁香花在线视频观看免费| 亚洲人成电影网站久久| 亚洲乱码国产一区网址| 中文字幕成人免费视频| 黑人粗长大战亚洲女2021国产精品成人免费视频 | 国产在线国偷精品产拍免费| 猫咪免费观看人成网站在线| 亚洲色欲色欲综合网站| 免费观看理论片毛片|