sysresv
sysresv: error while loading shared libraries: libclntsh.so.10.1: cannot open shared object file: No such file or directory[@more@][oracle@TestServer ~]$ sysresvsysresv: error while loading shared libraries: libclntsh.so.10.1: cannot open shared object file: No such file or directory[oracle@TestServer ~]$export LD_LIBRARY_PATH=$ORACLE_HOME/lib[oracle@TestServer ~]$ sysresvIPC Resources for ORACLE_SID "orcl10" :Shared Memory:ID KEY32769 0x0000000065538 0
ORA-16038: 日志 1 序列号 137 无法归档
ORA-16038: 日志 1 序列号 137 无法归档ORA-19809: 超出了恢复文件数的限制ORA-00312: 联机日志 1 线程 1:'D:ORACLEPRODUCT10.2.0ORADATAORCLREDO01.LOG'[@more@]SYS@orcl AS SYSDBA >startupORACLE 例程已经启动。Total System Global Area 612368384 bytesFixed Size 1290892 bytesVariable Size 192941428 bytesDatabase Buffers 411041792 bytesRedo Buffers 7094272 bytes数据库装载完毕。ORA-16038: 日志 1 序列号 137 无法归档ORA-19809: 超出了恢复文件数的限制ORA-003
ORA-00257: archiver error. Connect internal only, until freed.
RMAN-04004: 来自恢复目录数据库的警告: ORA-00257: archiver error. Connect internal only, until freed.[@more@]数据库在导入数据库的时候一直停留在导入一个大表那里,后来查看数据库的后台日志:ORA-19815: WARNING: db_recovery_file_dest_size of 2147483648 bytes is 100.00% used, and has 0 remaining bytes available.原来是db_recovery_file_dest目录给用完了,想删除一些过期的归档日志,结果连接rman的时候错:RMAN-04004: 来自恢复目录数据库的警告: ORA-00257: archiver error. Connect internal only, until freed.因为ca
How to find obsolete parameters using by database
How to find obsolete parameters using by database[@more@]可以查询:v$obsolete_parameter试图SQL> select * from v$obsolete_parameter;NAME ISSPECIFIED---------------------------------------------------------------- -----------spin_count FALSEuse_ism FALSElock_sga_areas FALSEinsta
Get Server IP address
Get Server IP address[@more@]可以用utl_inaddr来获得数据库的主机名和地址SQL> desc utl_inaddrElement Type -------------------- --------- UNKNOWN_HOST EXCEPTION UNKNOWN_HOST_ERRCODE CONSTANT GET_HOST_NAME FUNCTION GET_HOST_ADDRESS FUNCTION SQL> select utl_inaddr.get_host_name,utl_inaddr.get_host_address from dual;GET_HOST_NAME GET_HOST_ADDRESS----------------- -----------------TestServer 127.0.0.1SQL>
Easy Connect String 10g
Easy Connect String 10g[@more@]Ex :sqlplus scott/tiger@<SERVERIP>:1521/<DBNAME> Set up EZCONNECT in the sqlnet.ora file as follows: NAMES.DIRECTORY_PATH = (TNSNAMES, EZCONNECT)要求客户端是10g或10g以上的版本,如果端口号是1521的话,可以省略Ex :sqlplus /scott/tiger@<SERVERIP>/<DBNAME> Ex:sqlplus scott/tiger@192.168.1.254/orcl
oracle的not like的一个例子
oracle的not like的一个例子[@more@]有个表t 的一个字段userid其中里面带"_",譬如:SQL>select * from t;USERID -----------xiaguan_aj xiaguan_sb zenxin xiaguan_hb xiaguan_yg请问我想查询userid不带"_"的userid.怎么我就查询不出来呢?SQL>select * from t where userid not like '%_%';查询结果为空.但是里面有一个zenxin的结果啊?请教了一下高手,原来是要转义一下:SQL> select * from t where userid not like '%=_%' escape '=';
How to set multiple events
How to set multiple events[@more@]in spfile: the name is 'event' and values are quoted then comma separated as in: ALTER SYSTEM SET event='10235 trace name context forever, level 2','27072 trace name errorstack level 3' COMMENT='TEST' SCOPE=SPFILE; If bad syntax, you will get ORA-2194 at next database restart. so double check and copy old spfile just in case. You can remove all events with: ALTER SYSTEM RESET EVENT SCOPE=SPFILE SID='*' ; in memory: the name is 'events' and values are column-sepa
Trace a user's session from its beginning
Trace a user's session from its beginning[@more@]If you have to trace a "fast" user session, (for example, initiated by clicking on a button on the GUI of an application), you don't have enough time to query V$SESSION to initiate a trace for the session. A very easy way is to use a database "on logon" trigger; here is an example: CREATE OR REPLACE TRIGGER ON_LOGON_SCOTT AFTER LOGON ON DATABASE WHEN ( USER = 'SCOTT' ) BEGIN execute immediate 'alter session set events ''10046 t
快速查看表空间的使用情况
通过sm$ts_free,sm$ts_used,sm$ts_avail快速查看表空间使用情况[@more@]通过sys用户登录SQL>conn / as sysdbaSQL> select tablespace_name,sum(bytes)/1024/1024 "size(M)" from sm$ts_avail group by tablespace_name;TABLESPACE_NAME size(M)------------------------------ ----------ASB 1424CDT_LSTD 1024DEV 1024DRSYS 20INDX 20RBS 50RCPJ 1024SMIS_DATA 1024SYSTEM 280TEMP 179.375TOOLS 10TS_TCMS_DATA 1024USERS 2013 rows selectedSQL> select tablespace_name,sum(bytes)/1024/1024 "size(M)" f
查看ORACLE_HOME的另外一个方法
查看ORACLE_HOME的另外一个方法[@more@][root@TestServer conf]# ps -ef |grep oraoracle 8867 1 0 16:08 ? 00:00:00 ora_pmon_orcloracle 8869 1 0 16:08 ? 00:00:00 ora_mman_orcloracle 8871 1 0 16:08 ? 00:00:00 ora_dbw0_orcloracle 8873 1 0 16:08 ? 00:00:00 ora_lgwr_orcloracle 8875 1 0 16:08 ? 00:00:00 ora_ckpt_orcloracle 8877 1 0 16:08 ? 00:00:00 ora_smon_orcloracle 8879 1 0 16:08 ? 00:00:00 ora_reco_
oracle 8i的EXP-00008错误
EXP-00008: ORACLE error 6553 encounteredORA-06553: PLS-561: character set mismatch on value for parameter 'SHORTNAME'EXP-00000: Export terminated unsuccessfully[@more@]SQL>conn / as sysdbaSQL> col view_name format a15SQL> col text format a60SQL> set long 10000000SQL> select text from dba_views where view_name = ' EXU81JAVT'TEXT------------------------------------------------------------SELECT obj#FROM sys.obj$WHERE name = 'oracle/aurora/rdbms/DbmsJava'AND type# = 29AND owner# = 0A
grep的-E参数(查看alter_ORCL.log)
grep的-E参数用法[@more@]查看oracle日志的错误和警告$cat alter_ORCL.log |grep -E 'ORA-|WARNING:' ORA-00313: open failed for members of log group 1 of thread 1ORA-00312: online log 1 thread 1: '/oracle8/oradata/dtgdb/redo03.log'ORA-27037: unable to obtain file statusORA-00313: open failed for members of log group 2 of thread 1ORA-00312: online log 2 thread 1: '/oracle8/oradata/dtgdb/redo02.log'ORA-27037: unable to obtain file statusORA-00313: open failed for members of log group 3 of thread 1ORA-00
ORA-600 [2252] Occurs During Alter Database Open
ORA-600 [2252] Occurs During Alter Database Open[@more@]Subject: ORA-600 [2252] Occurs During Alter Database OpenDoc ID: Note:253977.1 Type: PROBLEMLast Revision Date: 19-OCT-2004 Status: PUBLISHEDSymptom(s)After shutdown of the database you receive the following error during alter database open: ora-600 [2252]You did not restore the database before receiving this error.Cause:The system date is lower than the date of the shutdown. While opening the database, Oracle compares the given SCN value w
tar的一个应用
tar的一个应用[@more@]1,需要打包应用包war中所以的jsp文件和jar文件,不需要其他的文件.先find 一下#cd webmod.war#find . -name "*.jsp" -o -name "*.jar" > list#tar -cvzf webmod.tgz -T list这样打包生成的文件就只有jsp和jar格式的文件了2,打包除了doc和help目录下的文件#cd /jboss/service/default/deploy/#tar --exclude HRWebProject.war/doc --exclude HRWebProject.war/help --czvf HRWebProject.tgz HRWebProject.war3,只备份某个目录下面的几个子目录#tar -cf test.tar home/oracle /home/rar4,解
ORPHAN (no passwd entry)
crontab 不能自动运行,且日志报ORPHAN (no passwd entry)[@more@]crontab 不能自动运行,且日志报ORPHAN (no passwd entry)原来的crontab -l 显示的结果为12 18 * * * /usr/local/bin/firewall.sh start0 0 * * * /usr/local/bin/backoracle.sh结果到时候以后,就是不自动运行这些脚本。但是在命令行执行这些脚本没有问题,能正常运行。后来查看/var/log/cron日志的时候,有好多的ORPHAN (no passwd entry)错误!这个错误是由执行oracle备份脚本引起的Mar 2 09:59:00 Asbapp crond[20903]: (tmp.28003) ORPHAN (no passwd entry) Mar 2 09:5
获取操作系统信息
获取操作系统信息[@more@]解决方法:sysreport是一个脚本程序,用来收集系统信息,比如运行的是什么核心?加载了什么驱动?还有各种服务的配置文件。 要能够运行sysreport,必需要先安装sysreport软件包。如果该系统已经在红帽网络中注册,则可以通过up2date命令安装。 up2date sysreport 如果系统没有在红帽网络(RHN)中注册,则可以使用RPM命令安装光盘上sysreport软件包。 rpm -Uvh sysreport-<version>.src.rpmcd /usr/src/redhat/SPECSrpmbuild -bd sysreport.speccd /usr/src/redhat/BUILDcd sysreport-1.3.13-1/ ./sysreportT
怎么从红帽企业Linux2.1上迁移用户帐号到红帽企业Linux3或4上?
怎么从红帽企业Linux2.1上迁移用户帐号到红帽企业Linux3或4上?[@more@]怎么从红帽企业Linux2.1上迁移用户帐号到红帽企业Linux3或4上?解决方法:迁移用户帐号不是一件容易的任务。你需要确保文件所有权保持完整,密码和所属组保持原样。需要考虑的文件应该是,比如,用户的主目录和email。 在红帽企业Linux2.1和3上,好的情况是他们有相似的处理用户帐号的方法。加入系统的用户的UID和GID总是从500开始计算,一直增加,除非被覆盖(参见man页的useradd)。这里,我们假设你使用/etc/passwd,/etc/group和/etc/shadow来做身份认证。这样迁移
oracle的一个00600错误
ORA-00600: internal error code, arguments: [keltnfy-ldmInit], [46], [1], [], [], [], [], [][@more@]ORA-00600: internal error code, arguments: [keltnfy-ldmInit], [46], [1], [], [], [], [], []原因是:修改了主机名以后,忘记修了/etc/hosts文件redhat linux应该同时修改/etc/hosts和/etc/sysconfig/network文件中的hostname的值.如果忘了将/etc/hosts中127.0.0.1对应的机器修改成/etc/sysconfig/network文件中的一样,将会导致上面描述的错误。
Linux中统计用户登录失败的次数
Linux中统计用户登录失败的次数[@more@]#vi /etc/pam.d/system-auth --添加auth required pam_tally.so no_magic_rootaccount required pam_tally.so deny=2 no_magic_root--deny=2表示错误密码尝试次数为2次测试一下,用putty登陆,输入错误的用户名和密码#faillog -u rootUsername Failures Maximum Latestroot 2 0 1 10:37:17 +0800 2007 on 192.168.100原文地址:http://www.redhatmagazine.com/2007/02/20/how-do-i-use-the-faillog-program-to-track-failed-login-attempts