検索

对oracle10grac配置em,原本是非常简单的事,却花费了很长时间,记录下来,备忘。 首先是报如下错误: [oracle@node1 admin]$ emca -config dbcontrol dbSTARTED EMCA at Aug 17, 2014 9:06:47 AMEM Configuration Assistant, Version 10.2.0.5.0 Production

对oracle10grac配置em,原本是非常简单的事,却花费了很长时间,记录下来,备忘。

首先是报如下错误:

[oracle@node1 admin]$ emca -config dbcontrol db

STARTED EMCA at Aug 17, 2014 9:06:47 AM
EM Configuration Assistant, Version 10.2.0.5.0 Production
Copyright (c) 2003, 2009, Oracle.  All rights reserved.

Enter the following information:
Database SID: racdb1
Listener port number: 1521
Password for SYS user:  
Password for DBSNMP user:  
Aug 17, 2014 9:06:57 AM oracle.sysman.emcp.util.GeneralUtil initSQLEngine
WARNING: ORA-28000: the account is locked

Password for SYSMAN user:  
Aug 17, 2014 9:07:02 AM oracle.sysman.emcp.util.GeneralUtil initSQLEngine
WARNING: ORA-28000: the account is locked

Email address for notifications (optional): 
Outgoing Mail (SMTP) server for notifications (optional): 
ASM ORACLE_HOME [ /u01/app/oracle/product/11.2.0/db ]: 
ASM SID [ +ASM ]: 
ASM port [ 1521 ]: 
ASM user role [ SYSDBA ]: 
ASM username [ SYS ]: 
ASM user password:  
ASM user password:  
-----------------------------------------------------------------

You have specified the following settings

Database ORACLE_HOME ................ /u01/app/oracle/product/11.2.0/db

Local hostname ................ node1
Listener port number ................ 1521
Database SID ................ racdb1
Email address for notifications ............... 
Outgoing Mail (SMTP) server for notifications ............... 
ASM ORACLE_HOME ................ /u01/app/oracle/product/11.2.0/db
ASM SID ................ +ASM
ASM port ................ 1521
ASM user role ................ SYSDBA
ASM username ................ SYS

-----------------------------------------------------------------
Do you wish to continue? [yes(Y)/no(N)]: y
Aug 17, 2014 9:12:22 AM oracle.sysman.emcp.EMConfig perform
INFO: This operation is being logged at /u01/app/oracle/product/11.2.0/db/cfgtoollogs/emca/racdb/emca_2014-08-17_09-06-47-AM.log.
Aug 17, 2014 9:12:34 AM oracle.sysman.emcp.util.DBControlUtil secureDBConsole
INFO: Securing Database Control (this may take a while) ...
Aug 17, 2014 9:13:01 AM oracle.sysman.emcp.util.DBControlUtil secureDBConsole
INFO: Database Control secured successfully.
Aug 17, 2014 9:13:01 AM oracle.sysman.emcp.util.DBControlUtil startOMS
INFO: Starting Database Control (this may take a while) ...
Aug 17, 2014 9:17:40 AM oracle.sysman.emcp.util.PlatformInterface executeCommand
WARNING: Error executing /u01/app/oracle/product/11.2.0/db/bin/emctl start dbconsole 
Aug 17, 2014 9:17:40 AM oracle.sysman.emcp.EMConfig perform
SEVERE: Error starting Database Control
Refer to the log file at /u01/app/oracle/product/11.2.0/db/cfgtoollogs/emca/racdb/emca_2014-08-17_09-06-47-AM.log for more details.
Could not complete the configuration. Refer to the log file at /u01/app/oracle/product/11.2.0/db/cfgtoollogs/emca/racdb/emca_2014-08-17_09-06-47-AM.log for more details.
[root@node1 ~]# cat /u01/app/oracle/product/11.2.0/db/cfgtoollogs/emca/racdb/emca_2014-08-17_09-06-47-AM.log 

Aug 17, 2014 9:17:40 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:649)
	at oracle.sysman.emcp.EMDBPostConfig.invoke(EMDBPostConfig.java:227)
	at oracle.sysman.emcp.EMDBPostConfig.invoke(EMDBPostConfig.java:196)
	at oracle.sysman.emcp.EMConfig.perform(EMConfig.java:184)
	at oracle.sysman.emcp.EMConfigAssistant.invokeEMCA(EMConfigAssistant.java:494)
	at oracle.sysman.emcp.EMConfigAssistant.performConfiguration(EMConfigAssistant.java:1161)
	at oracle.sysman.emcp.EMConfigAssistant.statusMain(EMConfigAssistant.java:478)
	at oracle.sysman.emcp.EMConfigAssistant.main(EMConfigAssistant.java:426)


网上查资料,是oracle的bug。

Oracle对此的解释是:

In Enterprise Manager Database Control with Oracle Database 10.2.0.4 and 10.2.0.5, the root certificate used to secure communications via the Secure Socket Layer (SSL) protocol will expire on 31-Dec-2010 00:00:00. The certificate expiration will cause errors if you attempt to configure Database Control on or after 31-Dec-2010. Existing Database Control configurations are not affected by this issue.

If you plan to configure Database Control with either of these Oracle Database releases, Oracle strongly recommends that you apply Patch 8350262 to your Oracle Home installations before you configure Database Control. Configuration of Database Control is typically done when you create or upgrade Oracle Database, or if you run Enterprise Manager Configuration Assistant (EMCA) in standalone mode.

 

可以查看:Enterprise Manager Database Control Configuration - Recovering From Errors Due to CA Expiry on Oracle Database 10.2.0.4 or 10.2.0.5 [Video] [ID 1222603.1]

解决方法:

如果是在创建实例前就已经打了这个patch的话,那之后就不会报错了。如果是在创建实例之后才打的这个patch,那么需要执行以下:

对于单实例:
1.使用Opatch安装Patch 8350262
2.设置ORACLE_HOME and ORACLE_SID 环境变量,执行 /killDBConsole.(windows 平台省略这一步)
3.Re-secure Database Control with the following command:
/bin/emctl secure dbconsole -reset
4.Re-start Database Control with the following command:
/bin/emctl start dbconsole


对于RAC:
1.使用Opatch安装Patch 8350262, 在一个节点安装就ok了。
2.在所有节点执行:设置ORACLE_HOME and ORACLE_SID 环境变量,执行 /killDBConsole.(windows 平台省略这一步)
3.Re-secure Database Control on the first cluster node with the following command:
/bin/emctl secure dbconsole -reset
4.Re-secure Database Control on the remaining cluster nodes with the following command. Note that the -reset switch is not included with this command:
/bin/emctl secure dbconsole
5.Re-start Database Control by executing the following command on each node in the cluster:
/bin/emctl start dbconsole

打补丁后,清除并新建em,各种报错,无奈下手工删除各种数据:
Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.5.0 - 64bit Production
With the Partitioning, Real Application Clusters, OLAP, Data Mining
and Real Application Testing options

SQL> DROP public synonym SETEMVIEWUSERCONTEXT;

Synonym dropped.

SQL> DROP PUBLIC SYNONYM MGMT_TARGET_BLACKOUTS;

Synonym dropped.

SQL> drop role MGMT_USER;

Role dropped.

SQL> DROP USER MGMT_VIEW CASCADE;
DROP USER MGMT_VIEW CASCADE
          *
ERROR at line 1:
ORA-01918: user 'MGMT_VIEW' does not exist


SQL> DROP USER SYSMAN CASCADE;

User dropped.

SQL> exit

之后新建em成功,
[oracle@node1 ~]$ emca -config dbcontrol db -repos create

STARTED EMCA at Aug 17, 2014 2:58:04 PM
EM Configuration Assistant, Version 10.2.0.5.0 Production
Copyright (c) 2003, 2009, Oracle.  All rights reserved.

Enter the following information:
Database SID: racdb1
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): 
ASM ORACLE_HOME [ /u01/app/oracle/product/11.2.0/db ]: 
ASM SID [ +ASM ]: +ASM1
ASM port [ 1521 ]: 
ASM user role [ SYSDBA ]:       
ASM username [ SYS ]: 
ASM user password:  
-----------------------------------------------------------------

You have specified the following settings

Database ORACLE_HOME ................ /u01/app/oracle/product/11.2.0/db

Local hostname ................ node1
Listener port number ................ 1521
Database SID ................ racdb1
Email address for notifications ............... 
Outgoing Mail (SMTP) server for notifications ............... 
ASM ORACLE_HOME ................ /u01/app/oracle/product/11.2.0/db
ASM SID ................ +ASM1
ASM port ................ 1521
ASM user role ................ SYSDBA
ASM username ................ SYS

-----------------------------------------------------------------
Do you wish to continue? [yes(Y)/no(N)]: y
Aug 17, 2014 2:58:32 PM oracle.sysman.emcp.EMConfig perform
INFO: This operation is being logged at /u01/app/oracle/product/11.2.0/db/cfgtoollogs/emca/racdb/emca_2014-08-17_02-58-04-PM.log.
Aug 17, 2014 2:58:34 PM oracle.sysman.emcp.EMReposConfig createRepository
INFO: Creating the EM repository (this may take a while) ...
Aug 17, 2014 3:02:14 PM oracle.sysman.emcp.EMReposConfig invoke
INFO: Repository successfully created
Aug 17, 2014 3:02:24 PM oracle.sysman.emcp.util.DBControlUtil secureDBConsole
INFO: Securing Database Control (this may take a while) ...
Aug 17, 2014 3:02:50 PM oracle.sysman.emcp.util.DBControlUtil secureDBConsole
INFO: Database Control secured successfully.
Aug 17, 2014 3:02:50 PM oracle.sysman.emcp.util.DBControlUtil startOMS
INFO: Starting Database Control (this may take a while) ...
Aug 17, 2014 3:04:27 PM oracle.sysman.emcp.EMDBPostConfig performConfiguration
INFO: Database Control started successfully
Aug 17, 2014 3:04:27 PM oracle.sysman.emcp.EMDBPostConfig performConfiguration
INFO: >>>>>>>>>>> The Database Control URL is https://node1:1158/em 
<p><br>
</p>
登陆之后,发现不是rac的em,重新配置
<p><br>
</p><pre class="brush:php;toolbar:false">[oracle@node1 dbs]$ cd /u01/app/crs_home/bin
[oracle@node1 bin]$ ./cemutlo -n
crs
[oracle@node1 bin]$ sqlplus / as sysdba

SQL*Plus: Release 10.2.0.5.0 - Production on Sun Aug 17 17:18:28 2014

Copyright (c) 1982, 2010, Oracle.  All Rights Reserved.


Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.5.0 - 64bit Production
With the Partitioning, Real Application Clusters, OLAP, Data Mining
and Real Application Testing options

SQL> show parameter name

NAME				     TYPE	 VALUE
------------------------------------ ----------- ------------------------------
db_file_name_convert		     string
db_name 			     string	 racdb
db_unique_name			     string	 racdb
global_names			     boolean	 TRUE
instance_name			     string	 racdb1
lock_name_space 		     string
log_file_name_convert		     string
service_names			     string	 service1, SYS$ADMIN.TARGET_QUE
						 UE.RACDB.EPOINT.COM, service2,
						  racdb.epoint.com
SQL> 
[oracle@node1 dbs]$ emca -config dbcontrol db -repos create -cluster

STARTED EMCA at Aug 17, 2014 5:02:15 PM
EM Configuration Assistant, Version 10.2.0.5.0 Production
Copyright (c) 2003, 2009, Oracle.  All rights reserved.

Enter the following information:
Database unique name: racdb
Database Control is already configured for the database racdb
You have chosen to configure Database Control for managing the database racdb
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: 1521
Cluster name: crs
Password for SYS user:  
Password for DBSNMP user:  
Password for SYSMAN user:  
Email address for notifications (optional): 
Outgoing Mail (SMTP) server for notifications (optional): 
ASM ORACLE_HOME [ /u01/app/oracle/product/11.2.0/db ]: 
ASM port [ 1521 ]: 
ASM user role [ SYSDBA ]: 
ASM username [ SYS ]: 
ASM user password:  
-----------------------------------------------------------------

You have specified the following settings

Database ORACLE_HOME ................ /u01/app/oracle/product/11.2.0/db

Database instance hostname ................ node1
Listener port number ................ 1521
Cluster name ................ crs
Database unique name ................ racdb
Email address for notifications ............... 
Outgoing Mail (SMTP) server for notifications ............... 
ASM ORACLE_HOME ................ /u01/app/oracle/product/11.2.0/db
ASM port ................ 1521
ASM user role ................ SYSDBA
ASM username ................ SYS

-----------------------------------------------------------------
Do you wish to continue? [yes(Y)/no(N)]: y
Aug 17, 2014 5:02:38 PM oracle.sysman.emcp.EMConfig perform
INFO: This operation is being logged at /u01/app/oracle/product/11.2.0/db/cfgtoollogs/emca/racdb/emca_2014-08-17_05-02-15-PM.log.
Aug 17, 2014 5:02:40 PM oracle.sysman.emcp.util.DBControlUtil stopOMS
INFO: Stopping Database Control (this may take a while) ...
Aug 17, 2014 5:02:44 PM oracle.sysman.emcp.EMReposConfig createRepository
INFO: Creating the EM repository (this may take a while) ...
Aug 17, 2014 5:05:22 PM oracle.sysman.emcp.EMReposConfig invoke
INFO: Repository successfully created
Aug 17, 2014 5:05:27 PM oracle.sysman.emcp.EMDBCConfig instantiateOC4JConfigFiles
INFO: Propagating /u01/app/oracle/product/11.2.0/db/oc4j/j2ee/OC4J_DBConsole_node1_racdb1 to remote nodes ...
Aug 17, 2014 5:05:28 PM oracle.sysman.emcp.EMDBCConfig instantiateOC4JConfigFiles
INFO: Propagating /u01/app/oracle/product/11.2.0/db/oc4j/j2ee/OC4J_DBConsole_node2_racdb2 to remote nodes ...
Aug 17, 2014 5:05:28 PM oracle.sysman.emcp.EMDBCConfig copyAndPropagateOC4JDir
INFO: Propagating /u01/app/oracle/product/11.2.0/db/oc4j/j2ee/isqlplus_node1 to remote nodes ...
Aug 17, 2014 5:05:29 PM oracle.sysman.emcp.EMDBCConfig copyAndPropagateOC4JDir
INFO: Propagating /u01/app/oracle/product/11.2.0/db/oc4j/j2ee/isqlplus_node2 to remote nodes ...
Aug 17, 2014 5:05:34 PM oracle.sysman.emcp.EMAgentConfig deployStateDirs
INFO: Propagating /u01/app/oracle/product/11.2.0/db/node1_racdb1 to remote nodes ...
Aug 17, 2014 5:05:37 PM oracle.sysman.emcp.EMAgentConfig deployStateDirs
INFO: Propagating /u01/app/oracle/product/11.2.0/db/node2_racdb2 to remote nodes ...
Aug 17, 2014 5:05:38 PM oracle.sysman.emcp.util.DBControlUtil secureDBConsole
INFO: Securing Database Control (this may take a while) ...
Aug 17, 2014 5:06:30 PM oracle.sysman.emcp.util.DBControlUtil startOMS
INFO: Starting Database Control (this may take a while) ...
Aug 17, 2014 5:08:26 PM oracle.sysman.emcp.EMDBPostConfig performConfiguration
INFO: Database Control started successfully
Aug 17, 2014 5:08:26 PM oracle.sysman.emcp.EMDBPostConfig performConfiguration
INFO: >>>>>>>>>>> The Database Control URL is https://node1:1158/em <br>
<br>
<br>
其他问题:
<p>如果drop repos特别慢,可以尝试如下语句:<span>alter system unquiesce;</span><br>
<br>
</p>


声明
この記事の内容はネチズンが自主的に寄稿したものであり、著作権は原著者に帰属します。このサイトは、それに相当する法的責任を負いません。盗作または侵害の疑いのあるコンテンツを見つけた場合は、admin@php.cn までご連絡ください。
MySQL:世界で最も人気のあるデータベースの紹介MySQL:世界で最も人気のあるデータベースの紹介Apr 12, 2025 am 12:18 AM

MySQLはオープンソースのリレーショナルデータベース管理システムであり、主にデータを迅速かつ確実に保存および取得するために使用されます。その実用的な原則には、クライアントリクエスト、クエリ解像度、クエリの実行、返品結果が含まれます。使用法の例には、テーブルの作成、データの挿入とクエリ、および参加操作などの高度な機能が含まれます。一般的なエラーには、SQL構文、データ型、およびアクセス許可、および最適化の提案には、インデックスの使用、最適化されたクエリ、およびテーブルの分割が含まれます。

MySQLの重要性:データストレージと管理MySQLの重要性:データストレージと管理Apr 12, 2025 am 12:18 AM

MySQLは、データストレージ、管理、クエリ、セキュリティに適したオープンソースのリレーショナルデータベース管理システムです。 1.さまざまなオペレーティングシステムをサポートし、Webアプリケーションやその他のフィールドで広く使用されています。 2。クライアントサーバーアーキテクチャとさまざまなストレージエンジンを通じて、MySQLはデータを効率的に処理します。 3.基本的な使用には、データベースとテーブルの作成、挿入、クエリ、データの更新が含まれます。 4.高度な使用には、複雑なクエリとストアドプロシージャが含まれます。 5.一般的なエラーは、説明ステートメントを介してデバッグできます。 6.パフォーマンスの最適化には、インデックスの合理的な使用と最適化されたクエリステートメントが含まれます。

なぜMySQLを使用するのですか?利点と利点なぜMySQLを使用するのですか?利点と利点Apr 12, 2025 am 12:17 AM

MySQLは、そのパフォーマンス、信頼性、使いやすさ、コミュニティサポートに選択されています。 1.MYSQLは、複数のデータ型と高度なクエリ操作をサポートし、効率的なデータストレージおよび検索機能を提供します。 2.クライアントサーバーアーキテクチャと複数のストレージエンジンを採用して、トランザクションとクエリの最適化をサポートします。 3.使いやすく、さまざまなオペレーティングシステムとプログラミング言語をサポートしています。 4.強力なコミュニティサポートを提供し、豊富なリソースとソリューションを提供します。

InnoDBロックメカニズム(共有ロック、排他的ロック、意図ロック、レコードロック、ギャップロック、次のキーロック)を説明します。InnoDBロックメカニズム(共有ロック、排他的ロック、意図ロック、レコードロック、ギャップロック、次のキーロック)を説明します。Apr 12, 2025 am 12:16 AM

INNODBのロックメカニズムには、共有ロック、排他的ロック、意図ロック、レコードロック、ギャップロック、次のキーロックが含まれます。 1.共有ロックにより、トランザクションは他のトランザクションが読み取らないようにデータを読み取ることができます。 2.排他的ロックは、他のトランザクションがデータの読み取りと変更を防ぎます。 3.意図ロックは、ロック効率を最適化します。 4。ロックロックインデックスのレコードを記録します。 5。ギャップロックロックインデックス記録ギャップ。 6.次のキーロックは、データの一貫性を確保するためのレコードロックとギャップロックの組み合わせです。

貧弱なMySQLクエリパフォーマンスの一般的な原因は何ですか?貧弱なMySQLクエリパフォーマンスの一般的な原因は何ですか?Apr 12, 2025 am 12:11 AM

MySQLクエリのパフォーマンスが低いことの主な理由には、インデックスの使用、クエリオプティマイザーによる誤った実行計画の選択、不合理なテーブルデザイン、過剰なデータボリューム、ロック競争などがあります。 1.インデックスがゆっくりとクエリを引き起こし、インデックスを追加するとパフォーマンスが大幅に向上する可能性があります。 2。説明コマンドを使用してクエリ計画を分析し、オプティマイザーエラーを見つけます。 3.テーブル構造の再構築と結合条件を最適化すると、テーブルの設計上の問題が改善されます。 4.データボリュームが大きい場合、パーティション化とテーブル分割戦略が採用されます。 5.高い並行性環境では、トランザクションの最適化とロック戦略は、ロック競争を減らすことができます。

複数の単一列インデックスに対して複合インデックスをいつ使用する必要がありますか?複数の単一列インデックスに対して複合インデックスをいつ使用する必要がありますか?Apr 11, 2025 am 12:06 AM

データベースの最適化では、クエリ要件に従ってインデックス作成戦略を選択する必要があります。1。クエリに複数の列が含まれ、条件の順序が固定されている場合、複合インデックスを使用します。 2。クエリに複数の列が含まれているが、条件の順序が修正されていない場合、複数の単一列インデックスを使用します。複合インデックスは、マルチコラムクエリの最適化に適していますが、単一列インデックスは単一列クエリに適しています。

MySQLでスロークエリを識別して最適化する方法は? (スロークエリログ、Performance_schema)MySQLでスロークエリを識別して最適化する方法は? (スロークエリログ、Performance_schema)Apr 10, 2025 am 09:36 AM

MySQLスロークエリを最適化するには、slowquerylogとperformance_schemaを使用する必要があります。1。LowerQueryLogを有効にし、しきい値を設定して、スロークエリを記録します。 2。performance_schemaを使用してクエリの実行の詳細を分析し、パフォーマンスのボトルネックを見つけて最適化します。

MySQLおよびSQL:開発者にとって不可欠なスキルMySQLおよびSQL:開発者にとって不可欠なスキルApr 10, 2025 am 09:30 AM

MySQLとSQLは、開発者にとって不可欠なスキルです。 1.MYSQLはオープンソースのリレーショナルデータベース管理システムであり、SQLはデータベースの管理と操作に使用される標準言語です。 2.MYSQLは、効率的なデータストレージと検索機能を介して複数のストレージエンジンをサポートし、SQLは簡単なステートメントを通じて複雑なデータ操作を完了します。 3.使用の例には、条件によるフィルタリングやソートなどの基本的なクエリと高度なクエリが含まれます。 4.一般的なエラーには、SQLステートメントをチェックして説明コマンドを使用することで最適化できる構文エラーとパフォーマンスの問題が含まれます。 5.パフォーマンス最適化手法には、インデックスの使用、フルテーブルスキャンの回避、参加操作の最適化、コードの読み取り可能性の向上が含まれます。

See all articles

ホットAIツール

Undresser.AI Undress

Undresser.AI Undress

リアルなヌード写真を作成する AI 搭載アプリ

AI Clothes Remover

AI Clothes Remover

写真から衣服を削除するオンライン AI ツール。

Undress AI Tool

Undress AI Tool

脱衣画像を無料で

Clothoff.io

Clothoff.io

AI衣類リムーバー

AI Hentai Generator

AI Hentai Generator

AIヘンタイを無料で生成します。

ホットツール

Dreamweaver Mac版

Dreamweaver Mac版

ビジュアル Web 開発ツール

MantisBT

MantisBT

Mantis は、製品の欠陥追跡を支援するために設計された、導入が簡単な Web ベースの欠陥追跡ツールです。 PHP、MySQL、Web サーバーが必要です。デモおよびホスティング サービスをチェックしてください。

SAP NetWeaver Server Adapter for Eclipse

SAP NetWeaver Server Adapter for Eclipse

Eclipse を SAP NetWeaver アプリケーション サーバーと統合します。

VSCode Windows 64 ビットのダウンロード

VSCode Windows 64 ビットのダウンロード

Microsoft によって発売された無料で強力な IDE エディター

PhpStorm Mac バージョン

PhpStorm Mac バージョン

最新(2018.2.1)のプロフェッショナル向けPHP統合開発ツール