5.2 アップグレードの実行

既存のOAMおよびOARMインストールを最新バージョンにアップグレードします。

  1. インストール・ファイルをダウンロードしたインストール・ホストで、$WORKDIR/oaaimages/oaa-installディレクトリに移動します:
    cd $WORKDIR/oaaimages/oaa-install
  2. 次のようにinstallManagementContainer.shスクリプトを実行します:
    ./installManagementContainer.sh -t ./<oaa-image>.tar

    アップグレードの進行中、様々な質問に回答して特定のタスクを実行するように求められます。次の表に、回答を求められる質問または実行を求められるタスクの一部について概説します:

    出力 アクション
    Version check failed for podman, would you like to use docker instead? [Y/N]: 「インストール・ホストの要件」に示されているように、このメッセージは、podmanがインストール・ホストにインストールされていない場合に表示されます。必要なバージョンのpodmanがない場合は、「Y」と回答してDockerの使用を選択します。
    Login into container-registry.oracle.com from browser and navigate to the location of each of the supporting images. On the right-hand side, select the Language from the drop-down menu and click Continue. Read the Oracle Standard Terms and Restrictions and click Accept to agree.
    Finally, use 'podman login' to store the credentials locally. Login successful? [Y/N]:

    ノート:

    Dockerを使用している場合は、前述の出力にdocker loginと表示されます。
    • ブラウザを起動し、https://container-registry.oracle.comにアクセスします。資格証明を使用してサインインします。「データベース」「InstantClient」の順に移動します。右側のドロップダウン・メニューから「言語」を選択し、「続行」をクリックします。オラクル社標準の条件および規制を読み、「承認」をクリックして同意します。
    • podmanを使用するかDockerを使用するかに応じて、podman loginまたはdocker loginを使用してcontainer-registry.oracle.comにログインし、プロンプトが表示されたら資格証明を入力します:
      podman login container-registry.oracle.com
      または:
      docker login container-registry.oracle.com
    Use 'podman login' to login into your private registry if you have not done so previously.Login successful? [Y/N]:

    ノート:

    Dockerを使用している場合は、前述の出力にdocker loginと表示されます
    イメージを格納するプライベート・コンテナ・イメージ・レジストリ(CIR)でログインが必要な場合は、podman loginまたはdocker loginを使用してCIRにログインし、プロンプトが表示されたら資格証明を入力します:
    podman login <container-registry.example.com>
    または:
    docker login <container-registry.example.com>
    
    Would you like to specify a kube context (otherwise 'kubernetes-admin@kubernetes' will be used)? [Y/N]: クラスタに複数のkubeコンテキストがある場合は、使用するコンテキストを選択できます。「Y」を選択した場合は、使用するコンテキストを入力する必要があります。選択されているデフォルト・コンテキストを使用する場合、またはkube構成にコンテキストが1つしかない場合は、「N」を選択します。

    ノート:

    アップグレード中に表示されるプロンプトのほとんどは字義どおりなので、前述の表にすべてのプロンプトの完全なリストは含まれていません。
  3. 管理コンテナのインストールが完了すると、次のような出力が表示されます:
    Release "oaamgmt" has been upgraded. Happy Helming!
    NAME: oaamgmt
    LAST DEPLOYED: <date>
    NAMESPACE: oaans
    STATUS: deployed
    REVISION: 2
    TEST SUITE: None
    Waiting 15 secs for OAA mgmt deployment to start...
    File /u01/oracle/scripts/settings/installOAA.properties already exists, copying file to /u01/oracle/scripts/settings/installOAA.properties.<date>
    Copying OAA properties file to oaans/oaamgmt-oaa-mgmt-7d7597c694-tzzdz:/u01/oracle/scripts/settings
    Use command 'kubectl exec -n oaans -ti oaamgmt-oaa-mgmt-7d7597c694-tzzdz -- /bin/bash' to get a shell to the OAA mgmt pod.
    From pod shell, use command 'kubectl get pods' to verify communication with the cluster.
    Continue OAA installation from the OAA mgmt pod.
    OAA management installation complete.
    
  4. 出力に従ってOAA管理ポッドに接続します。次に例を示します:
    kubectl exec -n oaans -ti oaamgmt-oaa-mgmt-7d7597c694-tzzdz -- /bin/bash
    これにより、OAA管理ポッド内のBashシェル内に移動します:
    [oracle@oaamgmt-oaa-mgmt-7d7597c694-tzzdz /]$
  5. OAA管理ポッド内でアップグレードを実行します:
    [oracle@oaamgmt-oaa-mgmt-7d7597c694-tzzdz /]$ cd ~
    [oracle@oaamgmt-oaa-mgmt-7d7597c694-tzzdz ~]$ ./OAA.sh -f installOAA.properties

    ノート:

    これにより、<NFS_CONFIG_PATH>/installOAA.propertiesファイルが使用されます。
  6. アップグレードでhelm健全性チェックまで到達すると、'<common.deployment.name>-sanity-checkを除くすべてのhelmチェックに合格することがわかります。たとえば:
    Release "oaainstall" has been upgraded. Happy Helming!
    NAME: oaainstall
    LAST DEPLOYED: Thu Apr 14 20:43:14 2022
    NAMESPACE: dev
    STATUS: deployed
    REVISION: 2
    NOTES:
    Get the Oracle Advance Authentication(OAA) Service URL by running these commands:
    Waiting for OAA installation check : oaainstall
    NAME: oaainstall
    Error: pod oaainstall-sanity-check failed
    LAST DEPLOYED: Thu Apr 14 20:43:14 2022
    NAMESPACE: dev
    STATUS: deployed
    REVISION: 2
    TEST SUITE:     oaainstall-sanity-check
    Last Started:   Thu Apr 14 20:45:01 2022
    Last Completed: Thu Apr 14 20:46:54 2022
    Phase:          Failed
    TEST SUITE:     oaainstall-email-sanity-check
    Last Started:   Thu Apr 14 20:44:14 2022
    Last Completed: Thu Apr 14 20:44:16 2022
    Phase:          Succeeded
    TEST SUITE:     oaainstall-fido-sanity-check
    Last Started:   Thu Apr 14 20:44:16 2022
    Last Completed: Thu Apr 14 20:44:18 2022
    Phase:          Succeeded
    TEST SUITE:     oaainstall-oaa-admin-ui-sanity-check
    Last Started:   Thu Apr 14 20:44:18 2022
    Last Completed: Thu Apr 14 20:44:20 2022
    Phase:          Succeeded
    TEST SUITE:     oaainstall-uaskbadb-test-connection
    Last Started:   Thu Apr 14 20:43:23 2022
    Last Completed: Thu Apr 14 20:43:43 2022
    Phase:          Succeeded
    TEST SUITE:     oaainstall-oaa-kba-sanity-check
    Last Started:   Thu Apr 14 20:44:20 2022
    Last Completed: Thu Apr 14 20:44:22 2022
    Phase:          Succeeded
    TEST SUITE:     oaainstall-uaspoledb-test-connection
    Last Started:   Thu Apr 14 20:43:43 2022
    Last Completed: Thu Apr 14 20:44:14 2022
    Phase:          Succeeded
    TEST SUITE:     oaainstall-oaa-policy-sanity-check
    Last Started:   Thu Apr 14 20:44:22 2022
    Last Completed: Thu Apr 14 20:44:24 2022
    Phase:          Succeeded
    TEST SUITE:     oaainstall-push-sanity-check
    Last Started:   Thu Apr 14 20:44:24 2022
    Last Completed: Thu Apr 14 20:44:26 2022
    Phase:          Succeeded
    TEST SUITE:     oaainstall-riskdb-test-connection
    Last Started:   Thu Apr 14 20:43:18 2022
    Last Completed: Thu Apr 14 20:43:20 2022
    Phase:          Succeeded
    TEST SUITE:     oaainstall-risk-cc-sanity-check
    Last Started:   Thu Apr 14 20:44:26 2022
    Last Completed: Thu Apr 14 20:44:28 2022
    Phase:          Succeeded
    TEST SUITE:     oaainstall-risk-sanity-check
    Last Started:   Thu Apr 14 20:44:28 2022
    Last Completed: Thu Apr 14 20:44:30 2022
    Phase:          Succeeded
    TEST SUITE:     oaainstall-uasdb-test-connection
    Last Started:   Thu Apr 14 20:43:20 2022
    Last Completed: Thu Apr 14 20:43:23 2022
    Phase:          Succeeded
    TEST SUITE:     oaainstall-sms-sanity-check
    Last Started:   Thu Apr 14 20:44:30 2022
    Last Completed: Thu Apr 14 20:44:32 2022
    Phase:          Succeeded
    TEST SUITE:     oaainstall-spui-sanity-check
    Last Started:   Thu Apr 14 20:44:32 2022
    Last Completed: Thu Apr 14 20:44:34 2022
    Phase:          Succeeded
    TEST SUITE:     oaainstall-totp-sanity-check
    Last Started:   Thu Apr 14 20:44:34 2022
    Last Completed: Thu Apr 14 20:44:59 2022
    Phase:          Succeeded
    TEST SUITE:     oaainstall-yotp-sanity-check
    Last Started:   Thu Apr 14 20:44:59 2022
    Last Completed: Thu Apr 14 20:45:01 2022
    Phase:          Succeeded
    NOTES:
    Get the Oracle Advance Authentication(OAA) Service URL by running these commands:
    Helm test failed
    この時点で、次を実行してstsをクリーン・アップする必要があります:
    1. 次のコマンドを実行して、stsを削除します:
      kubectl delete sts -l coherenceCluster=<common.deployment.name> -n <common.kube.namespace>

      ノート:

      <common.deployment.name>および<common.kube.namespace>の値は、NFS_CONFIG_PATH/installOAA.properties内にあります。
    2. 次のコマンドを実行して、stsのステータスを確認します:
      kubectl get sts -n <common.kube.namespace>
      stsのステータスにReady(n/n)と表示されたら、次のステップに進むことができます:
      NAME                    READY   AGE
      oaainstall-cache-rest   1/1     5m
      oaainstall-storage      3/3     5m
      
    3. ./OAA.sh -f installOAA.propertiesを再実行すると、今度はhelmテストがすべて合格します。
  7. アップグレードが完了したら、次のコマンドを実行してポッドを再起動します:
    kubectl get deploy -n <common.kube.namespace> -l app.kubernetes.io/instance=<common.deployment.name> -o name | xargs -n 1 kubectl rollout restart -n <common.kube.namespace>
  8. 次のコマンドを実行して、すべてのポッドが実行されていることを確認します:
    kubectl get pods -n <namespace>
    たとえば:
    kubectl get pods -n oaans
    出力は次のようになります。
    NAME                                       READY   STATUS    RESTARTS   AGE
    oaainstall-cache-rest-0                    1/1     Running   0          2m30s
    oaainstall-email-5465c65844-j2pqc          1/1     Running   0          2m36s
    oaainstall-fido-7f4c455559-g6ppz           1/1     Running   0          2m36s
    oaainstall-oaa-7b5574f9bd-wt5rf            1/1     Running   0          2m35s
    oaainstall-oaa-admin-ui-64b587dc4c-ftggm   1/1     Running   0          2m36s
    oaainstall-oaa-kba-6859456966-z6rbc        1/1     Running   0          2m36s
    oaainstall-oaa-policy-6978575cf-hrw6b      1/1     Running   0          2m36s
    oaainstall-push-7ff9c4d76b-hz7pl           1/1     Running   0          2m36s
    oaainstall-risk-6b55687d7-jpvcs            1/1     Running   0          2m36s
    oaainstall-risk-cc-99b545467-tgw62         1/1     Running   0          2m36s
    oaainstall-sms-589fc9d4b5-bfqp9            1/1     Running   0          2m36s
    oaainstall-spui-b9bfccfc9-f7rkt            1/1     Running   0          2m35s
    oaainstall-storage-0                       1/1     Running   0          23m
    oaainstall-storage-1                       1/1     Running   0          23m
    oaainstall-storage-2                       1/1     Running   0          23m
    oaainstall-totp-58987cc8d7-hmh29           1/1     Running   0          2m35s
    oaainstall-yotp-797754fcfb-f294x           1/1     Running   0          2m35s
    oaamgmt-oaa-mgmt-7d7597c694-tzzdz          1/1     Running   0          3m42s

    ノート:

    すべてのポッドでREADYステータスが1/1と表示されるまでに数分かかります。