ITPub博客

首页 > Linux操作系统 > Linux操作系统 > RMAN的"rman: can't open target"错误

RMAN的"rman: can't open target"错误

原创 Linux操作系统 作者:foxmile 时间:2008-07-24 14:40:21 0 删除 编辑
在Linux上,安装完成之后,在测试RMAN时可能会遇到如下错误:
[oracle@smsdbrac1 oracle]$ rman target /
rman: can't open target

这是由于调用的是非Oracle的RMAN的缘故:
[oracle@smsdbrac1 oracle]$ which rman
/usr/X11R6/bin/rman

在X11R6下存在一个名为rman的命令:
[oracle@smsdbrac1 bin]$ ./rman -help
rman
    [-f ]
    [-S(ource of man page passed in)] [-F(ormatted man page passed in)]
    [-r ] [-l ]<br>    [-V(olume) <colon-separated list>] [-U(RLs as hyperlinks)]<br>    [-b (show subsections)] [-k(eep head/foot)]<br>    [-n(ame of man page) <string>] [-s(ection) <string>]<br>    [-p(aragraph mode toggle)] [-t(abstops spacing) <number>]<br>    [-N(ormalize spacing, changebars)] [-y (zap hyphens toggle)]<br>    [-K (declare that page has no breaks)]<br>    [-d(iff) <file> (diff of old page source to incorporate)]<br>    [-M(essage) <text> (included verbatim at end of Name section)]<br>    [-R(ebus words for TkMan)] [-C (enable Tcl/Tk formatting)]<br>    [-o (no op)] [-O <arg> (no op with arg)]<br>    [-q(uiet--don't report warnings)] [-h(elp)] [-v(ersion)]<br>    [<filename>]<br></blockquote>修正这个问题,我们只需要在Oracle用户的环境变量下,将$ORACLE_HOME/bin放在PATH变量前就可以了:<br> <blockquote>export PATH=$ORACLE_HOME/bin:${PATH}:/usr/bin:/bin:/usr/bin/X11:/usr/local/bin<br></blockquote><br>重新登录使环境变量生效,现在Oracle能找到正确的rman了:<br> <blockquote>[oracle@smsdbrac1 oracle]$ su - oracle<br>Password: <br>[oracle@smsdbrac1 oracle]$ which rman<br>~/product/10.2.0/db/bin/rman</blockquote> <div></div> </div> <p style="clear:both;"></p> <p class="translate"> 来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/79499/viewspace-409913/,如需转载,请注明出处,否则将追究法律责任。 </p> </div> </div> <div class="preview-footer clearfix"> <!--已点赞、收藏--> <div class="icon-praise" id="praise" onclick="blogObj.praise($(this),'/praise/')"><span class="text"></span><span class="num">0</span></div> <div class="icon-collect" id="collect" onclick="blogObj.praise($(this),'/favour/')"><span class="text"></span><span class="num">0</span></div> <div class="share-group fr"> <div class="bdsharebuttonbox bdshare-button-style0-16" data-bd-bind="1522216707615"> <span class="fl">分享到:</span> <a href="javascript:;" class="bds_tsina" data-cmd="tsina" title="分享到新浪微博"></a> <a href="javascript:;" class="bds_sqq" data-cmd="sqq" title="分享到QQ好友"></a> <a href="javascript:;" class="bds_qzone" data-cmd="qzone" title="分享到QQ空间"></a> <a href="javascript:;" class="bds_weixin" data-cmd="weixin" title="分享到微信"></a> </div> <script> window._bd_share_config = { "common": { "bdSnsKey": {}, "bdText": "", "bdDesc": "", "bdMini": "", "bdMiniList": false, "bdPic": "", "bdStyle": "0", "bdSize": "32" }, "share": {"bdSize": 16} }; with (document) 0[(getElementsByTagName('head')[0] || body).appendChild(createElement('script')).src = 'http://bdimg.share.baidu.com/static/api/js/share.js?v=89860593.js?cdnversion=' + ~(-new Date() / 36e5)]; if ($(window).width() < 1320) { if ($(window).width() < 1200) { $(".sideslip").css({ "left": "20px", "margin-left": 0 }) } else { $(".sideslip").css({ "margin-left": "-590px" }) } }</script> </div> </div> <div class="article-context"> <div class="fl"> <span class="color77">上一篇:</span> <a href="http://blog.itpub.net/79499/viewspace-408742/">深度分析数据库的热点块问题</a> </div> <div class="fr"> <span class="color77">下一篇:</span> <a href="http://blog.itpub.net/79499/viewspace-417380/">create index online 与rebuild index online</a> </div> </div> <input type="hidden" id="blogId" value="409913"> <!--评论开始--> <div class="blog-comment"> <div class="new-comment"> <input type="hidden" id="hid" name="hid" value="409913"> <input type="hidden" name="_token" value="9UzuhQ2Y5eJ16TvOlljoAlKvQm1plpBca1dtE88u"> <a class="avatar" href="javascript:;"> <img src="http://blog.itpub.net/images/user_pic_default.png"></a> <!--用户未登录--> <div class="sign-container"> <span>请登录后发表评论</span> <a class="btn btn-sign"> <a class="layui-btn ml30" onclick="blog.login(event)">登录</a> </a> </div> <!--用户已登录--> <textarea placeholder="请写下你的评论…" onfocus="blogObj.textareaFocus($(this),200)" maxlength=200></textarea> </div> <div class="comment-list"> <div class="top-title"><span class="all-comment">全部评论</span> <span class="colorbb ml20"></span> </div> <div class="comment-items" id="comment_items"> <script type="text/template" id='blog_template'> <%for(var i=0;i <items.length;i++){%> <div class="comment-item"> <div class="author"> <a target="_blank" href="/<%=items[i].uid%>" class="avatar"> <img src="<%=items[i].headimg%>" alt=""> </a> <div class="info"> <div class="name"><a target="_blank" href="/<%=items[i].uid%>"><%=items[i].username%></a> <span class="fr reply-btn" onclick="blogObj.newComment($(this),'<%=items[i].username%>',<%=items[i].id%>)">回复</span></div> <div class="time colorbb"><%=items[i].createtime%></div> </div> </div> <p class="comment-wrap"><%=items[i].content%></p> <%if(items[i].items.items.length) { %> <div class="sub-comment-list"> <%for(var j=0;j<items[i].items.items.length;j++){%> <div class="sub-comment"> <div class="color77 time-reply"> <span class="time"><%=items[i].items.items[j].createtime%></span> <span class="reply-btn fr" onclick="blogObj.newComment($(this),'<%=items[i].items.items[j].username%>',<%=items[i].items.items[j].id%>)">回复</span> </div> <p><a href="/<%=items[i].uid%>"><%=items[i].items.items[j].username%></a>   回复   <a href="/<%=items[i].touid%>"><%=items[i].items.items[j].tousername%></a>: <span class="content"><%=items[i].items.items[j].content%></span></p> </div> <%}%> <%if(items[i].items.total > 5) { %> <div class="more-comment"><span class="sub-comment-count">还有<i class="count"><%=items[i].items.total-5%></i>条评论</span><span class="more-comment-btn" onclick=blogObj.loadSubComment($(this),<%=items[i].id%>) data-count=1 data-flag=true>点击查看</span></div> <%}%> </div> <%}%> </div> <%}%> </script> </div> </div> </div> <!--评论结束--> </div> <script> </script> <div class="fr w290"> <!--作者信息开始--> <!--作者信息开始--> <div class="author-info right-fixed "> <div class="head-img"> <a href="http://blog.itpub.net/79499/"><img src="http://account.itpub.net/api/avatar.php?uid=79499" alt=""></a> </div> <div class="author-name"><a href="http://blog.itpub.net/79499/">foxmile</a></div> <div class="author-intro"> </div> <p class="register-time"><span class="color77">注册时间:</span>2007-12-10</p> <ul class="tree-list clearfix"> <li> <div class="item-tt">博文量</div> <a href="http://blog.itpub.net/79499/"><span class="item-num blognum">106</span></a> </li> <li> <div class="item-tt">访问量</div> <div class="item-num blogviewnum">207444</div> </li> </ul> </div> <!--作者信息结束--> <script> var data = {uid: 79499}; $._ajax({ url: '/getAuthorInfo/', data: data, type: 'get', dataType: 'json', success: function (data) { if (data.code == 200) { var data = data.data; $(".blognum").text(data.blognum); $(".blogviewnum").text(data.visitednum); } } }); </script> <!--作者信息结束--> <!--博文推荐开始--> <div class="blog-choice right-fixed"> <h3 class="choice-title">最新文章</h3> <ul class="newul"> <li class="new-item"> <a href="http://blog.itpub.net/79499/viewspace-630824/" class="clearfix"> Linux下删除昨天的文件 </a> </li> <li class="new-item"> <a href="http://blog.itpub.net/79499/viewspace-616835/" class="clearfix"> 9208物理standby备份报错。 </a> </li> <li class="new-item"> <a href="http://blog.itpub.net/79499/viewspace-445635/" class="clearfix"> 感人的短信(转载) </a> </li> <li class="new-item"> <a href="http://blog.itpub.net/79499/viewspace-434604/" class="clearfix"> 流星夜雨 </a> </li> <li class="new-item"> <a href="http://blog.itpub.net/79499/viewspace-434603/" class="clearfix"> 一只特立独行的猪 </a> </li> <li class="new-item"> <a href="http://blog.itpub.net/79499/viewspace-434584/" class="clearfix"> 个人学习 </a> </li> <li class="new-item"> <a href="http://blog.itpub.net/79499/viewspace-433135/" class="clearfix"> stream测试 </a> </li> <li class="new-item"> <a href="http://blog.itpub.net/79499/viewspace-417380/" class="clearfix"> create index online 与rebuild index online </a> </li> <li class="new-item"> <a href="http://blog.itpub.net/79499/viewspace-417668/" class="clearfix"> 热点块处理是首先应该处理对象呢?还是优化sql。 </a> </li> <li class="new-item"> <a href="http://blog.itpub.net/79499/viewspace-417667/" class="clearfix"> 版主们去集体休假了? </a> </li> <ul> </div> <!--大牛精选结束--> </div> </div> <div class="icon-back-top" onclick="$('html,body').animate({scrollTop:0},'slow');"></div> <!--main部分结束--> <!--百度推送--> <script> (function(){ var bp = document.createElement('script'); var curProtocol = window.location.protocol.split(':')[0]; if (curProtocol === 'https') { bp.src = 'https://zz.bdstatic.com/linksubmit/push.js'; } else { bp.src = 'http://push.zhanzhang.baidu.com/push.js'; } var s = document.getElementsByTagName("script")[0]; s.parentNode.insertBefore(bp, s); })(); </script> <!--2021-10-16 07:01:29--> <!--footer部分开始--> <div class="blog-footer"> <div class="w1200 pr"> <div class="footer-links"> <a class="icon-blog icon-wx mr30"> <div class="wx-qrcode"> <img src="http://edu.itpub.net/images/qrcode.jpg" alt=""> </div> </a> <a href="https://weibo.com/itpub2001?from=myfollow_all" class="icon-blog icon-wb" target="_blank"></a> </div> <p class="footer-nav"> <a href="http://www.it168.com/bottomfile/it168.shtml" target="_blank">支持我们</a> <a href="http://www.it168.com/bottomfile/tgzn.shtml" target="_blank">作者招募</a> <a href="http://www.it168.com/bottomfile/sytk.shtml" target="_blank">用户协议</a> <a href="http://blog.itpub.net/31509949/viewspace-2157750/" target="_blank">FAQ</a> <a href="http://edu.itpub.net/contactus.html" target="_blank">Contact Us</a> <script src="https://s22.cnzz.com/z_stat.php?id=1274521965&web_id=1274521965" language="JavaScript"></script> </p> <p>北京盛拓优讯信息技术有限公司. 版权所有  <a style="color:#777777;" target="_blank" href="http://beian.miit.gov.cn">京ICP备16024965号-8</a> 北京市公安局海淀分局网监中心备案编号:11010802021510 niuxiaotong@pcpop.com 17352615567 <a style="color:#777777;" target="_blank" href="http://www.it168.com/jubao.html"> 未成年人举报专区</a></p> <p>广播电视节目制作经营许可证(京) 字第1234号 中国互联网协会会员</p> </div> </div> <!--footer部分结束--> <script> var _hmt = _hmt || []; (function() { var hm = document.createElement("script"); hm.src = "https://hm.baidu.com/hm.js?5016281862f595e78ffa42f085ea0f49"; var s = document.getElementsByTagName("script")[0]; s.parentNode.insertBefore(hm, s); })(); </script> <!-- END STAT PV --> </body> </html>