DataGuard已应用归档日志删除脚本
#!/bin/sh. /home/oracle/.bash_profileexport ORACLE_SID=hrdg$ORACLE_HOME/bin/sqlplus -silent "/ as sysdba" <<EOF > /home/oracle/scripts/deletehrdgarch.shset heading off;set pagesize 0;set term off;set feedback off;set linesize 32767;select 'rm -rf '||name from v$archived_log where DELETED='NO' and APPLIED='YES';exit;EOFsh /home/oracle/scripts/deletehrdgarch.shrman target /<<ENDcrosscheck archivelog all;delete noprompt expired archivelog all;exit;END[@more@]Dat
EXP-00062: invalid source statements for an object type
刚刚处理完一件小事,一个系统,今天凌晨的EXP导出是正常的,但现在导出的时候报错About to export specified users .... exporting pre-schema procedural objects and actions. exporting foreign function library names for user WDRMS . exporting PUBLIC type synonyms. exporting private type synonyms. exporting object type definitions for user WDRMS EXP-00062: invalid source statements for an object typeEXP-00000: Export terminated unsuccessfullyCause: TYPE was not found in the statements in SOURCE$ for an O
HP-UX mount Linux目录impdp导入数据库备份速度超级慢问题
由于HP-UX小机本地存储空间不足,并且,环境为RAC+ASM环境,没有剩余的空间保存数据库备份文件从一台Linux导数据至此小机环境,因此将Linux的导出目录mount至HP-UX服务器进行导入不加任何参数mount,impdp的速度非常慢,同样备份文件在Linux服务器上导入大概1小时,在HP-UX上导入花费了6个多小时,尤其是在导入那些小表(几KB)时非常缓慢,CPU SYS% 单核心达到100%修改导入参数mount -F nfs -o rw,bg,vers=3,proto=tcp,noac,hard,nointr,timeo=600,rsize=32768,wsize=32768,suid 10.199.84.33:/home/oracle/dumpdir/ /u01/oracle问题依旧
遭遇BUG 5190596,ORA-29740: evicted by member 0, group incarnation 32
Thu Jun 14 15:55:46 2012IPC Send timeout detected. Receiver ospid 15255Thu Jun 14 15:55:46 2012Errors in file /u01/app/oracle/admin/ufsa8/bdump/ufsa82_lms2_15255.trc:Thu Jun 14 15:55:48 2012Trace dumping is performing id=[cdmp_20120614155548]Thu Jun 14 15:57:29 2012Waiting for clusterware split-brain resolutionThu Jun 14 16:07:43 2012Errors in file /u01/app/oracle/admin/ufsa8/bdump/ufsa82_lmon_15247.trc:ORA-29740: evicted by member 0, group incarnation 32Thu Jun 14 16:07:44 2012LMON: terminating
Linux网卡绑定实现带宽翻倍
之前有过一篇BLOG,是介绍如何简单的将Linux两张网卡进行绑定,已实现高可用。但在之前的模式里,仅仅能实现高可用,当两个网卡中的一个失效时并不会影响服务器的联通性。但是,如果有交换机的配合,是否可以时间负载均衡,同时达到带宽翻倍的目的呢?首先,需要先明确,绑定的各种模式0 - Sets a round-robin policy for fault tolerance and load balancing. Transmissions are received and sent out sequentially on each bonded slave interface beginning with the first one available.1 - Sets an active-backup policy for fault
ORA-12161: TNS:内部错误:收到部分数据
周末将部分服务器搬迁至廊坊今天早上发现,OA测试Oracle数据库无法从北京正常连接,使用pl/sql developer连接数据库后,查询一个稍大些的表,报错ORA-12161: TNS:内部错误:收到部分数据同时,JDBC连接也出现问题java.sql.SQLException: Io exception: Bad packet typemetalink上查了一下,没有相关文章,google也没有什么收获。又只能靠猜了根据这个错误,结合周末服务器搬迁的事实,变化的因素只有网络,估计问题出在网络上。联想到之前同事李龙(lilong.itpub.net)碰到过ora-02068的错误,也是类似的情况,最后通过修改了SDU临时解决了一
SP2-0642: SQL*Plus internal error state 2130, context 0:0:0 Unsafe to proceed
从10.2.0.1版本客户端通过EZCONNECT连接一套RAC环境时报错:SQL> conn system/xxxx@10.199.87.122:1521/gppSP2-0642: SQL*Plus internal error state 2130, context 0:0:0Unsafe to proceed这个错误是因为BUG:8599395EZCONNECT Connections Error with SP2-0642: Sql*Plus Internal Error State 2130 [ID 855965.1]解决方法很简单,不要加1521端口号,或者使用11.2版本以上的客户端SQL> conn system/xxxx@10.199.87.119/gppConnected.Bug is fixed from release 11.2 onwards. Check for one off patches for your release / platfo
OPatch failed with error code 135, Given 'ocmrf' file does not exists
利用opatch打补丁时出现如下错误:2012-02-13 09:11:53: The apply patch output is Oracle Interim Patch Installer version 11.2.0.1.9 Copyright (c) 2011, Oracle Corporation. All rights reserved. Argument(s) Error... Given 'ocmrf' file does not exists. Please check the arguments and try again. OPatch failed with error code 135support.oracle.com上查到如下文章:opatch auto failed with message OPatch failed with error code 135 while applying 11.2.0.2 Bundle Patch 3 [ID 1283954.1]大意为需建立OCM conf
unable to get oracle owner for
在使用opatch打PSU时,如果不注意,经常会出现如下错误2012-02-13 10:42:25: Command output:> 数据库唯一名称: xxx> 数据库名: xxx> Oracle 主目录: /u01/app/oracle/product/11.2.0/dbhome_1> Oracle 用户: oracle> Spfile: +DATA/xxx/spfilegpp.ora> 域: > 启动选项: open> 停止选项: immediate> 数据库角色: PRIMARY> 管理策略: AUTOMATIC> 服务器池: xxx> 数据库实例: xxx1,xxx2> 磁盘组: DATA> 装载点路径: > 服务: > 类型: RAC> 数据库是管理员管理的 >En
EXP直接导出压缩问津,IMP直接导入压缩文件的方法
在10G之前,甚至在10G的Oracle环境中,有很多数据量不大,重要性不太高的系统依然采用EXP/IMP逻辑导出备份方式,或者,作为辅助备份方式。通常情况下,我们都是这样操作的:1.exp导出2.gzip压缩3.gzip解压4.imp导入这样操作有如下两个不好的地方:1.占用大量磁盘空间,磁盘剩余空间必须大于导出的,未压缩的文件大小加上压缩后的文件大小。如果设置计划任务,每日定时导出的话,很有可能因为磁盘空间不足导致备份失败。由于这种备份方式磁盘使用率的剧烈抖动,即使有监控工具,也不能很好的提供趋势分析2.系统资源浪费,在导出时,大部分都