11g裡建立OEM時的一個坑“emca -config dbcontrol db -repos recreate”
11g裡建立OEM時的一個坑
關於11g的OEM的更多內容: http://blog.itpub.net/26736162/viewspace-2029565/
一般來說,新建一個庫後都有SYSMAN使用者,但是當沒有SYSMAN使用者時,建立EM時可以使用“emca -config dbcontrol db -repos recreate”來建立,注意這裡的repos是有s的,SYSMAN使用者不能手工建立:
-- 刪除EM drop user sysman cascade; drop user mgmt_view cascade; drop role mgmt_user; --重建EM emca -config dbcontrol db -repos recreate --emca -config dbcontrol db -repo recreate 該命令雖然可以執行,但是該命令是錯誤的,當SYSMAN不存在時會報很多錯誤 select username,account_status from dba_users where username in ('SYSMAN','MGMT_VIEW'); alter user dbsnmp identified by lhr account unlock; lsnrctl status
如果使用 錯誤命令 “emca -config dbcontrol db -repo recreate”來建立EM,那麼當SYSMAN不存在時會報如下的錯誤:
[oracle@rhel6lhr ~]$ emca -config dbcontrol db -repo recreate STARTED EMCA at Jul 19, 2019 9:47:38 PM EM Configuration Assistant, Version 11.2.0.3.0 Production Copyright (c) 2003, 2011, Oracle. All rights reserved. Enter the following information: Database SID: ora11g Listener port number: 1521 Listener ORACLE_HOME [ /u01/app/oracle/product/11.2.0/dbhome_1 ]: Password for SYS user: Password for DBSNMP user: oracle Password for SYSMAN user: oracle Jul 19, 2019 9:47:53 PM oracle.sysman.emcp.util.GeneralUtil initSQLEngineLoacly WARNING: ORA-01017: invalid username/password; logon denied Jul 19, 2019 9:47:53 PM oracle.sysman.emcp.util.GeneralUtil initSQLEngineLoacly WARNING: ORA-01017: invalid username/password; logon denied Invalid username/password. Password for SYSMAN user: Password for SYSMAN user: Jul 19, 2019 9:48:28 PM oracle.sysman.emcp.util.GeneralUtil initSQLEngineLoacly WARNING: ORA-01017: invalid username/password; logon denied Jul 19, 2019 9:48:29 PM oracle.sysman.emcp.util.GeneralUtil initSQLEngineLoacly WARNING: ORA-01017: invalid username/password; logon denied Invalid username/password. Password for SYSMAN user: oracle Email address for notifications (optional): Outgoing Mail (SMTP) server for notifications (optional): ----------------------------------------------------------------- You have specified the following settings Database ORACLE_HOME ................ /u01/app/oracle/product/11.2.0/dbhome_1 Local hostname ................ rhel6lhr Listener ORACLE_HOME ................ /u01/app/oracle/product/11.2.0/dbhome_1 Listener port number ................ 1521 Database SID ................ ora11g Email address for notifications ............... Outgoing Mail (SMTP) server for notifications ............... ----------------------------------------------------------------- Do you wish to continue? [yes(Y)/no(N)]: y Jul 19, 2019 9:48:36 PM oracle.sysman.emcp.EMConfig perform INFO: This operation is being logged at /u01/app/oracle/cfgtoollogs/emca/ora11g/emca_2019_07_19_21_47_37.log. Jul 19, 2019 9:48:36 PM oracle.sysman.emcp.DatabaseChecks performReposChecks WARNING: ORA-00942: table or view does not exist Jul 19, 2019 9:48:36 PM oracle.sysman.emcp.DatabaseChecks performReposChecks SEVERE: The existing database you have specified has Grid Control repository. This operation is not supported. [oracle@rhel6lhr ~]$ emca -config dbcontrol db -repo recreate STARTED EMCA at Jul 19, 2019 9:48:54 PM EM Configuration Assistant, Version 11.2.0.3.0 Production Copyright (c) 2003, 2011, Oracle. All rights reserved. Enter the following information: Database SID: ora11g Listener port number: 1521 Listener ORACLE_HOME [ /u01/app/oracle/product/11.2.0/dbhome_1 ]: Password for SYS user: oracle Password for DBSNMP user: oracle Password for SYSMAN user: oracle 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 ................ /u01/app/oracle/product/11.2.0/dbhome_1 Local hostname ................ rhel6lhr Listener ORACLE_HOME ................ /u01/app/oracle/product/11.2.0/dbhome_1 Listener port number ................ 1521 Database SID ................ ora11g Email address for notifications ............... Outgoing Mail (SMTP) server for notifications ............... ----------------------------------------------------------------- Do you wish to continue? [yes(Y)/no(N)]: y Jul 19, 2019 9:49:12 PM oracle.sysman.emcp.EMConfig perform INFO: This operation is being logged at /u01/app/oracle/cfgtoollogs/emca/ora11g/emca_2019_07_19_21_48_54.log. Jul 19, 2019 9:49:12 PM oracle.sysman.emcp.DatabaseChecks performReposChecks WARNING: ORA-00942: table or view does not exist Jul 19, 2019 9:49:12 PM oracle.sysman.emcp.DatabaseChecks performReposChecks SEVERE: The existing database you have specified has Grid Control repository. This operation is not supported.
這些錯誤很莫名其妙的,所以,正確的做法是用命令“emca -config dbcontrol db -repos recreate”, repos是有s的 。
關於EM的一些其它內容:
Oracle Enterprise Manager
Description:
------------
This component will appear in dba_registry when you have configured a db console in your database. This is available from Oracle rdbms 10gR1 onwards. Please note that for this component you need to have Oracle Enterprise Manager installed at binaries level.
Schema:
---------
DBSNMP, SYSMAN, MGMT_VIEW (11gR1 and 11gR2 only)
How to Install and De-Install:
------------------------------
Note.278100.1 How To Drop, Create And Recreate DB Control In A 10g Database
(This note is applicable to 11gR1 and 11gR2)
Please note that reconfiguring the dbconsole will remove the existing settings in dbconsole. So after dropping and recreating the em repository you need to redo all the em related setting.
About Me
........................................................................................................................ ● 本文作者:小麥苗,部分內容整理自網路,若有侵權請聯絡小麥苗刪除 ● 本文在itpub、部落格園、CSDN和個人微 信公眾號( xiaomaimiaolhr )上有同步更新 ● 本文itpub地址: http://blog.itpub.net/26736162 ● 本文部落格園地址: http://www.cnblogs.com/lhrbest ● 本文CSDN地址: https://blog.csdn.net/lihuarongaini ● 本文pdf版、個人簡介及小麥苗雲盤地址: http://blog.itpub.net/26736162/viewspace-1624453/ ● 資料庫筆試面試題庫及解答: http://blog.itpub.net/26736162/viewspace-2134706/ ● DBA寶典今日頭條號地址: http://www.toutiao.com/c/user/6401772890/#mid=1564638659405826 ........................................................................................................................ ● QQ群號: 230161599 (滿) 、618766405 ● 微 信群:可加我微 信,我拉大家進群,非誠勿擾 ● 聯絡我請加QQ好友 ( 646634621 ) ,註明新增緣由 ● 於 2019-07-01 06:00 ~ 2019-07-31 24:00 在西安完成 ● 最新修改時間:2019-07-01 06:00 ~ 2019-07-31 24:00 ● 文章內容來源於小麥苗的學習筆記,部分整理自網路,若有侵權或不當之處還請諒解 ● 版權所有,歡迎分享本文,轉載請保留出處 ........................................................................................................................ ● 小麥苗的微店 : https://weidian.com/s/793741433?wfr=c&ifr=shopdetail ● 小麥苗出版的資料庫類叢書 : http://blog.itpub.net/26736162/viewspace-2142121/ ● 小麥苗OCP、OCM、高可用網路班 : http://blog.itpub.net/26736162/viewspace-2148098/ ● 小麥苗騰訊課堂主頁 : https://lhr.ke.qq.com/ ........................................................................................................................ 使用 微 信客戶端 掃描下面的二維碼來關注小麥苗的微 信公眾號( xiaomaimiaolhr )及QQ群(DBA寶典)、新增小麥苗微 信, 學習最實用的資料庫技術。
........................................................................................................................ |
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/26736162/viewspace-2651198/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- oracle 11g OEM在哪裡找到???Oracle
- 建立 UIWindow 被忽視的一個坑UI
- app.config的坑APP
- 學習openresty時,nginx的一個坑RESTNginx
- nodejs request module裡的json引數的一個坑NodeJSJSON
- springcloud-config-client的那些坑SpringGCCloudclient
- laravel 踩坑 env,configLaravel
- linux安裝nginx時遇到的一個坑LinuxNginx
- 一個@Transaction哪裡來這麼多坑?
- 如何在Kubernetes裡建立一個Nginx serviceNginx
- 如何在Hybris commerce裡建立一個media物件物件
- foreach使用引用時的一個坑-foreach原始碼分析原始碼
- 初學 GoLang 遇到的一個關於時間的坑...Golang
- python中的一個現象,db.commit和db.commit()PythonMIT
- oracle 11g 分割槽表建立(年月日周時分秒)Oracle
- [提問交流]讀取資料庫中的配置 這個 DB_CONFIG_DATA 是什麼?資料庫
- 建立一個雙模式跨執行時的 JavaScript 包模式JavaScript
- 分享一個composer的坑
- 一個私有協議檔案DB 的解析.協議
- DROP AND RECREATE ONLINE REDOLOG FILES
- 如何批量刪除指定的GitHub ReposGithub
- PHP Composer 的一個小坑PHP
- Golang Recover的一個小坑Golang
- Python裡的那些坑Python
- Javascript裡instanceo的坑JavaScript
- Android一個小知識點: 多個介面同時使用一個資源佈局的時候,修改背景需要注意的坑Android
- Nginx 轉發時的一個坑,運維居然讓我背鍋!!Nginx運維
- 【上接 9 年前的一篇文章】動態建立控制元件的一個坑和解決方案控制元件
- 建立一個物件的集合物件
- DB2 SSL配置遇到的一個問題DB2
- SAP Business Application Studio 裡建立一個基於 CAP 模型的 OData 服務APP模型
- oracle db link的檢視建立與刪除Oracle
- DB2建立資料庫,建立表空間DB2資料庫
- beego ORM 建立模型,生成表。遇到的一些坑。GoORM模型
- 使用Golang時遇到的一些坑Golang
- oracle 11G RAC的建立(VM虛擬環境)Oracle
- Array.prototype.splice 的一個坑
- go select case的一個小坑Go