(回到Blog入口)

Oracle数据库 归档

2007年12月19日

压力测试和回退方案的重要

上周某客户2个数据库分别做了分区和升级。
我做了分区的主要工作,方案是应用开发dba设计的。
升级是oracle原厂工程师做的。

升级后,cache buffer chain 争用严重(有500多个session等待这个事件),cpu使用100%,性能底下,最了回退;

分区后,buffer busy wait等待严重,经statspack分析后确认是大量全表扫描引起,创建索引后解决。

数据库升级这个我没有参与,估计没有做压力测试。
分区是做了压力测试的,但是从后来实际情况看,压力测试没有达到效果。
这个数据库有很多关联应用,可能部分压力测试没有做到。
在检查分区方案时,特别提出要做回退方案。虽然后来没有回退,但是如果没有回退方案,当时在处理时压力就更大。


这2个事情说明回退,即对原方案或者原环境的备份,是非常重要的。

简单的说,备份是非常重要的。

2007年11月19日

说说这次主机迁移

就是16号晚上6点开始到17号早上7点多才结束的主机迁移。

当前环境有3台主机,1台备机,是1备3,共4个节点。
这四个节点迁移到新的四个节点,主要工作在存储和小机,简单说就是把存储从原来的4个节点挂到新的4个节点。

数据库组的任务就是修改数据库环境,迁移后数据库启动正常,应用正常。
简单的想,就是spfile中相应路径修改一下。

本来计划是凌晨1:40完成,后来到7点多才完成,主要原因有:
1.预先对工作分析得不透,环境检查得不够。
在备用机上本来还有实例在运行,这个处理不在计划内。
2.部分工作没有考虑到
比如使用dblink,必须同步复制到新环境,侦听的配置
3.应用测试的时间没有考虑
因为是热备,测试热备需要花时间,测试时出现问题的处理,这个时间都没有考虑到。
4.额外发现的问题的处理时间

把事情做好,真的是要方方面面考虑到。
很重要的是在事情开始前,把步骤列好,check。确认步骤没有少。

这次7点多离开,12点多又接到电话,可能是归档空间满引起业务停止。

又匆匆赶过去,结果有人通过vpn上去解决了。后来了解到是系统组的人忘记把归档路径的权限设置为oracle了。

这个问题一方面是系统组漏了,另一方面,我当时应该检查alert文件,否则可以提早发现的。

当时系统组一起干活的兄弟,感觉做事也很细心,比较有章法,不过做了13个小时,谁都晕了。
难保不会漏个东西。所以说,在做之前,把东西想周全是最好,另外,如果有变化,先修改计划文档,再动手做,避免做的过程出现问题,导致漏掉其他内容。有点类似oralce的先保存到redo,也有点类似iso9001里面的“写下要做的”。

这里还是觉得iso9001的思路很好:
写下要做的;
按所写的做;
写下所做的。

好的习惯,有时候比技术本身更重要。

2007年11月15日

整理oracle学习case

最近没有写oracle的帖子,一个是没有特别值得写的,一个是这段时间在整理oracle的学习case。
把oracle整个知识架构理出来,比较重要的知识点,以测试/实战/解释的方式做出来。
目的有几个:把知识点都补全,通过实践加深理解,加强记忆。

基本上把oracle知识框架分为
BA--base knowledge
BK--backup and recovery
HA-- high availability, dataguard, partition, rac
TS-- trouble shooting
PF-- performance tuning
IN-- install
NE--10g 11g new feathers.

bug list, 各个最常用版本,各个平台的bug清单。

工作开始了一段时间,记个符号。

2007年09月17日

Oracle数据库历史

今天有兴趣看看oracle各个版本什么时候发布的

google了一下,查到这样一些网页,
http://www.oracle.com/corporate/story.html
http://www.oracle.com/corporate/history.html
http://orafaq.com/faq/what_is_oracles_history

摘录其中oracle产品的发布日期:

1984 oracle4
1985 oracle5
1988 oracle6


1992 oracle7
1997 oracle8
1998 oracle for linux
1999 oracle 8i

2000 oracle 8i Release2
2001 oracle 9i
2002 oracle 92 Release2
2004 oracle 10g
2005 oracle 10g Release2
2007 oracle 11g

简单回顾一下自己oracle的使用历史:
从oracle 8.0.7开始使用,开发的系统需要支持oracle, informix, sybase数据库,oracle是在linux,solaris上运行的。当时安装还是文字界面,在linux上安装时有一些bug,
经常在linuxforum 上发帖。 应该是在redhat6上。
后来在redhat 7上安装8i,做了一个游戏从mysql到oracle8i的迁移。对oracle9i,在redhat上使用了9i rac, 是一个OID (oracle internet directory)系统。后来从suse-oracle10g rac开始, 各种平台,随着做oracle服务, 开始在各种版本,各种平台的oracle提供服务。

2007年08月18日

关于归档日志空间满这件事

这件事遇到已经不是一次两次了,而是, 我处理的客户就有5个,有大客户,大得有几十个数据库,有小客户,只有一台pc server。
可见这种问题发生的普遍性,貌似没有技术的事情,但是遇到就是大问题,因为生产停止了。

总结起来,不外乎几种原因:

1.业务异常
这好像是最主要的原因
2.dba不懂得删(确实有)


业务异常的情况,有次遇到是9204的bug,做报表时使用了临时表,而9204里面有个bug,临时表的redo 比普通表还大好多(正常情况临时表的redo很少),这样看报表时归档日志那个快,一分钟100M,甚至删都来不及。
还有个客户,就是我最近遇到的这个,这个系统比较复杂,一个数据库上有几个应用,不同的应用的数据是不同的开发商维护的(乱),有个应用的开发商前几天删数据,导致归档日志狂增,增到来不及备份释放空间,结果就挂了。
另外一个大客户,前面几乎每周都有这个事情,也是业务突然有变化,归档空间不够大,发生了几次。

dba不懂的,我只遇到一个,真是不懂。

解决方法:原因找到了,问题就好解决,改扩大空间的扩大空间,改增加备份频率的增加备份频率。

但是救急的解决方法很重要,比较简单的,就是把归档日志移动到其他目录(不要删)。
然后 archive log start;启动归档进程,业务马上恢复。
如果空间比较多,而且是aix的,那么可以临时调大归档空间,最容易了。(一般大客户才有这个条件);
如果把文件移走了,后面rman备份时找不到,也是个问题。
在备份前要先change archivelog all crosscheck,让oracle检查一下哪些归档日志实际不存在,就不会去备份,否则因为找不到而备份失败。 后面可以再通过change ... available把移走的归档日志状态改回来,下次备份的时候,这些归档日志还可以被备份。

另外有个方法,我没有测试过,frank提出来的。就是备份归档日志时,把最后切换归档日志那句去掉,这样不会因为没有空间导致切换日志失败,导致备份归档日志失败。因为一般备份归档日志后都会删除这些归档日志,这样也可以解决空间不足的问题。

对这些问题,主要是每天检查归档日志备份是否成功,以及业务是否有变化。

2007年07月29日

关于应用可扩展性

使用oracle数据库开发应用,对于应用的扩展性,一直以为绑定变量是最重要的。
现在知道,连接方式也是非常重要的。

有2个应用和oracle文档的说明让我认识到这点。2个应用有点类似,号称3层架构,使用了websphere中间件,但是客户端直接连接数据库,没有使用连接池。
每处理一条业务,要连接3次数据库,处理完成就断开。

每秒要处理2条业务,数据库连接7次左右。

结果是:
一个应用发生过2次telnet不上的情况,虽然业务还在跑,当时没有办法连接上去看系统性能,估计是内存耗尽导致。
另外一个应用每秒处理业务逐渐降低,具体原因还不是很清楚,但是在改用连接池后,性能提高了有10倍。

看看oracle官方文档的说明:
Oracle9i Database Performance Planning Release 2 (9.2)
Part Number A96532-01

Good Database Connection Management

Connecting to the database is an expensive operation that is highly unscalable. Therefore, the number of concurrent connections to the database should be minimized as much as possible. A simple system, where a user connects at application initialization, is ideal. However, in a Web-based or multitiered application, where application servers are used to multiplex database connections to users, this can be difficult. With these types of applications, design efforts should ensure that database connections are pooled and are not reestablished for each user request.

2007年06月02日

最近学习oracle的感受

很久没有更新了,工作忙是一个借口,也是一个理由。

前面给客户培训oracle,连续5天,够累的, 不过正如frank所说, 培训对于讲师的收获可能更大。
信夫!

通过讲课,对oracle的很多知识点可以明确,理论可以更好得贯穿起来,对于提高oracle水平非常有帮助。

另外,这段时间客户的事情确实比较多:数据库升级(oracle 8i已经不提供补丁支持);因为
DDL引起数据库挂起,引起后续性能问题; 数据库备份恢复测试等等,不一而足。好像5月是事故多发期。后面陆续得:数据库迁移测试,压力测试,等等。

不过随着对oracle知识面扩大和知识点深入了解,各种问题的分析和解决基本心中有数, 思路明确,应该可以在预估的时间内解决问题。

2007年05月11日

oracle基础有恶补的需要

前些日子花了些时间看asktom的归档的资料,感觉颇有收获。觉得好多都是书上看不到的,实战的东西。看多了,总觉得很凌乱,很松散,没有形成一个体系。
前几天将031,仔细回读了一下教材,发现很有收获。真是每次读每次都有收获。
后面好多oracle基础文档要再尽快过一遍,趁热打铁。不然过几天可能又没有感觉,没有兴趣了。

2007年03月31日

应用决定性能

最近接触了几个调优的case, 很有感触。

自己没有开发人员的客户,上线的业务系统,或者由于选择的开发商不是很有经验,或者没有很好的前期检查、测试, 都是上线后发现问题很多,系统负载大,影响业务运行。

有开发人员的,对于选择产品,上线前测试都多多少少做了一些工作。
在系统架构,数据库开发方面都不会很差,可能在业务运行一段时间后,因为数据量问题引起性能下降,需要调优。
自己没有开发人员的,在引进系统方面不是很了解,或许别的原因(比如上级指定产品),导致使用的产品开发不完善,架构不合理,系统上线就面临问题。

这些都说明压力测试是多么重要,无论用什么方式获得的软件产品, 在上线前,只要充分进行压力测试,问题都可以发现。

想想以前开发的软件,都是简单的c/s,哪儿有考虑并发,压力?
现在一般都是三层架构,并发压力大,如果不充分考虑各种因素,开发完成后,可能发现距离上线还有很大差距。

也许这些也是数据库顾问可以做的工作。

2007年03月14日

网络故障导致standby 数据库没有获得归档日志解决一例

primary 数据库+standby数据库。
因网络原因arch日志没有发送到standby服务器,数据不同步。
primary上每天rman备份,归档日志在备份后删除。
action:
1.从rman备份restore arch log
在standby上:
SQL>select name, sequence#,applied from v$archived_log;
查到最后一个应用的arch log,检查最后获得arch的时间。确定需要restore的arch的时间范围。
比如是4天前故障。
到primary上。
rman执行
RUN
{
allocate channel c1 type disk;
SET ARCHIVELOG DESTINATION TO '/arch/tmp';
RESTORE ARCHIVELOG time between 'sysdate - 4' and 'sysdate';
release channel c1;
}
把归档日志解到一个临时目录/arch/tmp
2.把arch log 传到standby 服务器
ftp上传到arch目录
3.在standby上register 日志
从第一个applied为NO的arch开始,逐个执行
SQL>alter database register physical logfile '/path/to/arch/archfile.dbf'
...

在register后,每个arch日志将依次被应用。

2007年01月13日

参加oracle数据库高级技术合作伙伴培训有感

1.参加培训的同学的求知欲强烈。出现了占座,甚至第一天出现抢座的现象。午饭后回来发现座位已经被占,而占者面无愧色。

2.培训的场所太差。 培训开始时听oracle销售(估计是培训的发起者)解释 ,开始报名的不多,后面突然增加了很多。所以前面准备的不够。百乐门5楼大会议室。是长的,后面的同学基本看不清楚。

3.看到了久仰的oracle技术资深技术顾问

4.感觉我们现在做的工作或和oracle资深技术顾问很象啊。

不过他们服务的是大客户,国税,移动之类的,数据量比较大,压力更大。

而我们服务的是中小客户。

他们数据库调优,故障处理比较多,数据库安装比较少。我们是安装,调优,故障都有。

使用的技术他们掌握的深入,全面,可以对某个业务,需求使用正确的技术。 这点非常重要。oracle技术非常多,但是使用合适的技术才能达到最优。否则可能比sqlserver,mysql也不如。

再有就是都是顶着压力干活。他们也没有一条绿色通道,可以通过oracle开发马上解决,遇到具体问题也是要查metalink, 通过metalink联系后面的人。不过他们metalink能查到oracle内部的资料,这个是一个很大的优势,讲课的时候老师给我们show了一些资料,上面赫然写着oracle internal only.

5. 掌握oracle架构,熟悉oracle最成熟的各项技术,根据客户的需求使用最恰当的技术,对做oracle服务来说,可以最大限度减少主动错误。

6.数据库调优方面,statspack报告,老师大概提了几个要重点关注的,但是没有很深的讲解。他的statspack的时间跨度是10个小时。从asktom看,一般30分钟最好。这个好像是见仁见智。

7.老师知识面广泛,也是从开发转向纯oracle。估计有45左右。也是风趣幽默的人。

8.开始讲课前老师就说,他讲的东西打印给大家了,其它的一些oracle内部资料不能发给大家,所以不能从他那里拷贝东西。蛮好,省得后面别人要再解释。不过实际他讲课时应用了较多没有打印的资料,还好我主要是听,自己记,没有以来教材。教材编排很乱。

--------

2006年12月26日

Where to find Step-By-Step RAC setup guides

Where to find Step-By-Step RAC setup guides:

Posted by Alejandro Vargas, 3/29/06 at 2:56:16 AM. Where to find Step-By-Step RAC setup guides: - Wednesday, March 29, 2006

RAC Step-By-Step Installation on IBM RS/6000 see Note 199457.1 . RAC Step-By-Step Installation on LINUX see Note 184821.1 .

RAC Step-By-Step Installation on COMPAQ OPEN VMS see Note 180012.1 .

RAC Step-By-Step Installation on SUN CLUSTER V3 see Note 175465.1 .

RAC Step-By-Step Installation on WINDOWS 2000 or NT see Note 178882.1 .

RAC Step-By-Step Installation on HP TRU64 UNIX CLUSTER see Note 175480.1 .

RAC Step-By-Step Installation on HP-UX see Note 182177.1 .

--------

2006年12月25日

如何查找/下载oracle文档?

http://blogs.oracle.com/AlejandroVargas/stories/storyReader$14

10gr2:

http://www.oracle.com/pls/db102/homepage?remark=tahiti

9ir2:

http://www.oracle.com/pls/db92/homepage?remark=tahiti

--------

2006年12月16日

32bit linux为何oracle 只能使用1.75G SGA(转)


~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~ RedHat Advanced Server (RHAS) 2.1
~
~ Default Configuration w/o Enterprise Kernel with <4Gb of RAM
~
~ >>>SGA MAX Size 1.7 GB<<<
~
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Configuration : 3+1 3Gb user process +1Gb Kernel
On normal kernel we have the following default memory layout for every process:

1.0 GB Text/code
1.7 GB available process memory for mmap, malloc /
address space (e.g. usable by shared Pool)
0.3 GB Stack
1.0 GB Kernel

==> 4 – 1 – 1 – 0.3 = 1.7GB left for SGA

A picture of Memory Layout:
---------------------------

4GB +------------------+ 0xFFFFFFFF
| |
| Kernel stuff |
| | 0xE0000000 SSKGMTOP
| | (from sskgm.h may17 label)
| |
3GB +------------------+ 0xC0000000 __PAGE_OFFSET
| | Stack grows | (include/asm-i386/page.h)
| v down... |
2.98GB |------------------| 0xBF000000
| |
| |
| Oracle SGA |
| max 1776MB |
| max 1.75GB |
| |
| |
| |
| |
| |
| |
| |
| |
1.25GB +------------------| 0x50000000 GENKSMS_SGA_ADDR
| Shared libraries |
| lib*.so |
| |
| |
| |
| |
1GB +------------------+ 0x40000000 TASK_UNMAPPED_BASE
| applicaton code |
| (Oracle .text) | ^
| | |
| | 0x20000000 SSKGMBOTTOM |
| | (from sskgm.h may17 label) |
| | |
| | |
128MB |------------------| 0x08000000 |
| | |
| | |
0 +------------------+ 0x00000000 |


check
Note 260152.1

https://metalink.oracle.com/metalink/plsql/f?p=130:14:5739562173496231439::::p14_database_id,p14_docid,p14_show_header,p14_show_help,p14_black_frame,p14_font:NOT,260152.1,1,1,1,helvetica

--------

Oracle Diagnostic Tools(转)


Oracle Diagnostic Tools


RACDDT - a data collection tool designed and configured specifically for gathering diagnostic data related to Oracle's Real Application Cluster (RAC) technology.
See MetalinkNote:301138.1

RDA - Remote Diagnostic Agent - a set of command line diagnostic scripts that are used to gather detailed information about an Oracle environment.
See Metalink Note:314422.1
RDA 4 - Health Check / Validation Engine Guide
RDA 4 - RAC Cluster Guide

OSW - OS Watcher - a collection of UNIX shell scripts intended to collect and archive operating system and network metrics to aid support in diagnosing complex RAC issues as well as generic performance issues.
SeeMetalinkNote:301137.1

LTOM - The On-Board Monitor - a java program designed as a real-time diagnostic platform for deployment to a customer site. LTOM differs from other support tools, as it is proactive rather than reactive. LTOM provides real-time automatic problem detection and data collection.
See
MetalinkNote:352363.1

Support Diagnostics Tools Catalog for E-Business Suite -
a test repository, execution engine, and user interface for customers, support analysts, and developers to plug-in diagnostic test tools/scripts
See MetalinkNote:179661.1

--------

2006年11月23日

differences between global partitioned index and local partitioned index

You Asked (Jump to Tom's latest followup)

Hi Tom, please explain the differences between global partitioned index and
local partitioned index.

Thanks! 
and we said...

<quote src=expert one on one Oracle>
Partitioning Indexes
Indexes, like tables, may be partitioned. There are two possible methods to
partition indexes. You may either:

    Equipartition the index with the table – Also known as a local
index. For every table partition, there will be an index partition that indexes
just that table partition. All of the entries in a given index partition point
to a single table partition and all of the rows in a single table partition are
represented in a single index partition.
    Partition the index by range – Also known as a global index. Here
the index is partitioned by range, and a single index partition may point to any
(and all) table partitions.

In the locally partitioned index, the index entries in a given partition, point
into exactly one table partition. The globally partitioned index diagram
however, shows that the index entries in a global index may point into any or
all of the table partitions. Also, note that the number of index partitions may
in fact be different than the number of table partitions.

Since global indexes may be partitioned by range only, you must use local
indexes if you wish to have a hash or composite partitioned index. The local
index will be partitioned using the same scheme as the underlying table.

</quote>

--------

2006年11月17日

查lock的信息

有时因为DML语句没有及时commit,导致其它session等待其占用的锁,引起hang.

引用:
http://www.itpub.net/244694.html
http://www.builder.com.cn/developer/database/story/0,3800066906,39451598-1,00.htm

1.找到等待的session

select /*+ NO_MERGE(a) NO_MERGE(b) NO_MERGE(c) */ 'Wait' "Status", a.username, a.machine, a.sid, a.serial#, a.last_call_et "Seconds", b.id1, c.sql_text "SQL"
from v$session a, v$lock b, v$sqltext c
where a.username is not null
and a.lockwait = b.kaddr
and c.hash_value =a.sql_hash_value
union
select /*+ NO_MERGE(a) NO_MERGE(b) NO_MERGE(c) */ 'Lock' "Status", a.username, a.machine, a.sid, a.serial#, a.last_call_et "Seconds", b.id1, c.sql_text "SQL"
from v$session a, v$lock b, v$sqltext c
where b.id1 in
(select /*+ NO_MERGE(d) NO_MERGE(e) */ distinct e.id1
from v$session d, v$lock e
where d.lockwait = e.kaddr)
and a.username is not null
and a.sid = b.sid
and b.request=0
and c.hash_value =a.sql_hash_value;

2.取出session等待的信息

select row_wait_obj#,row_wait_file#,row_wait_block#,row_wait_row# from v$session where sid = &sid;

3.取出等待的对象,所在的表空间

select owner, segment_name, segment_type, tablespace_name from dba_extents
where file_id = &fileid_in
and &blockid_in between block_id and block_id + blocks - 1

但是还不能查到引起持有资源的那个sql?


check-lock.txt

其它:

asktom上tom对lock的一个答复

You Asked (Jump to Tom's latest followup)

Hi Tom,


Here are the few questions on Locking.

1)How do I use v$lock to figure out lock details ? Details like
whos has locked,on which table,who else is waiting, and what type
of locking (shared or exlusive ?), since when it is locked.

2)Why and when exclusive/shared locks are used ? Could you give me
example please ?

Thanks for the answer, I understand better.

3)Could you tell me significance of v$mystat and v$locked_object ?

Thank you .

4) Do we have page level locking in Oracle ?

Thank you


Thanks in advance,

Gururaj


and we said...

1) Here is a small example showing how this happens. We will use three V$ tables
in order to see how this works; V$TRANSACTION, V$SESSION, and V$LOCK.
V$TRANSACTION contains an entry for every active transaction. V$LOCK contains an
entry for all locks held as well as locks being waited on. V$SESSION shows us
the sessions logged in. We'll start by starting a transaction in one session and
looking at the state of the system at that point:

tkyte@TKYTE816> update dept set deptno = deptno+10;
4 rows updated.

tkyte@TKYTE816> select username,
2 v$lock.sid,
3 trunc(id1/power(2,16)) rbs,
4 bitand(id1,to_number('ffff','xxxx'))+0 slot,
5 id2 seq,
6 lmode,
7 request
8 from v$lock, v$session
9 where v$lock.type = 'TX'
10 and v$lock.sid = v$session.sid
11 and v$session.username = USER
12 /

USERNAME SID RBS SLOT SEQ LMODE REQUEST
-------- ---------- ---------- ---------- ---------- ---------- ----------
TKYTE 8 2 46 160 6 0

tkyte@TKYTE816> select XIDUSN, XIDSLOT, XIDSQN
2 from v$transaction
3 /

XIDUSN XIDSLOT XIDSQN
---------- ---------- ----------
2 46 160

The interesting things to note here are:

ć The LMODE is 6 in the V$LOCK table and the request is 0. If you refer to the
definition of the V$LOCK table in the Oracle Server Reference, you will find
that LMODE=6 is an exclusive lock. A value of 0 in the request means we are not
making a request ¡V we have the lock.
ć There is only one row in this table. This V$LOCK table is more of a queuing
table than a lock table. Many people expect there would be four rows in V$LOCK
since we have four rows locked. What you must remember however is that Oracle
does not store a master list of every row locked anywhere. To find out if a row
is locked, we must go to that row.
ć I took the ID1 and ID2 columns, and performed a bit of bit manipulation on
them. Oracle needed to save three 16bit numbers, but only had two columns in
order to do it. So, the first column ID1 holds two of these numbers. By dividing
by 2^16 with trunc(id1/power(2,16)) rbs and by masking out the high bits with
bitand(id1,to_number('ffff','xxxx'))+0 slot, I am able to get the two numbers
that are hiding in that one number back out.
ć The RBS, SLOT, and SEQ values match the V$TRANSACTION information. This is my
transaction ID.

Now I'll start another session using the same user name, update some rows in
EMP, and then try to update DEPT:

tkyte@TKYTE816> update emp set ename = upper(ename);
14 rows updated.

tkyte@TKYTE816> update dept set deptno = deptno-10;


I am now blocked in this session. If we run the V$ queries again, we see:

tkyte@TKYTE816> select username,
2 v$lock.sid,
3 trunc(id1/power(2,16)) rbs,
4 bitand(id1,to_number('ffff','xxxx'))+0 slot,
5 id2 seq,
6 lmode,
7 request
8 from v$lock, v$session
9 where v$lock.type = 'TX'
10 and v$lock.sid = v$session.sid
11 and v$session.username = USER
12 /

USERNAME SID RBS SLOT SEQ LMODE REQUEST
-------- ---------- ---------- ---------- ---------- ---------- ----------
TKYTE 8 2 46 160 6 0
TKYTE 9 2 46 160 0 6
TKYTE 9 3 82 163 6 0

tkyte@TKYTE816> select XIDUSN, XIDSLOT, XIDSQN
2 from v$transaction
3 /

XIDUSN XIDSLOT XIDSQN
---------- ---------- ----------
3 82 163
2 46 160

What we see here is that a new transaction has begun ¡V (3,82,163) is the
transaction ID. It has two rows in V$LOCK this time. One row represents the
locks that it owns (where LMODE=6). It also has a row in there that shows a
REQUEST with a value of 6. This is a request for an exclusive lock. The
interesting thing to note here is that the RBS/SLOT/SEQ values of this request
row are the transaction ID of the holder of the lock. We can easily see that the
transaction with SID=8 is blocking the transaction with SID=9. Now, if we commit
in SID = 8 the above changes:

tkyte@TKYTE816> select username,
2 v$lock.sid,
3 trunc(id1/power(2,16)) rbs,
4 bitand(id1,to_number('ffff','xxxx'))+0 slot,
5 id2 seq,
6 lmode,
7 request, block
8 from v$lock, v$session
9 where v$lock.type = 'TX'
10 and v$lock.sid = v$session.sid
11 and v$session.username = USER
12 /

USERNAME SID RBS SLOT SEQ LMODE REQUEST
-------- ---------- ---------- ---------- ---------- ---------- ----------
TKYTE 9 3 82 163 6 0

tkyte@TKYTE816> select XIDUSN, XIDSLOT, XIDSQN
2 from v$transaction
3 /

XIDUSN XIDSLOT XIDSQN
---------- ---------- ----------
3 82 163

that request row has gone ¡V it disappeared the instant the other session gave
up its lock. That request row was the queuing mechanism. The database is able to
wake up the blocked sessions the instant the transaction is completed. Note that
the above gives us a very easy way to see blockers and waiters:

tkyte@TKYTE816> select
(select username from v$session where sid=a.sid) blocker,
2 a.sid,
3 ' is blocking ',
4 (select username from v$session where sid=b.sid) blockee,
5 b.sid
6 from v$lock a, v$lock b
7 where a.block = 1
8 and b.request > 0
9 and a.id1 = b.id1
10 and a.id2 = b.id2
11 /

BLOCKER SID 'ISBLOCKING' BLOCKEE SID
-------- ---------- ------------- -------- ----------
TKYTE 8 is blocking TKYTE 9

simply by doing a self-join of V$LOCK with itself (I ran this query before
committing the session with SID=8).

2) exclusive lock -- I updated a row. no one else can update it until I commit.
I have an X lock on that row and only one person at a time can have an X lock.
an X lock provides serialization to a resource.

A shared lock -- when I update a table, I take a shared lock on the DEFINITION
of the table. Everyone else can do that as well (more then one session can get
a shared lock on the table definition). So, more than one person at a time can
update the table. If you wanted to ALTER the table, you would need an X lock on
the defintion. You cannot get an X lock when there are shared locks so you wait
until there are no shared locks.

3) mystat has the statistics (cpu use, blocks read, cursors opened, etc) for
your session only. v$locked_object shows you all of the locks in the system.

4) no, never.

showsql script from Tom

--------

2006年11月16日

32bit-linux 上使用8G内存

查了几个比较好的参考文档
1.http://www.puschitz.com/TuningLinuxForOracle.shtml(推荐)
2.http://www1.ap.dell.com/content/topics/topic.aspx/ap/topics/power/zhcn/ps3q03_mahmood?c=cn&l=zh&s=bsd

参考第一个文档,使用VLM方式,写了个简单的step by step.尚未test


Step by step – using vlm on RHEL4 for Oracle 9206

一、 参考文档:
 http://www.puschitz.com/TuningLinuxForOracle.shtml
 http://www1.ap.dell.com/content/topics/topic.aspx/ap/topics/power/zhcn/ps3q03_mahmood?c=cn&l=zh&s=bsd
二、 说明
扩大SAG的一种方法是扩展缓冲缓存或超大内存(VLM)。这一方法不支持Oracle9i Release2的一些特性,例如动态SGA在数据库中存在多个数据块大小。

三、 步骤:

1. 规划内存使用
8G 内存,配置4G给SGA,其中db cache : 3G, shared pool 400m,

db_block_size=8192
db_block_buffers=393216
shared_pool_size=419430400

2. 配置OS
a) 配置ramfs

假设oracle 的primary group 为oinstall

# umount /dev/shm
# mount -t ramfs ramfs /dev/shm
# chown oracle:oinstall /dev/shm

修改/etc/rc.local,加上

umount /dev/shm
mount –t ramfs ramfs /dev/shm
chown oracle:oinstall /dev/shm
b) 配置memlock

修改 /etc/security/limits.conf,加上:

oracle soft memlock 3145728
oracle hard memlock 3145728

配置后,以oracle登录,检查
$ulimit –l
是否为3145728

3. 配置Oracle
修改初始化文件

a) 加上:

use_indirect_data_buffers=true
db_block_size=8192
db_block_buffers=393216
shared_pool_size=419430400

b) 把db_cache_size 注释


4. 启动oracle

Now try to start the database. Note the database startup can take a while. Also, the sqlplus banner or show sga may not accurately reflect the actual SGA size in older Oracle versions.

The 3GB file for the database buffer cache can be seen in the ramfs shared memory filesystem:
$ ls -al /dev/shm
total 120
drwxr-xr-x 1 oracle dba 0 Nov 20 16:29 .
drwxr-xr-x 22 root root 118784 Nov 20 16:25 ..
-rw-r----- 1 oracle dba 3221225472 Nov 20 16:30 ora_orcl_458754
$


--------

2006年11月14日

10g 安装没有gb18030字符集

又是一个oracle bug. 10g 在dbca建库时没有gb18030的字符集选择。
解决方法有2种,一是先用US7创建,然后改为gb18030,一是用dbca生成scripts,修改scripts,改为gb18030字符集,再执行scripts.
建库完成后,查看nls_characterset _parameters 确认。

如下是metalink上得到的答复:

这个metalink的产生还挺麻烦。
直接8008100366过去,还是下午5点多,metalink中文服务到6点。我选择了英文服务,
以为可以直接和工程师对话,结果也是hub,不过是英文的hub。痛苦的对话后,huber给我创建了一个tar,后来发现我说的GB,被听成了GP,结果写出来是GP18030,不幸中的万幸是,创建的是一个2级tar,所以处理速度应该还可以。

后面第一个回复我,问我是否使用了locale builder(lbuilder),我感觉有些偏了,因为9i安装时不需要这个。

后来打了2次电话催,一次让工程师回电,没有收到;
后来打电话,找中文的服务,huber解释目前负责的是老美,老美还在睡觉呢,就帮我把负责的工程师切换到亚太,很快就回复了。

感觉以后要催,还是要找中文的。


QUESTION
=========
When I tried to create database with dbca, I select the character set from the
character sets list, but I can't find the ZHS32GB18030, which can be found when
I run dbca on Oracle 9i.

so My question is : does Oracle 10g doesn't support ZHS32GB18030 any longer?
or Is there a character set which contains ZHS32GB18030?

eos (end of section)

ANSWER
=======
Oracle still supports the character set ZHS32GB18030. But
DBCA not listing the characterset seems to be a new BUG.

I understand that your concern is to create a database with the characterset
ZHS32GB18030 . So , please follow the workaroud below.

+ Create a database selecting the characterset US7ASCII from the DBCA dropdown
list .

+ Then change the database characterset to ZHS32GB18030 with 'ALTER DATABASE '
command .

To change the characterset to ZHS32GB18030 from US7ASCII using 'alter database'
------------------------------------------------
Once the database with US7ASCII is created using DBCA , perform the following
steps :

SHUTDOWN IMMEDIATE;
-- make sure there is a database backup you can rely on, or create one
STARTUP MOUNT;
ALTER SYSTEM ENABLE RESTRICTED SESSION;
ALTER SYSTEM SET JOB_QUEUE_PROCESSES=0;
ALTER SYSTEM SET AQ_TM_PROCESSES=0;
ALTER DATABASE OPEN;
ALTER DATABASE CHARACTER SET ZHS32GB18030;
-- a alter database takes typically only a few minutes or less,
-- it depends on the number of columns in the database, not the
-- amount of data.
SHUTDOWN;


New info : liyuefu@yahoo.com.cn : Thanks for kindly reply.

Can I create the scripts with dbca, and then change the script to use GB18030 ,
and then create database with new scripts?


14-NOV-06 05:56:47 GMT

.
UPDATE
======

Hi Yuefu,

Yes. You can do like that also. There shouldnot be any problem.
After creating the database you can query nls_characterset _parameters to confirm the character set.

--------

一次归档日志异常快速增长分析

1 问题描述

客户数据库服务器在06年11月8日归档日志快速增长,认为有异常情况,请求协助分析。

2 问题分析
启用logmnr分析
检查归档日志,发现大概每分钟产生1个到2个归档,每个200M.
为分析具体的内容,使用logmnr分析日志。

execute dbms_logmnr.add_logfile(logfilename=>'/oradata10/oracle/arch/arch_1_56478.arc',
options=>dbms_logmnr.addfile);

exec dbms_logmnr.start_logmnr();

分析插入操作的情况

spool inssql.txt
select session_info ,sql_redo from v$logmnr_contents where upper(operation) = 'INSERT';
spool off


因为归档日志太大,没有分析完就停止。 绝大部分内容是

insert into "UNKNOWN"."OBJ# 31552"() values ();


查看对象情况:

SQL> select object_name, owner from dba_objects where object_id = 31552;

OBJECT_NAME
--------------------------------------------------------------------------------
OWNER
------------------------------
GLTMP_ASSORA
NC31


查看表结构:

--------------------------------------------------------------------------------

CREATE GLOBAL TEMPORARY TABLE "NC31"."GLTMP_ASSORA"
( "ASSID" CHAR(20)
) ON COMMIT DELETE ROWS

分析是NC软件在这个时间端有大量的临时表数据插入.


分析DELETE:


spool delsql.txt
select session_info ,sql_redo from v$logmnr_contents where upper(operation) = 'DELETE';
spool off

查看delsql.txt,大部分是如下内容:
delete from "UNKNOWN"."OBJ# 34216" where "COL 1" = HEXTORAW('3131313756323130303
030303030303053454b57') and ROWID = 'AARpmJAABAABpt/AAw';

查具体的segment:

SQL> select owner, object_name, object_type, temporary as TEMP from dba_objects where object_id = 34216;

OWNER
------------------------------
OBJECT_NAME
--------------------------------------------------------------------------------
OBJECT_TYPE T
------------------ -
NC31
ASSTEMPORA
TABLE Y

查看其创建SQL

SQL>set long 9000
SQL> select dbms_metadata.get_ddl('TABLE','ASSTEMPORA','NC31') from dual;

DBMS_METADATA.GET_DDL('TABLE','ASSTEMPORA','NC31')
--------------------------------------------------------------------------------

CREATE GLOBAL TEMPORARY TABLE "NC31"."ASSTEMPORA"
( "ASSID" CHAR(20)
) ON COMMIT DELETE ROWS


分析,归档日志内容大部分是global temporary表的操作引起的。应该属于正常的业务。

查是否存在bug:
查到是9204的bug:
2874489: Excessive REDO generated for INSERT as SELECT into GLOBAL TEMPORARY TABLES.
Fixed: 9205
确实命中了bug. 这个bug导致临时表的insert as select 操作产生大量的redo 日志。


向客户了解这几天的业务情况:

原dba介绍
以前开archivelog 时也差不多每分钟产生一个归档。

比较同期归档日志:

发现2006-10-7号下午13:40到15:00直接归档日志产生的频率也达到每分钟1-2个。

dba发现归档产生非常多后,停止了归档模式, 后来因为shareplex的需要,重新启动了归档模式。
Mon Sep 18 23:55:58 2006
alter database archivelog
Mon Sep 18 23:55:58 2006
Completed: alter database archivelog


财务部
发生问题的几天大量查报表,业务量比上个月增加。


3 总结和建议

因为应用使用了较多的global temporary 进行数据处理, 而9204版本存在的bug使得这些操作产生更多的arch log。针对业务的需要,在业务繁忙的时候,提高清理归档日志频率; 如果归档太多影响到业务,可以考虑升级到9206。


4.附测试9204bug

测试9204的这个bug:

D:MyDocument>sqlplus lyf/lyf

SQL*Plus: Release 9.2.0.1.0 - Production on 星期四 11月 9 10:56:28 2006

Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.


连接到:
Oracle9i Enterprise Edition Release 9.2.0.1.0 - Production
With the Partitioning, OLAP and Oracle Data Mining options
JServer Release 9.2.0.1.0 - Production

SQL> create table cc1(c1 number);

表已创建。

SQL> set autotrace trace stat
SQL> insert into cc1 select rownum from dba_objects;

已创建29521行。


Statistics
----------------------------------------------------------
909 recursive calls
809 db block gets
23119 consistent gets
215 physical reads
461400 redo size
614 bytes sent via SQL*Net to client
546 bytes received via SQL*Net from client
3 SQL*Net roundtrips to/from client
17 sorts (memory)
0 sorts (disk)
29521 rows processed

SQL> create global temporary table cc2(c1 number);

表已创建。

SQL> set autotrace trace stat
SQL> insert into cc2 select rownum from dba_objects;

已创建29522行。


Statistics
----------------------------------------------------------
17 recursive calls
30189 db block gets
22776 consistent gets
4 physical reads
3675880 redo size
618 bytes sent via SQL*Net to client
546 bytes received via SQL*Net from client
3 SQL*Net roundtrips to/from client
2 sorts (memory)
0 sorts (disk)
29522 rows processed

SQL>

SQL> delete from cc2;

已删除29522行。


Statistics
----------------------------------------------------------
24 recursive calls
30374 db block gets
59 consistent gets
0 physical reads
4755880 redo size
620 bytes sent via SQL*Net to client
515 bytes received via SQL*Net from client
3 SQL*Net roundtrips to/from client
1 sorts (memory)
0 sorts (disk)
29522 rows processed

SQL> delete from cc1;

已删除29521行。


Statistics
----------------------------------------------------------
24 recursive calls
30499 db block gets
65 consistent gets
0 physical reads
6648772 redo size
620 bytes sent via SQL*Net to client
515 bytes received via SQL*Net from client
3 SQL*Net roundtrips to/from client
1 sorts (memory)
0 sorts (disk)
29521 rows processed

SQL>

使用global temporary 产生的日志达到3M,而普通表产生的日志400k
临时表删除时也产生了4.5M日志。



在oracle 10g 上测试:

[oracle@iassrv oracle]$ sqlplus lyf/lyf

SQL*Plus: Release 10.1.0.4.2 - Production on Fri Nov 10 12:31:11 2006

Copyright (c) 1982, 2005, Oracle. All rights reserved.


Connected to:
Oracle Database 10g Enterprise Edition Release 10.1.0.4.2 - Production
With the Partitioning, OLAP and Data Mining options

SQL> create table cc1 (c1 number);

Table created.

SQL> set autotrace trace stat
1* insert into cc1 select rownum from dba_objects
SQL> /

60303 rows created.


Statistics
----------------------------------------------------------
1732 recursive calls
1536 db block gets
12848 consistent gets
752 physical reads
973516 redo size
632 bytes sent via SQL*Net to client
556 bytes received via SQL*Net from client
3 SQL*Net roundtrips to/from client
27 sorts (memory)
0 sorts (disk)
60303 rows processed

SQL> create global temporary table cc2 (c1 number);

Table created.

SQL> insert into cc2 select rownum from dba_objects;

60304 rows created.


Statistics
----------------------------------------------------------
33 recursive calls
708 db block gets
12275 consistent gets
455 physical reads
167188 redo size
636 bytes sent via SQL*Net to client
555 bytes received via SQL*Net from client
3 SQL*Net roundtrips to/from client
2 sorts (memory)
0 sorts (disk)
60304 rows processed

SQL>

Global temporary 的 redo log 比一般的表少很多。


在oracle 9206上测试

D:oracleora92sqlplusadmin>sqlplus lyf/lyf

SQL*Plus: Release 9.2.0.6.0 - Production on 星期五 11月 10 22:03:39 2006

Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.


连接到:
Oracle9i Enterprise Edition Release 9.2.0.6.0 - Production
With the Partitioning, OLAP and Oracle Data Mining options
JServer Release 9.2.0.6.0 - Production

SQL> create table cc1 (c1 number);
SQL> create global temporary table cc2 (c1 number);

SQL> set autotrace on statistics
SQL> insert into cc1 select rownum from dba_objects;

已创建29524行。


Statistics
----------------------------------------------------------
781 recursive calls
767 db block gets
23018 consistent gets
203 physical reads
464500 redo size
611 bytes sent via SQL*Net to client
546 bytes received via SQL*Net from client
3 SQL*Net roundtrips to/from client
17 sorts (memory)
0 sorts (disk)
29524 rows processed

SQL> insert into cc2 select rownum from dba_objects;

已创建29524行。


Statistics
----------------------------------------------------------
9 recursive calls
350 db block gets
22787 consistent gets
0 physical reads
79260 redo size
616 bytes sent via SQL*Net to client
546 bytes received via SQL*Net from client
3 SQL*Net roundtrips to/from client
2 sorts (memory)
0 sorts (disk)
29524 rows processed

SQL>

分析: 9206已经没有这个问题。Global temporary表比一般表生成的redo少。


--------

2006年11月01日

dba薪水及IMS数据库

想了解一下dba的薪水,看到一个2005年dba薪水统计

2004年的统计

DATABASE ADMINISTRATOR SALARIES

Year-to-Year Change
2005 2004 2002 2001 1-year change Change 01-05
$70,500 $71,400 $71,500 $66,800 -1.3% +5.5%
Average Annual Bonus
2005 2004 2002 2001 1-year change Change 01-05
$3,750 $3,600 $3,360 $5,350 +4.2% -29.9%

By Experience Level
<5 years <10 years 10+ years Differential
$60,600 $66,600 $78,700 +29.9%

By Operating System Environment
Mainframe Midrange AIX/Unix Windows Non-Mainframe
Linux
$75,500 $71,500 $73,700 $66,800 $66,400

By Database Environment
DB2 IMS Oracle SQL Server Sybase MySQL
$73,500 $75,100 $72,700 $69,100 $72,900 $67,800

其中有个 IMS,不知什么冬冬,google了一把(不知道是否有吹牛的嫌疑)
http://articles.e-works.net.cn/471/Article40956.htm


IBM信息管理系统(IBM Information Management System,IMS)是 IBM 最早的事务和层次数据库管理系统.

IMS 是 IBM 最早的事务和层次数据库管理系统,它非常适合支持高可用性、高性能、高容量、高完整性和低成本的关键性联机操作应用程序和数据。如今,IMS 管理着世界上一些任务关键型数据,并且继续在随需应变领域担任重要角色。全世界范围内 IMS 客户的 MIPS 已经迅速增长到超过 260 万。迁移到最新版 IMS 的客户一直都在迅速增长,并且比以前的版本增加的数目更多。

在我们朝着随需应变计算这个新的领域前进时,IMS 始终处于领导地位。自从首次 IMS-ready 消息用于 Apollo 太空计划 35 年多来,IMS 以及 zSeries 始终领导着这个行业,并不断突破技术壁垒。IMS 一直提供使用最新技术来满足客户需求的解决方案。

在利用新技术以及在满足日益增加的需求和客户复杂性之间平衡优先级等方面,IMS 客户一直处于最前沿。IMS 客户一直以来对性能、可用性、互操作性、灵活性以及支持新兴技术方面有很高的要求。IMS 始终提供解决方案来满足这些需求。为了将客户的现有资产扩展到现在的随需应变体系架构中,IMS 通过利用一个面向服务、随需应变的体系架构来进行集成和开放访问从而达到企业的现代化。

--------

一个报表查询优化优化

在出报表时,其它应用不能执行

Statspack查看报告


Event Waits Wait Time (cs) % Total Wt Time
-------------------------------------------- ------------ ------------ -------
direct path read 54,393 29,687 47.85
direct path write 34,272 28,559 46.03
log file parallel write 1,723 1,314 2.12
log file sync 1,326 1,215 1.96
control file parallel write 373 416 .67


运行了不到20分钟, direct path read/write就等待了 60000/100/60=10分钟。成为瓶颈。
查direct path read/write:
direct path read

When a session is reading buffers from disk directly into the PGA (opposed to the buffer cache in SGA), it waits on this event. If the I/O subsystem does not support asynchronous I/Os, then each wait corresponds to a physical read request.
If the I/O subsystem supports asynchronous I/O, then the process is able to overlap issuing read requests with processing the blocks already existing in the PGA. When the process attempts to access a block in the PGA that has not yet been read from disk, it then issues a wait call and updates the statistics for this event. Hence, the number of waits is not necessarily the same as the number of read requests (unlike 'db file scattered read' and 'db files sequential read').
V$SESSION_WAIT Parameter Columns
P1 - File_id for the read call
P2 - Start block_id for the read call
P3 - Number of blocks in the read call
Causes
This happens in the following situations:
• The sorts are too large to fit in memory and go to disk. If a sort does not fit into memory, then some of the sort data is written out directly to disk. This data is later read back in, using direct reads.
• Parallel slaves are used for scanning data.
• The server process is processing buffers faster than the I/O system can return the buffers. This can indicate an overloaded I/O system.
Actions
The file_id shows if the reads are for an object in TEMP tablespace (sorts to disk) or full table scans by parallel slaves. This is the biggest wait for large data warehouse sites. However, if the workload is not a DSS workload, then examine why this is happening.
Sorts to Disk
Examine the SQL statement currently being run by the session experiencing waits to see what is causing the sorts. Query V$TEMPSEG_USAGE to find the SQL statement that is generating the sort. Also query the statistics from V$SESSTAT for the session to determine the size of the sort. See if it is possible to reduce the sorting by tuning the SQL statement. If WORKAREA_SIZE_POLICY is MANUAL, then consider increasing the SORT_AREA_SIZE for the system (if the sorts are not too big) or for individual processes. If WORKAREA_SIZE_POLICY is AUTO, then investigate whether to increase PGA_AGGREGATE_TARGET.

查看目前sga配置:

SGA regions Size in Bytes
------------------------------ ----------------
Database Buffers 734,003,200
Fixed Size 75,804
Redo Buffers 77,824
Variable Size 196,767,744
----------------
sum 930,924,572

服务器内存有3G。可以适当调大sort_area_size.

把sort_area_size 调整为512k.

ALTER SYSTEM ... DEFERRED
Alter system set sort_area_size=524288;


调整后,重启,再运行此报告。用sysevent查看:
Avg
Total Total Time Ela Time % of
Event Name Waits Timeouts (in Hours) (Secs) Concern
------------------------------ ---------------- --------------- ----------- ----------- -------
CPU time 0.10 68.21
db file sequential read 16,742 0 0.02 0.01 15.88

direct read, direct write 已经消失。

初步判断问题解决。


--------

2006年10月31日

一个ORA-03106错误处理过程和其它

客户的应用程序在插入记录时遇到ora-03106错误。alert文件没有错误信息。

1. 查oracle错误信息
Cause: The communication path between Oracle and the user task has stopped. This is an internal error message not usually issued.
Action: Contact Oracle Support Services.
2. 要alert文件
没有相应错误记录
3. 查google

Troubleshooting
===============
Two-task common errors are generally RDBMS related issues, but could be caused by a problem with SQL*Net, or an application (i.e. Pro*C).

ORA-03106
======== Possible reasons for the ORA-03106 errors include:
1. Incompatibilities between the client application and the RDBMS server.
For example, version incompatibilities, or a client trying to use a feature not supported by the database kernel.
2. When using database links or gateways.
3. Network or SQL*Net problems.
4. Corruptions.
5. PL/SQL - language related.

RDBMS - Troubleshooting two-task common errors
==============================================
1. Check for NLS incompatibilities between the client and server. This is a very popular cause of the ORA-03106 error.
2. Check the alert log and RDBMS trace files for any pertinent information / errors that coincide with receiving the ORA-03106 error.
3. Try to get a testcase and reproduce the problem in-house.
4. If a testcase is not possible, ask for SQL*Net trace files, SQL traces, and try setting event 3106 to obtain the error stack.
5. In extreme circumstances, this could indicate that a shared memory segment used by Oracle is corrupted. You will have to shut down the database, possibly using the abort option. Make sure all semaphores have been released by using the IPCS command on Unix. Oracle uses semaphores to control concurrency between all of the background processes (pmon, smon, drwr, lgwr, and oracle shadow processes). Semaphores are also used to control Two-Task communication between the user process and the shadow process.
6. Try and narrow down the code that may be causing it. For example it might have started to happen after increasing the number of parameters in a PL/SQL block or when using certain values for bind variables, etc.
7. If we still do not make headway, file a bug under RDBMS, but we still may need some or all of the above information as indicated above

4. 让客户查客户端的NLS_LANG(服务器是GBK)
客户端zhs16cgb231280.
让客户端把客户端的修改维gbk测试。不再报错。

5. 其它

可能的进一步思路。
可以考虑客户端重启, 服务器上监控到新的oracle进程,然后trace 该进程,获得其执行的sql.
到服务器上用sqlplus连接执行测试。

--------

oracle开始提供linux服务

http://edelivery.oracle.com/EPD/Search/get_form

ora-rhel-download.JPG

来自chinaunix:
Oracle Unbreakable Linux最终发布了,看来正是万众瞩目。可以从Oracle公司的官方主页上看到该项目的相关说明,该发行版就是来源于redhat企业级Linux,把其中的Red Hat的商标移除掉,然后加上一些bug的修补。虽然Oracle公司的Linux发行版计划被称为是一项支持项目,支持Oracle的Linux平台用户,而不是为了发行Linux发行版。因为来源于RHEL,所以该发行版完全兼容RHEL。目前该版本提供免费下载,另外假如有公司需要额外的支持服务,可以另外选择付费服务,由Oracle提供。

Oracle声明:
Oracle Press Release

Contact(s):

Letty Ledbetter
Oracle
+1.650.506.8071
letty.ledbetter@oracle.com

Bob Wynne
Oracle
+1.650.506.5834
bob.wynne@oracle.com
Oracle Announces The Same Enterprise Class Support For Linux As For Its Database
Dell, Intel, HP, IBM, Accenture, AMD, BP, EMC, BMC, and NetApp Join Unbreakable Linux Program
REDWOOD SHORES, Calif., 25-OCT-2006 Today Oracle announced that it would provide the same enterprise class support for Linux as it provides for its database, middleware and applications products. Oracle starts with Red Hat Linux, removes Red Hat trademarks, and then adds Linux bug fixes.

Currently, Red Hat only provides bug fixes for the latest version of its software. This often requires customers to upgrade to a new version of Linux software to get a bug fixed. Oracle's new Unbreakable Linux program will provide bug fixes to future, current, and back releases of Linux. In other words, Oracle will provide the same level of enterprise support for Linux as is available for other operating systems.

Oracle is offering its Unbreakable Linux program for substantially less than Red Hat currently charges for its best support. "We believe that better support and lower support prices will speed the adoption of Linux, and we are working closely with our partners to make that happen," said Oracle CEO Larry Ellison. "Intel is a development partner. Dell and HP are resellers and support partners. Many others are signed up to help us move Linux up to mission critical status in the data center."

"Oracle's Unbreakable Linux program is available to all Linux users for as low as $99 per system per year," said Oracle President Charles Phillips. "You do not have to be a user of Oracle software to qualify. This is all about broadening the success of Linux. To get Oracle support for Red Hat Linux all you have to do is point your Red Hat server to the Oracle network. The switch takes less than a minute."

"We think it's important not to fragment the market," said Oracle's Chief Corporate Architect Edward Screven. "We will maintain compatibility with Red Hat Linux. Every time Red Hat distributes a new version we will resynchronize with their code. All we add are bug fixes, which are immediately available to Red Hat and the rest of the community. We have years of Linux engineering experience. Several Oracle employees are Linux mainline maintainers."

DELL
"As a customer with first hand experience of Oracle's outstanding support organization, Dell will use Oracle to support Linux operating systems internally," said Michael Dell, Chairman of the Board, Dell. "Oracle's new Linux support program will help us drive standards deeper into the enterprise. Today we're announcing that Dell customers can choose Oracle's Unbreakable Linux program to support Linux environments running on Dell PowerEdge servers."

Intel
"Having worked with Oracle for many years in the enterprise computing space, we believe that the Oracle Unbreakable Linux program will bring tremendous value to our mutual Linux customers," said Paul Otellini, President and CEO, Intel Corporation. "Our work with Oracle on this program will be an important extension to our longstanding enterprise computing relationship."

HP
"HP and Oracle's collaboration and testing of Linux with integrated stacks of hardware, software, storage, and networking has helped create numerous best practices across the industry. HP welcomes the addition of Oracle's Unbreakable Linux program to the portfolio," said Mark Hurd, Chairman and Chief Executive Officer, HP.

IBM
"Oracle's support for Red Hat Linux will encourage broader adoption of Linux in the enterprise," said Bill Zeitler, Senior Vice President & Group Executive, IBM Systems and Technology Group. "IBM shares Oracle's goal of making Linux a reliable, highly standard, cost effective platform for mission critical applications backed by world class support."

Accenture
"Linux is important to us, and to our customers," said Don Rippert, Chief Technology Officer, Accenture. "We applaud Oracle's efforts to bring enterprise-quality support to Linux with the Oracle Unbreakable Linux program announcement. Together with Oracle, we at Accenture look forward to making the Linux experience even better for our customers."

AMD
"Oracle's Unbreakable Linux program will greatly expand the servicing options available to our AMD Linux customers," said Hector Ruiz, Chairman and Chief Executive Officer of Advanced Micro Devices. "We are excited by the program's potential to further enhance the success of AMD Linux servers in the enterprise."

Bearing Point
"It is critical that our customers have true enterprise-quality support for their Linux deployments. Oracle's Unbreakable Linux program support delivers the level of confidence our customers need to run Linux in their data centers," said Harry You, CEO, Bearing Point.

EMC
"The combined power of EMC and Oracle solutions bring superior reliability, scalability, high availability, and now, enhanced enterprise supportability to Linux users. We are confident that joint Linux solutions from EMC and Oracle will deliver enterprise scale and quality while lowering the cost of infrastructure for our customers," said Joe Tucci, Chairman, CEO, President, EMC.

BMC
"As Oracle's only systems management ISV at the highest level in Oracle's Partner Program, BMC Software is excited to see Oracle's deepening commitment to Linux," said Bob Beauchamp, BMC Software President and CEO. "Business Service Management from BMC Software with the Oracle Unbreakable Linux program meets customer demand for lower cost and higher quality support for their infrastructure."

NetApp
"The world's largest enterprises must have the flexibility to quickly and continually adapt to today's rapidly changing business requirements, without incurring risk," said Dan Warmenhoven, CEO of Network Appliance. "The Oracle Unbreakable Linux program is designed to drive the key benefits of Linux - including flexibility, reliability, and simplicity - directly into the data center. The longstanding relationship between NetApp and Oracle has enabled us to continuously deliver superior enterprise solutions to enable business agility and improve reliability - all tenets of the NetApp brand."

Oracle Support
Oracle's breadth and depth of technical expertise, advanced support technologies, and global reach includes 7,000 support staff in 17 global support centers, providing help to our customers in 27 languages, in any time zone. Oracle has recently been awarded the J.D. Power and Associates Global Technology Service and Support Certification for "an outstanding customer service experience."

"With the scale of our support organization we can provide much better Linux support at a much lower price," said Executive Vice President of Oracle Customer Services Juergen Rottler. "We have the expertise and infrastructure to improve substantially the quality of support for enterprise Linux customers."

Enterprise Linux binaries will be available for free from Oracle. Enterprise Linux Network Support will be offered for $99.00 per system / per year. Enterprise Linux Basic support, which offers Network access plus 24x7 global coverage will be offered for $399 for a 2 CPU system per year and $999 for a system with unlimited CPU's. Enterprise Linux Premier Support, which offers Basic support plus back port of fixes to earlier releases as well as Oracle Lifetime Support will be offered for $1,199 for a 2 CPU system per year and $1,999 for a system with unlimited CPU's.

Oracle and Linux
Oracle has been a long-standing, key contributor to the Linux community. Oracle produced its first commercial Linux database in 1998. Since that time Oracle has worked steadily to improve the experience of all Linux users. Oracle's Linux Engineering team is a trusted part of the Linux community, and has made major code contributions such as Oracle Cluster File System that is now part of Linux kernel 2.6.16. Oracle has been and will continue contributing Linux related innovations, modifications, documentation and fixes directly to the Linux community on a timely basis.

About Oracle
Oracle (NASDAQ: ORCL) is the world's largest enterprise software company. For more information about Oracle, visit our Web site at http://www.oracle.com.

Trademarks
Oracle, JD Edwards, PeopleSoft, and Siebel are registered trademarks of Oracle Corporation and/or its affiliates. Other names may be trademarks of their respective owners.

This announcement is provided to you solely for information purposes, is not a commitment to deliver any material, code, or functionality, and should not be relied upon in making purchasing decisions. Many factors can materially affect Oracle's product development plans and the nature and timing of future product releases. The development, release, and timing of any features or functionality described remains at the sole discretion of Oracle. This information may not be incorporated into any contractual agreement with Oracle or its subsidiaries or affiliates. Oracle specifically disclaims any liability with respect to this information.

# # #

--------

what is mddb

What Is an MDDB?

A multidimensional database, or MDDB, is a specialized storage facility that allows data to be pulled from a data warehouse or other data sources for storage in a matrix-like format. The process of building an MDDB summarizes the raw data; the data stored in the MDDB is thus said to be presummarized. The MDDB enables users to quickly retrieve multiple levels of presummarized data through a multidimensional view. An MDDB is not a SAS data file; instead of the traditional structure used for SAS tables, an MDDB stores its data as an NWAY cube and zero or more subcubes.

参看


--------

2006年10月24日

hp-ux型号说明

今天提交metalink时, 发现hp-ux的9000系列有 2个选择,以前没有见过