1
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

OEMにパッチを適用する(Oracle Enterprise Manager 13c Release 2)

Last updated at Posted at 2018-04-12

パッチの適用

Oracle Database や Oracle Gird Infrastructure にパッチを適用するにはOPatchユーティリティを使います。一方Oracle Enterprise Managerに対してパッチを適用するには OMSPacher ユーティリティを使います。ここでは OMSPacher の使い方と、注意点について書きます。

OMSParcherとは

OMSPatcherはOracle Enterprise Managerにパッチを適用するためのユーティリティです。${ORACLE_HOME}/OMSPatcher ディレクトリのomspatcherコマンドを実行します。
ORACLE_HOMEはOracle Enterprise Managerのホーム・ディレクトリです。例えば /u01/software/em13c/middleware等です。-helpパラメータを指定すると、利用方法が表示されます。

$ ./omspatcher -help
OMSPatcher Automation Tool
Copyright (c) 2017, Oracle Corporation.  All rights reserved.


 Usage: omspatcher [ -help ] [ -analyze ] [ command ]

            command := apply
                       rollback
                       checkApplicable
                       lspatches
                       version
                       saveConfigurationSnapshot

 <global_arguments> := -help       Displays the help message for the command.
                       -analyze    Print the actions, steps to be performed without any execution.

 example:
   'omspatcher -help'
   'omspatcher apply -help'
   'omspatcher rollback -help'
   'omspatcher checkApplicable -help'
   'omspatcher lspatches -help'
   'omspatcher saveConfigurationSnapshot -help'


OMSPatcher succeeded.

OEMにパッチを適用するには、My Oracle SupportからダウンロードしたOEMのパッチを展開し、OMSPatcherユーティリティを起動します。


$ export PATH=$ORACLE_HOME/OMSPatcher:$PATH
$ unzip 26625183.zip
...
$ cd 26625183
$ omspatcher apply
OMSPatcher Automation Tool
Copyright (c) 2017, Oracle Corporation.  All rights reserved.


OMSPatcher version : 13.8.0.0.2
OUI version        : 13.9.2.0.0
...

OMSPatcherユーティリティはいくつかの原因で失敗します。失敗メッセージが表示された場合はログ・ファイルを確認してください。
ログ・ファイルは、$ORACLE_HOME/cfgtoollogs/omspatcher/{PatchID} ディレクトリに作成されます。
ファイル名は omspatcher_{YYYY}-{MM}-{DD}{HH}-{MI}-{SS}{AM|PM}{deploy|analyze}.logです。
$ORACLE_HOME/cfgtoollogs/omspatcher/ディレクトリには opatch-{YYYY}-{MM}-{DD}_{HH}-{MI}-{SS}{AM|PM}_1.logファイルも作成されます。

OEM用のOPatchのアップデート

OMSPatcher ユーティリティは、内部的にOPatchユーティリティを使っています。このため OMSPatcher を使う場合には、OPatch のアップデートが必要な場合があります。以下のようなエラーが発生します。

[Dec 23, 2017 10:27:40 AM]   Stack Description: java.lang.RuntimeException: OMSPatcher version is not compatible to apply the given patch

OEM 用 OPatch ユーティリティは、データベースと同じく Patch# 6880880 を検索して入手します。OEM 用 OPatch のバージョンは 13.X を指定してください。

パッチの展開

ダウンロードしたOPatchを展開します。


$ unzip ../p6880880_139000_Generic.zip
Archive:  ../p6880880_139000_Generic.zip
   creating: 6880880/
  inflating: 6880880/README.txt
  inflating: 6880880/opatch_generic.jar
  inflating: 6880880/version.txt
$ cd 6880880

バージョンアップ

README.txt に従ってバージョンアップを行います。


$ java -jar 6880880/opatch_generic.jar oracle_home=$ORACLE_HOME
Launcher log file is /tmp/OraInstall2017-12-23_11-06-29AM/launcher2017-12-23_11-06-29AM.log.
Extracting the installer . . . . Done
This installer must be executed using a Java Development Kit (JDK)
but /usr/lib/jvm/java-1.8.0-openjdk-1.8.0.102-4.b14.el7.x86_64/jre is not a valid JDK Java Home.
The log is located here: /tmp/OraInstall2017-12-23_11-06-29AM/launcher2017-12-23_11-06-29AM.log.

README.txtには書いていますが、使用した Java コマンドが JRE で提供されるものだとエラーになっています。
このため、JDK に含まれる java コマンドを使用して再度挑戦します。


$ /u01/software/em13c/middleware/oracle_common/jdk/bin/java -jar 6880880/opatch_generic.jar oracle_home=$ORACLE_HOME
Launcher log file is /tmp/OraInstall2017-12-23_11-22-53AM/launcher2017-12-23_11-22-53AM.log.
Extracting the installer . . . . Done
Checking if CPU speed is above 300 MHz.   Actual 2807.831 MHz    Passed
Checking monitor: must be configured to display at least 256 colors.   Actual 16777216    Passed
Checking swap space: must be greater than 512 MB.   Actual 3967 MB    Passed
Checking if this platform requires a 64-bit JVM.   Actual 64    Passed (64-bit not required)
Checking temp space: must be greater than 300 MB.   Actual 13433 MB    Passed
Preparing to launch the Oracle Universal Installer from /tmp/OraInstall2017-12-23_11-22-53AM
Session log file is /tmp/OraInstall2017-12-23_11-22-53AM/install2017-12-23_11-22-53AM.log
Logs successfully copied to /u01/app/oraInventory/logs.
$ 

OMSPatcherの再実行

OPatch ユーティリティのバージョンアップに成功したため、OMSPatcher を実行します。
まず apply -analyze パラメーターを指定して、分析を行います。途中で OMS Server のパスワードや接続URLの入力が必要です。


$ cd 26625183
$ omspatcher apply -analyze

OMSPatcher Automation Tool
Copyright (c) 2017, Oracle Corporation.  All rights reserved.


OMSPatcher version : 13.8.0.0.2
OUI version        : 13.9.2.0.0
Running from       : /u01/software/em13c/middleware
Log file location  : /u01/software/em13c/middleware/cfgtoollogs/omspatcher/opatch2017-12-23_11-27-15AM_1.log

OMSPatcher log file: /u01/software/em13c/middleware/cfgtoollogs/omspatcher/26625183/omspatcher_2017-12-23_11-27-20AM_analyze.log

Please enter OMS weblogic admin server URL(t3s://omehost1:7102):>
Please enter OMS weblogic admin server username(weblogic):>
Please enter OMS weblogic admin server password:>



Configuration Validation: Success


Running apply prerequisite checks for sub-patch(es) "26625183" and Oracle Home "/u01/software/em13c/middleware"...
Sub-patch(es) "26625183" are successfully analyzed for Oracle Home "/u01/software/em13c/middleware"


Complete Summary
================


All log file names referenced below can be accessed from the directory "/u01/software/em13c/middleware/cfgtoollogs/omspatcher/2017-12-23_11-27-15AM_SystemPatch_26625183_1"

Prerequisites analysis summary:
-------------------------------

The following sub-patch(es) are applicable:

             Featureset   Sub-patches                                     Log file
             ----------   -----------                                     --------
  oracle.sysman.top.oms      26625183   26625183_opatch2017-12-23_11-27-20AM_1.log



Log file location: /u01/software/em13c/middleware/cfgtoollogs/omspatcher/26625183/omspatcher_2017-12-23_11-27-20AM_analyze.log

OMSPatcher succeeded.

分析が成功したら -analyze パラメーターを削除して、パッチを適用します。
途中で実行するか聞かれるため、「Y」を入力します。


$ omspatcher apply
OMSPatcher Automation Tool
Copyright (c) 2017, Oracle Corporation.  All rights reserved.


OMSPatcher version : 13.8.0.0.2
OUI version        : 13.9.2.0.0
Running from       : /u01/software/em13c/middleware
Log file location  : /u01/software/em13c/middleware/cfgtoollogs/omspatcher/opatch2017-12-23_11-31-40AM_1.log

OMSPatcher log file: /u01/software/em13c/middleware/cfgtoollogs/omspatcher/26625183/omspatcher_2017-12-23_11-31-45AM_deploy.log

Please enter OMS weblogic admin server URL(t3s://oemhost1:7102):>
Please enter OMS weblogic admin server username(weblogic):>
Please enter OMS weblogic admin server password:>



Configuration Validation: Success

<< 途中省略 >>

Do you want to proceed? [y|n]
y
User Responded with: Y

Applying sub-patch(es) "26625183"
Please monitor log file: /u01/software/em13c/middleware/cfgtoollogs/opatch/opatch2017-12-23_11-31-44AM_1.log

<< 途中省略 >>

Log file location: /u01/software/em13c/middleware/cfgtoollogs/omspatcher/26625183/omspatcher_2017-12-23_11-31-45AM_deploy.log

OMSPatcher succeeded.

$

1
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?