ORA-01552 cannot use system rollback segment for non-system tablespace
今天在测试功能的时候,出现ORA-01552错误,如下: scott@CNHTM> update emp set sal=sal+1 where empno=7369;update emp set sal=sal+1 where empno=7369*ERROR at line 1:ORA-01552: cannot use system rollback segment for non-system tablespace 'TBS_1'解决过程如下: 确定undo表空间的相关参数 scott@CNHTM> show parameter undoNAME TYPE VALUE------------------------------------ ----------- ------------------------------undo_management string MANUALundo_retention integer 900undo_tablespace string查询undo表空
lsof for aix下载地址
下载地址:http://ftp.unicamp.br/pub/unix-tools/lsof/binaries/aix/用来查看aix操作系统打开多少文件的工具,对于java.net.SocketException: Too many open files这样的问题,可以用这个工具来查看现在系统打开文件数量,使用方法解压.bz2后改名为lsof(不改也可以,就是命令长,麻烦)修改为可执行 chmod u+x lsof运行 ./lsof查看打开文件数量,就加 |wc./lsof |wc--end--[@more@]
在oracle的plsql中为cursor使用绑定变量
oracle存储过程中,经常使用cursor,在cursor中使用绑定变量的时候,要使用refcursor,下面是例子: scott@CNHTM> set serveroutput on;scott@CNHTM> declare2 cur_test sys_refcursor;3 v_job emp.job%type;4 v_ename emp.ename%type;5 begin6 OPEN cur_test FOR 'SELECT job,ename FROM emp where job=:1'7 using 'SALESMAN';8 loop9 fetch cur_test10 into v_job, v_ename;11 exit when cur_test%notfound;12 dbms_output.put_line('job:'||v_job||', ename:'||v_ename);13 end loop;14 close cur_test;15 end;16 /job:SALESMAN,
检查oracle补丁是否可以滚动更新的方法
在oracl rac环境中,经常需要滚动打补丁(rolling patch),对于一个补丁是否是rolling patch,可以用如下两种方式进行检查。 1、使用opatch query命令 ora_test@oracle[/oracle/patch]> ls7662491 p7662491_10204_AIX5L.zipora_test@oracle[/oracle/patch]> cd 766*91ora_test@oracle[/oracle/patch/7662491]> opatch query . |grep rollingPatch is a rolling patch: true2、直接查看补丁包中的inventory文件 inventory文件具体位置: <patchid>/etc/config/inventory 打开inventory文件,查找 <online_rac_installab
aix6安装oracle 10g rac问题
在aix6(或aix6.1)上安装oracle10g rac过程中会出现很多问题,下面是各个问题的解决办法: 一、安装之前,运行如下命令修改oracle用户的属性 这一步骤不止aix6,aix5上也要执行,不知为何在官方文档上没有看到 chuser capabilities=CAP_PROPAGATE,CAP_BYPASS_RAC_VMM,CAP_NUMA_ATTACH oracle 二、安装crs的最后一步运行root.sh脚本之前需要修改$CRS_HOME/bin/racgvip脚本,否则会导致vip无法启动,修改方法如下: # cd $CRS_HOME/bin# cp racgvip racgvip.old# vi racgvip将221,231,371这三行中的 $5 修改为 $6 原因是AIX6.1与AIX5.3的
windows7中双击视频文件不能用终极解码播放问题的解决
windows7系统中安装终极解码,uac处于开启状态的时候:双击视频文件不能打开终极解码;运行我的播放器也没有反应;用管理员身份能打开我的播放器,但向播放器拖拽文件也不能播放。后来找到原因,是最近安装了一个win7的更新 KB976264,把这个更新卸载掉之后,终极解码运行正常,以上异常现象全部消失。[@more@]
位图索引导致的会话阻塞问题(p7)
Oracle9i&10g编程艺术:深入数据库体系结构第一章 开发成功的Oracle应用位图索引导致的会话阻塞问题(p7)在一个窗口中完成如下操作: scott@CNHTM> create table t(processed_flag varchar2(1));Table created.scott@CNHTM> create bitmap index t_idx on t(processed_flag);Index created.scott@CNHTM> insert into t values('N');1 row created.scott@CNHTM>打开另一个窗口,进行如下操作: scott@CNHTM> insert into t values('N'); 这条语句就会“挂起”,直到在第一个会话中发出commit为止。 --end-- [@more@]
Heap size 2183K exceeds notification threshold (2048K)
Windows 2000 oracle 10.2.0.1警告日志报如下提示:Mon May 17 13:54:05 2010Memory Notification: Library Cache Object loaded into SGAHeap size 2183K exceeds notification threshold (2048K)Details in trace file c:oracleproduct10.2.0adminorcludumporcl_ora_3792.trcKGL object name :XDB.XDZynXpO5DTv2jNMI2jLTZZA==原因:Oracle 10.2.0.1,隐含参数_kgl_large_heap_warning_threshold默认值为2m,过小;在10.2.0.2中默认值修改为50m;解决办法:将参数_kgl_large_heap_warning_threshold值修改为50m(或0以及其他较大值),过
Oracle RAC 安装 运行 root.sh时报Failed to upgrade Oracle Cluster Registry configuration问题的解决
CentOS 5.4 x86 Linux安装oracle rac 10.2.0.1的过程中,运行root.sh的时候报如下错误:rac1@root[/oracle/crs/10.1/bin]> cd ..rac1@root[/oracle/crs/10.1]> ./root.shWARNING: directory '/oracle/crs' is not owned by rootWARNING: directory '/oracle' is not owned by rootChecking to see if Oracle CRS stack is already configuredSetting the permissions on OCR backup directorySetting up NS directoriesFailed to upgrade Oracle Cluster Registry configuration[@more@]metalink上查询到doc id为 466673.1,按如下方
解决oracle rman报ORA-27054 NFS file system where the file is created or resides is not mounted with cor
Linux环境下,用oracle的rman通过nfs复制数据的时候报告 ORA-27054: NFS file system where the file is created or resides is not mounted with correct options 错误,详细错误信息如下: [oracle@rac1 admin]$ rman target sys/oracle@prim auxiliary /Recovery Manager: Release 10.2.0.1.0 - Production on Tue Apr 20 23:21:51 2010Copyright (c) 1982, 2005, Oracle. All rights reserved.connected to target database: DGTEST (DBID=3673368407)connected to auxiliary database: DGTEST (not mounted)RMAN> duplicate targe
oracle dbca报Exception in thread main 问题解决一例
Linux操作系统上安装oracle 10g,在启动dbca的时候报 Exception in thread "main" 错误,详细内容如下:[oracle@centos ~]$ dbcaException in thread "main"[oracle@rac1 ~]$经检查dbca的log如下:[oracle@centos ~]$ cd $ORACLE_HOME/cfgtoollogs/dbca[oracle@centos dbca]$ vi trace.logjava.lang.UnsatisfiedLinkError: /u01/app/oracle/product/10.2.0/db_1/jdk/jre/lib/i386/libawt.so: libXp.so.6: cannot open shared object file: No such file or directoryat java.lang.ClassLoader$NativeLibrary.load(Nat
oracle监听启动时报TNS-00507问题解决一例
Linux系统中,启动oracle监听的时候报如下错误:[oracle@centos ~]$ lsnrctl startLSNRCTL for Linux: Version 10.2.0.1.0 - Production on 17-APR-2010 00:25:22Copyright (c) 1991, 2005, Oracle. All rights reserved.Starting /u01/app/oracle/product/10.2.0/db_1/bin/tnslsnr: please wait...TNS-12537: TNS:connection closedTNS-12560: TNS:protocol adapter errorTNS-00507: Connection closedLinux Error: 29: Illegal seek[@more@]经过检查,发现hosts文件,内容如下:[root@centos ~]# cat /etc/hosts# Do not remove the fol
Linux安装Oracle报Checking operating system version must be redhat-3, SuSE-9, redhat-4, UnitedLinux-1.0,
在Linux系统中安装oralce的过程中,如果Linux发行版本不是oracle的推荐版本,可能会报如下错误,导致runInstaller无法完成:Checking operating system version: must be redhat-3, SuSE-9, redhat-4, UnitedLinux-1.0, asianux-1 or asianux-2Failed <<<<遇到这个问题,可以通过如下两种方式解决1、修改Linux的发行标记如在redhat-5上安装oracle的时候,需要将文件 '/etc/redhat-release'的内容由Red Hat Enterprise Linux Server release 5 (Tikanga)修改为Red Hat Enterprise Linux Server release 4 (Tikanga)2、runInsta
oracle中取得存储过程、函数等pl sql源码的方法
如果已经知道函数、存储过程、body等plsql的名称,可以通过查询user_source(dba_sourceall_source)取得其源代码演示过程如下:ora_test@oracle[/home/oracle]> sqlplus scott/tigerSQL*Plus: Release 10.2.0.1.0 - Production on Tue Mar 16 16:27:27 2010Copyright (c) 1982, 2005, Oracle. All rights reserved.Connected to:Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - ProductionWith the Partitioning, OLAP and Data Mining optionsscott@CNHTM> col text for a50;scott@CNHTM>scott@CNHTM> select b
解决 plsql dev中ORA-20000 ORU-10027 buffer overflow, limit of 2000 bytes 问题
在plsql dev中使用dbms_output.put_line的时候报如下错误 ORA-20000: ORU-10027: buffer overflow, limit of 2000 bytesORA-06512: at "SYS.DBMS_OUTPUT", line 32ORA-06512: at "SYS.DBMS_OUTPUT", line 97ORA-06512: at "SYS.DBMS_OUTPUT", line 112ORA-06512: at line 5详细日志如下: [@more@]SQL>SQL> set serveroutput on;SQL> begin2 for c in (select * from dba_objects)3 loop4 dbms_output.put_line(c.object_name);5 end loop;6 end;7 /ICOL$I_USER1... ...I_SNAP_REFTIME1MLOG_REFCO
怎么确保最终用户在Oracle数据库中只有一个会话
《Oracle 9i & 10g 编程艺术:深入数据库体系结构》第38页利用概要文件(profile)方式:1、创建一个名称为one_session的概要文件2、为概要文件one_session设置sessions_per_user=1的limit3、为用户分配one_session概要文件4、设置数据库参数resource_limit=true下面演示具体操作过程:[@more@]ora_test@oracle[/home/oracle]> sqlplus / as sysdbaSQL*Plus: Release 10.2.0.1.0 - Production on Tue Mar 16 10:12:15 2010Copyright (c) 1982, 2005, Oracle. All rights reserved.Connected to:Oracle Database 10g Enterprise Edi
TSM 5.4 ANR0110E An unexpected system date has been detected 问题的解决
登录TSM的时候,出现如下错误:ora_test@root[/opt/tivoli/tsm/server/bin]> dsmadmcIBM Tivoli Storage ManagerCommand Line Administrative Interface - Version 5, Release 4, Level 0.0(c) Copyright by IBM Corporation and other(s) 1990, 2007. All Rights Reserved.Enter your user id: adminANS1355E Session rejected: Server disabledANS8023E Unable to establish session with server.ANS8002I Highest return code was 55.经检查,在启动tsm的时候,出现“ANR0110E An unexpected system date has been detected”的错误
oracle数据库的挂起(Suspending)和恢复(Resuming)
B14231 第131页alter system suspend语句挂起数据文件和控制文件的I/O操作。挂起状态可以避免备份数据库时的IO操作。当数据库试图进入挂起状态时,允许当前活动的事务完成,新发起的事务会进入队列中。下面演示将数据库挂起以及恢复的过程[@more@]登录数据ora_test@oracle[/home/oracle]> sqlplus / as sysdbaSQL*Plus: Release 10.2.0.1.0 - Production on Thu Mar 11 09:49:32 2010Copyright (c) 1982, 2005, Oracle. All rights reserved.Connected to:Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - ProductionWith
出现ORA-01552错误别忘了查询数据库状态
在我的测试数据库上执行update语句时,报ORA-01552错误,如下: scott@CNHTM> update emp set sal=sal+1 where empno=7934;update emp set sal=sal+1 where empno=7934*ERROR at line 1:ORA-01552: cannot use system rollback segment for non-system tablespace 'TBS_1'经检查,是因为数据库处于readonly状态,检查数据库状态的语句为: sys@CNHTM> select open_mode from v$database;OPEN_MODE----------READ ONLY将数据库启动到正常状态后,再次执行更新语句,问题解决 --end-- [@more@]
oracle数据库的静默(Quiesce)状态
B14231 第129页一、静默状态(quiesce state)的用处1、在数据库静默状态的时候,只允许dba(这里dba指sysdba或sysoper)执行数据库操作;2、在oracle9i及之前,要达到静默状态的功能,只能重启数据库到限制模式(restricted mode);二、将数据库设置为静默状态的方法是使用"ALTER SYSTEM QUIESCE RESTRICTED"语句。这个语句会等待所有active session变为noactive 状态时完成。[@more@]1、用scott用户,开启一个事务,不提交ora_test@oracle[/home/oracle]> sqlplus scott/tigerSQL*Plus: Release 10.2.0.1.0 - Production