Oracle® Hierarchical Storage Manager and StorageTek QFS Software 文件系统恢复指南 发行版 6.0 E56781-02 |
|
上一页 |
下一页 |
一旦您已完成配置和数据恢复,应执行最后两项任务:
如果您已禁用归档和回收,请立即重新启用这些功能:
以 root
用户身份登录到文件系统元数据服务器。
root@solaris:~#
在文本编辑器中打开 /etc/opt/SUNWsamfs/archiver.cmd
文件,向下滚动到当您开始恢复工作时添加到该文件中的第一个 wait
指令。
在示例中,使用 vi
编辑器:
root@solaris:~#vi /etc/opt/SUNWsamfs/archiver.cmd
# Configuration file for Oracle HSM archiving file systems #----------------------------------------------------------------------- # General Directives archivemeta = off examine = noscan #----------------------------------------------------------------------- # Archive Set Assignmentswait
fs = samqfs1 logfile = /var/adm/samqfs1.archive.log all . 1 -norelease 15m 2 -norelease 15m fs = samqfs2 logfile = /var/adm/samqfs2.archive.log all . ...
要启用归档,请删除当您开始恢复工作时添加到该文件中的每个 wait
指令。保存文件并关闭编辑器。
在本示例中,我们删除所添加的单个 wait
指令:
root@solaris:~# vi /etc/opt/SUNWsamfs/archiver.cmd
...
#-----------------------------------------------------------------------
# Archive Set Assignments
fs = samqfs1
logfile = /var/adm/samqfs1.archive.log
all .
1 -norelease 15m
2 -norelease 15m
3 -norelease 15m
fs = samqfs2
...
:wq
root@solaris:~#
接下来,启用回收。
以 root
用户身份登录到文件系统元数据服务器。
root@solaris:~#
在文本编辑器中打开 /etc/opt/SUNWsamfs/recycler.cmd
文件,向下滚动到当您开始恢复工作时添加到该文件中的第一个 -ignore
参数。
在示例中,使用 vi
编辑器:
root@solaris:~#vi
/etc/opt/SUNWsamfs/recycler.cmd
# Configuration file for Oracle HSM archiving file systems #----------------------------------------------------------------------- logfile = /var/adm/recycler.log no_recycle tp VOL[0-9][2-9][0-9] library1 -hwm 95 -mingain 60-ignore
删除当您开始恢复工作时所添加的每个 -ignore
参数。然后保存该文件并关闭编辑器。
在本示例中,我们在 Oracle HSM 配置 library1
中只有一个库:
root@solaris:~# vi /etc/opt/SUNWsamfs/recycler.cmd # Configuration file for Oracle HSM archiving file systems #----------------------------------------------------------------------- logfile = /var/adm/recycler.log no_recycle tp VOL[0-9][2-9][0-9]library1
-hwm 95 -mingain 60-ignore
:wq
root@solaris:~#
在修改后的配置文件中检查错误。使用命令 archiver -lv
检查 archiver.cmd
文件并运行初始化命令 sam-fsd
。更正所有错误。
在示例中,配置文件是正确的:
root@solaris:~#archiver -lv
Reading '/etc/opt/SUNWsamfs/archiver.cmd'. 1: #----------------------------------------------------------------------- 2: # General Directives 3: archivemeta = off 4: examine = noscan 5: #----------------------------------------------------------------------- 5: # Archive Set Assignments 7: fs = samqfs1 ... .sort: path root@solaris:~#sam-fsd
Trace file controls: sam-amld /var/opt/SUNWsamfs/trace/sam-amld ... Would start sam-archiverd() Would start sam-stagealld() Would start sam-stagerd() Would start sam-amld() root@solaris:~#
使用恢复的配置文件重新配置 Oracle HSM 软件。使用命令 samd config
。
归档和回收进程恢复。
root@solaris:~# samd config
如果要从服务器问题或者一个或多个文件系统丢失或损坏中恢复,请保存新恢复的 Oracle HSM 配置。
否则,请在此处停止。
如果您在恢复工作过程中已更改 Oracle HSM 配置,则应立即再次备份该配置。
以 root
用户身份登录到文件系统元数据服务器。
root@solaris:~#
运行 samexplorer
命令,并创建 SAMreport。将其保存在包含您的备份配置信息的目录中。使用命令 samexplorer
path
/
hostname
.
YYYY
MM
DD
.
hh
mm
z
.
tar.gz
,其中 path
是所选目录的路径,hostname
是 Oracle HSM 文件系统主机的名称,YYYY
MM
DD
.
hh
mm
z
是日期和时间戳。
默认文件名是 /tmp/SAMreport.
hostname
.
YYYY
MM
DD
.
hh
mm
z
.tar.gz
。在本示例中,我们已经拥有用于保存 SAMreport 的目录,即 /zfs1/sam_config/
。因此我们在此目录中创建相应报告:
root@solaris:~#samexplorer
/zfs1/sam_config/explorer/
server1
.20140430.1659MST.tar.gz
Report name: /zfs1/sam_config/explorer/samhost1.20140430.1659MST.tar.gz Lines per file: 1000 Output format: tar.gz (default) Use -u for unarchived/uncompressed. Please wait............................................. Please wait............................................. Please wait...................................... The following files should now be ftp'ed to your support provider as ftp type binary. /zfs1/sam_config/explorer/samhost1.20140430.1659MST.tar.gz
将配置文件复制到其他文件系统。
/etc/opt/SUNWsamfs/
mcf
archiver.cmd
defaults.conf
diskvols.conf
hosts.
family-set-name
hosts.
family-set-name
.local
preview.cmd
recycler.cmd
releaser.cmd
rft.cmd
samfs.cmd
stager.cmd
inquiry.conf
samremote
# SAM-Remote server configuration filefamily-set-name
# SAM-Remote client configuration filenetwork-attached-library
# Parameters filescripts/*
# Back up all locally modified files/var/opt/SUNWsamfs/
备份所有磁带库目录数据,包括历史记录所维护的数据。对于每个目录,使用命令 /opt/SUNWsamfs/sbin/dump_cat -V
catalog-file
,其中 catalog-file
是目录文件的路径和名称。将输出重定向到新位置中的 dump-file
。
在示例中,我们将 library1
的目录数据转储到文件 library1cat.dump
,该文件在独立的已挂载 NFS 的文件系统 zfs1
上的一个目录中:
root@solaris:~#dump_cat -V
/var/opt/SUNWsamfs/catalog/library1cat
>
\/zfs1/sam_config/20140513/catalogs/
library1cat.dump
请复制 Oracle HSM 安装和配置过程中所修改的系统配置文件。其中可能包括:
/etc/
syslog.conf
system
vfstab
/kernel/drv/
sgen.conf
samst.conf
samrd.conf
sd.conf
ssd.conf
st.conf
/usr/kernel/drv/dst.conf
将作为 Oracle HSM 配置的一部分而创建的任何定制 shell 脚本和 crontab
条目复制到选定的子目录中。
例如,如果创建了 crontab
条目来管理恢复点创建,现在就保存其副本。
记录当前安装的软件(包括 Oracle Oracle HSM、Solaris 和 Solaris Cluster(如果适用))的修订级别,并将信息副本保存在所选子目录的 readme
文件中。
在选择的子目录中,保存任何新下载的 Oracle Oracle HSM、Solaris 和 Solaris Cluster 软件包的副本,以便下次需要时可以快速恢复软件。