ページの先頭行へ戻る
Site Recovery for Red Hat(R) OpenStack Platform V1.0 運用ガイド
FUJITSU Software

第9章 コマンドリファレンス

本項ではコマンドリファレンス について説明します。

rcx_srosp_setup

DRの準備をするコマンドです。

パス

/opt/FJSVrcxsr/bin/rcx_srosp_setup

ログ

/var/opt/FJSVrcxsr/log/rcxsr.log

rcx_srosp_setup sruser

SRユーザーを作成します。

usage: rcx_srosp_setup sruser [-h] [--password <PASSWORD>]
引数 説明
PASSWORD SRユーザーのパスワード。指定できる文字種、文字列の長さはOpenStackの環境に依存します。

rcx_srosp_setup trust-create

SRユーザー(rcxsrosp)に対して、trustor_usertrustor_projectに対して持っているすべての権限を委譲するためのtrustを作成します。

usage: rcx_srosp_setup trust-create [-h] <trustor_user_token> <trustor_project> <trustor_user>
引数 説明
trustor_user_token 権限を委譲するユーザーのtoken(trustor_projectで指定したプロジェクトに対して有効なもの)
trustor_project 権限を委譲するユーザーのプロジェクトid
trustor_user 権限を委譲するユーザーのユーザーid

各引数の取得方法

本手順は、以下の条件で実施してください。

  • 手順実施サイト : 本番サイト、災対サイト
  • 手順実施サーバ : メイン作業用コントロールノード
  • 手順実施ユーザー : インフラ管理者
  • 手順実施回数 : 1回

admin権限を持つOpenStackユーザーのクレデンシャルファイル(ここではopenrcとします)を読み込みます。 クレデンシャルファイルについては「OpenStackコマンドの実行について」を参照してください。

source openrc
  • trustor_user_tokenの取得

    以下のコマンドを実行し、指定したユーザーのtokenを取得します。

    openstack --os-username <user_name> --os-project-name <project_name> --os-password <password> token issue -c id -f value
  • trustor_projectの取得

    以下のコマンドを実行し、該当プロジェクトのidを確認します。

    openstack project list
  • trustor_userの取得

    以下のコマンドを実行し、該当ユーザーのidを確認します。

    openstack user list --project <project_id>

終了ステータス

以下の終了ステータスが返されます。

終了ステータス 意味
0 正常に処理されました。
1 エラーが発生しました。
2 引数に誤りがありました。

rcx_srosp_setup volume-info

RECのコピーペア作成に必要な情報を表示します。

usage: rcx_srosp_setup volume-info [-h] <volume_id> [<volume_id> ...]
引数 説明
volume_id REC設定対象のボリュームid。最大で260個まで指定できます。

終了ステータス

以下の終了ステータスが返されます。

終了ステータス 意味
0 正常に処理されました。
1 エラーが発生しました。
2 引数に誤りがありました。

# rcx_srosp_setup volume-info 9994e466-6137-483d-8d06-9b7b19c387fc e252ae8a-0fa6-4aaf-bcde-2ac1f33ed37c
ID                                   No     Size(GB) Name
9994e466-6137-483d-8d06-9b7b19c387fc 0x0024        1 FJosv_FdQnpHrPOiAqtj9U5gD1ng=
e252ae8a-0fa6-4aaf-bcde-2ac1f33ed37c 0x0023        1 FJosv_fWenaPtH1t2FdibGQ3VmtA=

rcx_srosp_backup

バックアップをするコマンドです。

パス

/opt/FJSVrcxsr/bin/rcx_srosp_backup

ログ

/var/opt/FJSVrcxsr/log/rcxsr.log

rcx_srosp_backup begin

バックアップを開始します。

usage: rcx_srosp_backup begin [-h] <backup_name> [--incremental]
引数 説明
backup_name バックアップを識別する一意な名前。半角の英大文字、英小文字、数字、"_"、"-"が使用可能です。文字列の長さは1バイト以上128バイトまでです。増分バックアップ時にはフルバックアップで指定したbackup_nameを指定してください。
--incremental 増分バックアップを取得する場合に指定します。

終了ステータス

以下の終了ステータスが返されます。

終了ステータス 意味
0 正常に処理されました。
1 エラーが発生しました。
2 引数に誤りがありました。

rcx_srosp_backup end

バックアップを終了します。

usage: rcx_srosp_backup end [-h]

終了ステータス

以下の終了ステータスが返されます。

終了ステータス 意味
0 正常に処理されました。
1 エラーが発生しました。
2 引数に誤りがありました。

rcx_srosp_backup system

データベースをバックアップします。

usage: rcx_srosp_backup system [-h]

終了ステータス

以下の終了ステータスが返されます。

終了ステータス 意味
0 正常に処理されました。
1 エラーが発生しました。
2 引数に誤りがありました。

rcx_srosp_backup instance

NovaインスタンスにアタッチされたCinderボリュームのバックアップをインスタンスごとに実施します。

usage: rcx_srosp_backup instance [-h] <instance_id> [--start]
引数 説明
instance_id バックアップ対象のインスタンスid
--start バックアップ取得後にインスタンスを起動

終了ステータス

以下の終了ステータスが返されます。

終了ステータス 意味
0 正常に処理されました。
1 エラーが発生しました。
2 引数に誤りがありました。

rcx_srosp_backup volume

NovaインスタンスにアタッチされたCinderボリュームのバックアップをインスタンスごとに実施します。

<volume_id>が指定されなかった場合、インスタンスにアタッチされていないすべてのボリュームのバックアップを一括で実施します。

<volume_id>が指定された場合、インスタンスにアタッチされていないボリュームの場合はバックアップを実施します。 <volume_id>に指定されたボリュームがインスタンスにアタッチされたボリュームの場合は、rcx_srosp_backup instanceを実行してください。

usage: rcx_srosp_backup volume [-h] [<volume_id> ...]
引数 説明
volume_id バックアップ対象のボリュームid

終了ステータス

以下の終了ステータスが返されます。

終了ステータス 意味
0 正常に処理されました。
1 エラーが発生しました。
2 引数に誤りがありました。

rcx_srosp_backup info

バックアップ情報を表示します。

usage: rcx_srosp_backup info [-h]

終了ステータス

以下の終了ステータスが返されます。

終了ステータス 意味
0 正常に処理されました。
1 エラーが発生しました。
2 引数に誤りがありました。

# rcx_srosp_backup info
   backup name: site01-2017-06-06
     backup id: 02274e7a41808f9df06c670a74f55a3b
    created at: 2017-06-06 07:12:31
     instances: 3 / 485
       volumes: 6 / 988
rec_info_files:
  - recinfo_copy_pair_<コピーグループ名1>
  - recinfo_copy_pair_<コピーグループ名2>
  ...(略)...
  - recinfo_source_volumes
  - recinfo_destination_volumes

rcx_srosp_stash

検証環境を退避・復旧するコマンドです。

パス

/opt/FJSVrcxsr/bin/rcx_srosp_stash

ログ

/var/opt/FJSVrcxsr/log/rcxsr.log

rcx_srosp_stash system

検証環境のシステム情報を退避します。

usage: rcx_srosp_stash system [-h]

終了ステータス

以下の終了ステータスが返されます。

終了ステータス 意味
0 正常に処理されました。
1 エラーが発生しました。
2 引数に誤りがありました。

rcx_srosp_stash pop system

検証環境のシステム情報を復旧します。

usage: rcx_srosp_stash pop system [-h]

終了ステータス

以下の終了ステータスが返されます。

終了ステータス 意味
0 正常に処理されました。
1 エラーが発生しました。
2 引数に誤りがありました。

rcx_srosp_stash instance

検証環境のインスタンスを退避します。

usage: rcx_srosp_stash instance [-h]

終了ステータス

以下の終了ステータスが返されます。

終了ステータス 意味
0 正常に処理されました。
1 エラーが発生しました。
2 引数に誤りがありました。

rcx_srosp_stash pop instance

検証環境のインスタンスを復旧します。

usage: rcx_srosp_stash pop instance [-h]

終了ステータス

以下の終了ステータスが返されます。

終了ステータス 意味
0 正常に処理されました。
1 エラーが発生しました。
2 引数に誤りがありました。

rcx_srosp_stash info

退避した環境情報を表示します。

usage: rcx_srosp_stash info [-h]

終了ステータス

以下の終了ステータスが返されます。

終了ステータス 意味
0 正常に処理されました。
1 エラーが発生しました。
2 引数に誤りがありました。

# rcx_srosp_stash info
stash name: current_stash
  stash id: 1a63cae51f954fcfa5b62152838bf3fe
created at: 2017-06-06 13:24:19
 instances: 30 / 92
   volumes: 63 / 203

rcx_srosp_restore

リストアをするコマンドです。

パス

/opt/FJSVrcxsr/bin/rcx_srosp_restore

ログ

/var/opt/FJSVrcxsr/log/rcxsr.log

rcx_srosp_restore begin

リストアを開始します。

usage: rcx_srosp_restore begin [-h] <backup_name>
引数 説明
backup_name バックアップを識別する一意な名前です。

終了ステータス

以下の終了ステータスが返されます。

終了ステータス 意味
0 正常に処理されました。
1 エラーが発生しました。
2 引数に誤りがありました。

rcx_srosp_restore end

リストアを終了します。

usage: rcx_srosp_restore end [-h]

終了ステータス

以下の終了ステータスが返されます。

終了ステータス 意味
0 正常に処理されました。
1 エラーが発生しました。
2 引数に誤りがありました。

rcx_srosp_restore system

データベースをリストアします。

usage: rcx_srosp_restore system [-h]

終了ステータス

以下の終了ステータスが返されます。

終了ステータス 意味
0 正常に処理されました。
1 エラーが発生しました。
2 引数に誤りがありました。

rcx_srosp_restore volume

すべてのボリュームをリストアします。

usage rcx_srosp_restore volume [-h]

終了ステータス

以下の終了ステータスが返されます。

終了ステータス 意味
0 正常に処理されました。
1 エラーが発生しました。
2 引数に誤りがありました。

rcx_srosp_restore instance

インスタンスをリストアします。

usage rcx_srosp_restore instance [-h] <instance_id> [--from-backup]
引数 説明
instance_id リストア対象のインスタンスid (リストア前のインスタンスid)
--from-backup Cinderバックアップからリストア

終了ステータス

以下の終了ステータスが返されます。

終了ステータス 意味
0 正常に処理されました。
1 エラーが発生しました。
2 引数に誤りがありました。