脚本内容:
[oracle@localhost ~]$ cat
chenchao.sh #!/bin/bash
# This is shell.
export ORACLE_SID=SMTCDB
rman target /
DELETE ARCHIVELOG ALL COMPLETED BEFORE 'SYSDATE-5';
yum install -y
crosscheck archivelog all;
delete expired archivelog all;
exit
执行过程:
[oracle@localhost ~]$ ./
chenchao.sh Recovery Manager: Release 11.2.0.1.0 - Production on Sat Jan 19 09:35:23 2019
Copyright (c) 1982, 2009, Oracle and/or its affiliates. All rights reserved.
connected to target database: SMTCDB (DBID=2761098402)
RMAN>
第三句就不执行了!
这是一个专为移动设备优化的页面(即为了让你能够在 Google 搜索结果里秒开这个页面),如果你希望参与 V2EX 社区的讨论,你可以继续到 V2EX 上打开本讨论主题的完整版本。
https://www.v2ex.com/t/528497
V2EX 是创意工作者们的社区,是一个分享自己正在做的有趣事物、交流想法,可以遇见新朋友甚至新机会的地方。
V2EX is a community of developers, designers and creative people.