管理の再開

TimesTenClassicオブジェクトがManualInterventionRequired状態の場合は、TimesTenオペレータに、TimesTenとそのデータベースの状態を調査して、それらが正常かどうかを確認するように指示できます。レプリケート・オブジェクトの手順については、「1つのデータベースの起動について」に進みます。

レプリケートされないオブジェクトの場合、オブジェクトの.spec.ttspec.reexamineデータ項目を設定します。これにより、オブジェクトをReexamine状態にするようにTimesTenオペレータに指示されます。Reexamine状態では、TimesTenオペレータによってTimesTenとそのデータベースの状態が確認されます。正常だった場合は、オペレータによってそのオブジェクトがAllReplicasReady状態に戻されます。正常でない場合は、そのオブジェクトが再びManualInterventionRequired状態になります。

  1. ネームスペースで実行されているTimesTenClassicオブジェクトを確認します。
    kubectl get ttc

    出力は、次のようになります。

    
    NAME             STATE                        ACTIVE           AGE
    samplenorep      ManualInterventionRequired   N/A              2d1h
    ...

    レプリケートされたsamplenorepオブジェクトはManualInterventionRequired状態です。

  2. samplenorepオブジェクトの管理を再開するようにTimesTenオペレータに指示します。
    1. kubectl editコマンドを使用して、オブジェクトを編集します。

      ファイル内に.spec.ttspec.reexamineの行がある場合は、その値を変更します。現在の値と異なる必要があります。行がない場合は、行を追加して値を指定します。

      この例では、.spec.ttspec.reexamineデータ項目を追加し、値をreexamineNowに設定します。

      kubectl edit ttc samplenorep
      
      # Please edit the object below. Lines beginning with a '#' will be ignored,
      # and an empty file will abort the edit. If an error occurs while saving this file will be
      # reopened with the relevant failures.
      #
      apiVersion: timesten.oracle.com/v3
      kind: TimesTenClassic
      metadata:
      ...
      spec:
        ttspec:
          additionalMemoryRequest: 2Gi
          automaticMemoryRequests: true
          cacheCleanup: true
          createASReadinessProbe: true
          daemonLogCPURequest: 200m
          daemonLogMemoryRequest: 200Mi
          reexamine: rexamineNow
      ...
    2. ファイルを保存して閉じます。
  3. 動作を確認します。
    kubectl get events

    出力は次のようになります。表示されているのは、出力の一部です。

    27s         Normal    StateChange   timestenclassic/samplenorep      Pod samplenorep-0 state was ManualInterventionRequired, now Reexamine
    27s         Normal    StateChange   timestenclassic/samplenorep      Pod samplenorep-1 state was ManualInterventionRequired, now Reexamine
    27s         Normal    StateChange   timestenclassic/samplenorep      Pod samplenorep-2 state was ManualInterventionRequired, now Reexamine
    27s         Normal    StateChange   timestenclassic/samplenorep      TimesTenClassic was ManualInterventionRequired, now Reexamine
    22s         Normal    StateChange   timestenclassic/samplenorep      Pod samplenorep-0 state was Reexamine, now Normal
    22s         Normal    StateChange   timestenclassic/samplenorep      Pod samplenorep-1 state was Reexamine, now Normal
    22s         Normal    StateChange   timestenclassic/samplenorep      Pod samplenorep-2 state was Reexamine, now Normal
    22s         Normal    StateChange   timestenclassic/samplenorep      TimesTenClassic was Reexamine, now AllReplicasReady
    

    TimesTenオペレータにより、各TimesTenポッドの状態がManualInterventionRequiredからReexamineに変更され、TimesTenClassicオブジェクトの状態がManualInterventionRequiredからReexamineに変更されました。TimesTenオペレータにより、TimesTenとそのデータベースが調査されました。TimesTenおよびそのデータベースは正常で正しく機能しているため、TimesTenオペレータによりTimesTenポッドの状態がNormalに変更され、TimesTenClassicオブジェクトの状態がAllReplicasReadyに変更されました。