0

我在脚本中使用下面的代码并以自动方式运行它们

#!/bin/bash
rman "user"/"xxx"d@rman target=/ | tee run1.restore.log

run {
allocate channel ch1;
restore database;
switch datafile all;
recover database;
}

现在的问题是我的日志文件只有在完成恢复/恢复后才会更新。我想实时更新日志文件,以便跟踪恢复进度。我也尝试了 RMAN 日志文件功能,但没有运气。

4

1 回答 1

0

像这样尝试logrman 的参数:

rman target=user/pwd@dbname log='logpath.log'

或者您可以像这样在 RMAN 提示符中假脱机日志:

RMAN> SPOOL LOG to 'logpath.log'
于 2017-08-11T07:03:51.223 回答