Skip to main content
  • Place orders quickly and easily
  • View orders and track your shipping status
  • Enjoy members-only rewards and discounts
  • Create and access a list of your products
  • Manage your Dell EMC sites, products, and product-level contacts using Company Administration.

NetWorker:如何還原 NMC 資料庫?

Summary: 您可以使用 NetWorker recoverpsm 命令將 NMC 資料庫還原至 nmcdb 的備份。

This article may have been automatically translated. If you have any feedback regarding its quality, please let us know using the form at the bottom of this page.

Article Content


Instructions

如果您已發現 NMC 資料庫損毀。您可以使用 NetWorker recoverpsm 命令將 NMC 資料庫還原至 nmcdb 的備份。依預設,預設伺服器保護原則內應有 NMC 伺服器備份工作流程。請確定已正確排程和設定,以完成 NMC 資料庫備份。如需 NMC 伺服器保護的詳細資訊,請參閱 NetWorker 管理指南 以及 NetWorker 命令參考指南 ,以瞭解 savepsm recoverpsm 選項。您可以在以下位置找到這些文件 https://www.dell.com/support/home/product-support/product/networker/docs

1) 首先使用 mminfo 命令確定有 NMC 資料庫備份:
語法:mminfo-avot-q client=nmc_server_name 
範例:
[root@linux1 ~]# mminfo -avot -q client=linux1.amer.lan -t "today" | grep nmcdb_stage
ClientBackupPool.001 Data Domain linux1.amer.lan 08/15/2022 02:00:17 PM 53 MB 687518690 cb full /nsr/nmc/nmcdb_stage


注意:如果您沒有上述儲存集,您就無法還原 NMC,唯一的選項就是 將其重新安裝為全新例項
 

2) 在 NMC 伺服器上開啟管理/根命令提示字元,停止 NMC GSTD 服務 (如果執行中):

Windows: net stop gstd
Linux: systemctl stop gst

注意: 使用 工作清單/工作管理員或 ps 命令來確認 gstd 服務已停止
 

3) 使用 cd 命令瀏覽至 NMC 的安裝 bin 目錄。檢查以確保 recoverpsm 命令列在此目錄內。此命令將用於復原 NMC 資料庫。

Windows:[NMC 安裝目錄\管理\GST\bin
Linux:/opt/lgtonmc/bin

4) 在 NMC 伺服器上執行 recoverpsm 命令:

語法:
recoverpsm [-s server] [-c 用戶端名稱] [-d destination] [-p 密碼短語] [-t time] [-hfO] Staging_Directory

Options:

-c 用戶端名稱

指定來源 NMC 伺服器的名稱。有關更多詳細資訊,請參閱還原。

 d 目的地

指定 recoverpsm 將 NMC 資料庫復原的目錄。使用此選項時,必須手動將資料庫檔從目標目錄複製到為 NMC 伺服器定義的資料庫目錄。確保在複製完成後保留對資料庫檔和憑據檔的相同擁有權和許可權。

  f

使用此選項可在開始恢復操作之前刪除資料庫目錄中存在的目前資料庫檔。

 h

顯示有關 recoverpsm 命令的使用資訊。

 O

使用此選項可省略資料庫認證檔案的復原作業。只有在憑據檔仍然存在並且您不想使用恢復中的憑據檔的極少數情況下,才使用此選項。

 p 密碼片語

使用此選項可在嘗試恢復 AES 加密資料庫檔時指定其他密碼短語。如需更多詳細資訊,請參閱 recover(1m)。

 s 伺服器

指定執行 NMC 資料庫備份的 NetWorker 伺服器名稱。

 時間

使用此選項可復原資料庫,作為指定的日期,以 nsrgetdate 格式。

暫存目錄

指定備份操作使用的暫存目錄。對於自動備份,請指定存儲集名稱

 範例: 

[root@linux1 bin]# ./recoverpsm -f -s linux1.amer.lan -c linux1.amer.lan -p Pa$$w0rd01 /nsr/nmc/nmcdb_stage
108157:recover: Restoring database files...
179040:recover: Step (1 of 11) for PID-6264: Recovery has been started on the client 'linux1.amer.lan'.
179733:recover: Step (2 of 11) for PID-6264: Checking if the set of exclusion files is given for the recovery of the selected files for the client 'linux1.amer.lan'.
179738:recover: Step (3 of 11) for PID-6264: Setting the server 'linux1.amer.lan' for the media database calls for the recovery of the selected files for the client 'linux1.amer.lan'.
179745:recover: Identified a file level recovery with PID 6264 to relocate to the new path '/nsr/nmc/nmcdb' for the client 'linux1.amer.lan'. Updating the total number of steps from 11 to 8.
179748:recover: Step (4 of 8) for PID-6264: Initializing a recovery job with the nsrjobd for the recovery of the selected file(s) for the client 'linux1.amer.lan'.
179749:recover: Step (5 of 8) for PID-6264: Validating and setting the relocation path '/nsr/nmc/nmcdb' for the recovery of selected file(s) for the client 'linux1.amer.lan'.
179754:recover: Step (6 of 8) for PID-6264: Initializing the file level recovery of the client 'linux1.amer.lan'.
179730:recover: Step (7 of 8) for PID-6264: Building the recovery tree of the client 'linux1.amer.lan'.
Recovering 1500 files within /nsr/nmc/nmcdb_stage/ into /nsr/nmc/nmcdb
Requesting 1500 file(s), this may take a while...
179728:recover: Initializing the recovery session with the NetWorker server 'linux1.amer.lan' to recover the selected files.
Recover start time: Mon 15 Aug 2022 02:20:37 PM PDT
179718:recover: Initializing to recover multiple streams of data from the NetWorker server 'linux1.amer.lan'.
Requesting 1 recover session(s) from server.
179714:recover: Initializing the child threads to recover the given recovery stream from the NetWorker server 'linux1.amer.lan'.
179713:recover: Initializing to set up a connection to start reading the data from the recover stream.
Enabling compressed restore for save set ID '687518690' with 'Data Domain' device path '/linux1/ClientBackupDevice01'.
Successfully established the direct file retrieval session for save set ID '687518690' with 'Data Domain' volume 'ClientBackupPool.001'.
./pgdata/backup_label
...
./pgdata/
179716:recover: Coordinating all the child recovery processes.
179717:recover: Releasing all the resources held by the recovery process.
179721:recover: All recovery streams from the NetWorker server 'linux1.amer.lan' are read successfully.
Received 1500 file(s) from NSR server `linux1.amer.lan'
Recover completion time: Mon 15 Aug 2022 02:20:39 PM PDT
179068:recover: Step (8 of 8) for PID-6264: The recovery completed successfully on the client 'linux1.amer.lan'.
108161:recover: Setting permissions for the restored database files

 

5) 在 NMC 伺服器上開啟管理/根命令提示字元,停止 NMC GSTD 服務:
Windows: net start gstd
Linux: systemctl 開始 GST

注意:使用 工作清單/工作管理員或 ps 命令來確保 gstd 服務已啟動。
 

6) 請確定您可以連線至 NMC。


如果您的使用 recoverpsm 進行 NMC 復原失敗,請聯絡 Dell EMC 支援以取得進一步協助。請注意,如果無法復原,則需要執行全新 NMC 安裝。

Additional Information

NMC 伺服器的 ..\Management\GSTD\logs\gstd.raw /opt/lgtonmc/logs/gstd.raw 可用來確認是否有 NMCDB 損毀:

範例

31581 1501512324 2 0 0 5632 6204 0 NMC-server gstd NSR warning 23 *** gstd starting at %s 1 36 24 Mon Jul 31 10:45:24 2017
NMC-server gstd NSR notice 5 %s %s 2 0 24 MM/DD/YYY HH:MM:SS.3852 0 50 Internal error: could not create database process.
NMC-server gstd NSR notice 5 %s %s 2 0 24 MM/DD/YYY HH:MM:SS.643852 0 50 Internal error: could not create database process.
NMC-server gstd NSR notice 5 %s %s 2 0 24 MM/DD/YYY HH:MM:SS.643852 0 50 Internal error: could not release database handle.
NMC-server gstd NSR notice 5 %s %s 2 0 24 MM/DD/YYY HH:MM:SS.675017 0 48 Internal error: could not stop database process.
NMC-server gstd NSR notice 5 %s %s 2 0 24 MM/DD/YYY HH:MM:SS.675017 0 54 FATAL ERROR: could not stop 'EMC GST Database Service'
NMC-server gstd NSR notice 5 %s %s 2 0 24 MM/DD/YYY HH:MM:SS.675017 0 48 Internal error: could not stop database process.
NMC-server gstd NSR notice 5 %s %s 2 0 24 MM/DD/YYY HH:MM:SS.675017 0 48 Internal error: could not stop database process.
NMC-server gstd NSR notice 5 %s %s 2 0 24 MM/DD/YYY HH:MM:SS.675017 0 54 The most recently called subfunction returned error 2.
NMC-server gstd NSR warning 2 %s 1 0 27 library error 22 os error 0
NMC-server gstd NSR warning 23 *** gstd stopping at %s 1 36 24 MM/DD/YYY HH:MM:SS

 

Article Properties


Affected Product

NetWorker

Product

NetWorker

Last Published Date

15 Aug 2022

Version

3

Article Type

How To