Category Archives: Study

11gR2 INS-40724错误

在AIX 6.1上安装11gR2 RAC,无DNS,配置scan ip过程中出现错误:见截图
屏幕快照 2011 12 07 上午7 36 24

/etc/hosts配置如下:

192.168.4.54 xxx_aaaaaa_3_boot1
 192.168.5.54 xxx_aaaaaa_3_boot2
 138.199.10.15 xxx_aaaaaa_3_pers xxx_aaaaaa_3
 138.199.10.16 xxx_aaaaaa_3_svc xxx_aaaaaa3_vip
 192.168.6.55 xxx_crmsnn3_priv
192.168.4.55 xxx_aaaaaa_4_boot1 AIX要求的boot IP
 192.168.5.55 xxx_aaaaaa_4_boot2 AIX要求的boot IP
 138.199.10.17 xxx_aaaaaa_4_pers xxx_aaaaaa_4 主机的物理ip
 138.199.10.18 xxx_aaaaaa_4_svc xxx_aaaaaa4_vip 主机的浮动ip
 192.168.6.54 xxx_aaaaaa4_priv RAC的心跳IP
 138.199.10.19 bbbbb-scan

 

 

ifconfig:
 # ifconfig -a
 en0: inet 192.168.6.54 netmask 0xffffff00 broadcast 192.168.6.255
en2: inet 192.168.4.54 netmask 0xffffff00 broadcast 192.168.4.255
 inet 138.199.10.15 netmask 0xffffff00 broadcast 138.199.10.255
en6: inet 192.168.5.54 netmask 0xffffff00 broadcast 192.168.5.255
 inet 138.199.10.16 netmask 0xffffff00 broadcast 138.199.10.255
lo0: inet 127.0.0.1 netmask 0xff000000 broadcast 127.255.255.255

 

11gR2 RAC安装时,如要配置SCAN IP,可通过DNS/GNS或是直接配置/etc/hosts的方式,客户无DNS,只能通过配置/etc/hosts的方式解决,Oracle文档中可以看到对这种方式的描述:
However, in order to overcome the installation requirement without setting up a DNS-based SCAN resolution, you can use a hosts-file based workaround. In this case, you would use a typical hosts-file entry to resolve the SCAN to only 1 IP address and one IP address only. It is not possible to simulate the round-robin resolution that the DNS server does using a local host file. The host file look-up the OS performs will only return the first IP address that matches the name. Neither will you be able to do so in one entry (one line in the hosts-file). Thus, you will create only 1 SCAN for the cluster. (Note that you will have to change the hosts-file on all nodes in the cluster for this purpose.)注意,scan ip的配置需要写在每个节点上。

(文档:http://www.oracle.com/technetwork/database/clustering/overview/scan-129069.pdf

客户的问题如何解决呢?
首先在google上搜索,资源较少,但是搜到了这一篇:
https://forums.oracle.com/forums/thread.jspa?threadID=1093100
其中的回答是:
Define a public interface with a subnet matching the SCAN VIP or choose a SCAN VIP with a subnet matching the public interface.
这一块已经配置过了。google上没有什么太多的资源,进而继续在MOS上寻找,查找对应错误号,发现下面这一篇:
Solutions for Typical 11gR2 Grid Infrastructure/RAC Database runInstaller Issues [ID 1056713.1]
P: [INS-40724] No locally defined network interface matches the SCAN VIP subnet.
S: Public IP and SCAN VIP should be in same subnet, and public IP should be primary IP on a NIC.
前一句与之前论坛上的一致,但是后一句也同样重要,Public IP应为NIC上的主IP。

再次查看配置信息,发现如下问题:
1.en2上,Primary IP应配置为138.199.10.15
2.en6上的vip应该在配置完后才会出现,之所以现在出现,是由于手动配置的原因,需要删除
3.两节点/etc/hosts文件中的scan ip配置需要重新对比下,需要保证一致。

总结:
在遇到问题的时候,首先搜过google,没有合适的答案的时候,去搜索MOS,基本上这两步之后答案就可以找到。在查找的过程中,一定要认真仔细,不放过任何半句话。

Oracle 9.2.0.8.0 – ORA-600 – [17113]错误

某省级电信运营商核心生产库。
根据实例CRM1上的告警日志中记录,2011年12月1日08:37-08:43之间,出现了6次ORA-00600错误。

Thu Dec 1 08:37:52 2011
 Errors in file /oracle9/app/admin/crm/udump/crm1_ora_1995124.trc:
 ORA-00600: internal error code, arguments: [17113], [0x000000000], [], [], [], [], [], []
 Thu Dec 1 08:37:52 2011
 Trace dumping is performing id=[cdmp_20111201083752]
 Thu Dec 1 08:38:21 2011
 Errors in file /oracle9/app/admin/crm/udump/crm1_ora_1995124.trc:
 ORA-00600: internal error code, arguments: [17113], [0x000000000], [], [], [], [], [], []
 Thu Dec 1 08:39:47 2011
 Errors in file /oracle9/app/admin/crm/udump/crm1_ora_2982400.trc:
 ORA-00600: internal error code, arguments: [17113], [0x000000000], [], [], [], [], [], []
 Thu Dec 1 08:41:32 2011
 Errors in file /oracle9/app/admin/crm/udump/crm1_ora_1995124.trc:
 ORA-00600: internal error code, arguments: [17113], [0x000000000], [], [], [], [], [], []
 Thu Dec 1 08:42:13 2011
 Errors in file /oracle9/app/admin/crm/udump/crm1_ora_1995124.trc:
 ORA-00600: internal error code, arguments: [17113], [0x000000000], [], [], [], [], [], []
 Thu Dec 1 08:43:03 2011
 Thread 1 advanced to log sequence 197157
 Current log# 2 seq# 197157 mem# 0: /dev/rcrm_redo012lv
 Current log# 2 seq# 197157 mem# 1: /dev/rcrm_redo022lv
 Thu Dec 1 08:43:03 2011
 ARC1: Evaluating archive log 5 thread 1 sequence 197156
 ARC1: Beginning to archive log 5 thread 1 sequence 197156
 Creating archive destination LOG_ARCHIVE_DEST_1: '/arch01/1_197156.dbf'
 Thu Dec 1 08:43:37 2011
 Errors in file /oracle9/app/admin/crm/udump/crm1_ora_1995124.trc:
 ORA-00600: internal error code, arguments: [17113], [0x000000000], [], [], [], [], [], []

这个错误多为使用第三方工具(如PLSQL Developer,SQL Navigator)时出现的,尤其是工具的版本和RDBMS的版本有冲突时最可能出现。
根据错误中的提示,我们获取了跟踪文件/oracle9/app/admin/crm/udump/crm1_ora_1995124.trc,
从中可以发现,出现错误时,使用的客户端为PL/SQL Developer,其hash value与MOS上示例的值一致。

O/S info: user: Administrator, term: PC2011100510NLE, ospid: 2676:2564, machine: WORKGROUP\PC2011100510NLE
 program: plsqldev.exe
 application name: PL/SQL Developer, hash value=1190136663
 action name: Main session, hash value=1773317990

检查出现ORA-00600错误时的另一个跟踪日志/oracle9/app/admin/crm/udump/crm1_ora_2982400.trc,application name/action name记录的信息与另一个跟踪日志一致。

O/S info: user: Administrator, term: PC2011100510NLE, ospid: 3168:3188, machine: WORKGROUP\PC2011100510NLE
 program: plsqldev.exe
 application name: PL/SQL Developer, hash value=1190136663
 action name: Main session, hash value=1773317990

出现ORA-00600错误时,执行的SQL为:

Cursor 5 (110360558): CURBOUND  curiob: 11037fc78
curflg: 4c curpar: 0 curusr: 0 curses 700000c3b72b308
cursor name: 
declare
  t_owner varchar2(30);
  t_name  varchar2(30);
  procedure check_mview is
    dummy integer;
  begin
    if :object_type = 'TABLE' then
      select 1 into dummy
      from sys.all_objects
      where owner = :object_owner
      and object_name = :object_name
      and object_type = 'MATERIALIZED VIEW'
      and rownum = 1;
      :object_type := 'MATERIALIZED VIEW';
    end if;
  exception
    when others then null;
  end;
begin
  :sub_object := null;
  if :deep != 0 then
    begin
      if :part2 is null then
        select constraint_type, owner, constraint_name
          into :object_type, :object_owner, :object_name
          from sys.all_constraints c
         where c.constraint_name = :part1 and c.owner = user
           and rownum = 1;
      else
        select constraint_type, owner, constraint_name, :part3
          into :object_type, :object_owner, :object_name, :sub_object
          from sys.all_constraints c
         where c.constraint_name = :part2 and c.owner = :part1
           and rownum = 1;
      end if;
      if :object_type = 'P' then :object_type := 'PRIMARY KEY'; end if;
      if :object_type = 'U' then :object_type := 'UNIQUE KEY'; end if;
      if :object_type = 'R' then :object_type := 'FOREIGN KEY'; end if;
      if :object_type = 'C' then :object_type := 'CHECK CONSTRAINT'; end if;        
      return;
    exception
      when no_data_found then null;
    end;
  end if;
  :sub_object := :part2;
  if (:part2 is null) or (:part1 != user) then
    begin
      select object_type, user, :part1
      into :object_type, :object_owner, :object_name
      from sys.all_objects
      where owner = user
      and object_name = :part1
      and object_type in ('MATERIALIZED VIEW', 'TABLE', 'VIEW', 'SEQUENCE', 'PROCEDURE', 'FUNCTION', 'PACKAGE', 'TYPE', 'TRIGGER', 'SYNONYM')
      and rownum = 1;
      if :object_type = 'SYNONYM' then
        select s.table_owner, s.table_name
          into t_owner, t_name
          from sys.all_synonyms s
         where s.synonym_name = :part1
           and s.owner = user
           and rownum = 1;
        select o.object_type, o.owner, o.object_name
          into :object_type, :object_owner, :object_name
          from sys.all_objects o 
         where o.owner = t_owner
           and o.object_name = t_name
           and object_type in ('MATERIALIZED VIEW', 'TABLE', 'VIEW', 'SEQUENCE', 'PROCEDURE', 'FUNCTION', 'PACKAGE', 'TYPE', 'TRIGGER', 'SYNONYM')
           and rownum = 1;
      end if;
      :sub_object := :part2;
      if :part3 is not null then
        :sub_object := :sub_object || '.' || :part3;
      end if;
      check_mview;
      return;
    exception
      when no_data_found then null;
    end;
  end if;
  begin
    select s.table_owner, s.table_name
      into t_owner, t_name
      from sys.all_synonyms s
     where s.synonym_name = :part1
       and s.owner = 'PUBLIC'
       and rownum = 1;
    select o.object_type, o.owner, o.object_name
      into :object_type, :object_owner, :object_name
      from sys.all_objects o 
     where o.owner = t_owner
       and o.object_name = t_name
       and object_type in ('MATERIALIZED VIEW', 'TABLE', 'VIEW', 'SEQUENCE', 'PROCEDURE', 'FUNCTION', 'PACKAGE', 'TYPE', 'TRIGGER', 'SYNONYM')
       and rownum = 1;
    check_mview;
    return;
  exception
    when no_data_found then null;
  end;
  :sub_object := :part3;
  begin
    select o.object_type, o.owner, o.object_name
      into :object_type, :object_owner, :object_name
      from sys.all_objects o
     where o.owner = :part1
       and o.object_name = :part2
       and object_type in ('MATERIALIZED VIEW', 'TABLE', 'VIEW', 'SEQUENCE', 'PROCEDURE', 'FUNCTION', 'PACKAGE', 'TYPE', 'TRIGGER', 'SYNONYM')
       and rownum = 1;
    check_mview;
    return;
  exception
    when no_data_found then null;
  end;
  begin
    if :part2 is null and :part3 is null
    then
      select 'USER', null, :part1
      into :object_type, :object_owner, :object_name
      from sys.all_users u
      where u.username = :part1
      and rownum = 1;
      return;
    end if;
  exception
    when no_data_found then null;
  end;
  begin
    if :part2 is null and :part3 is null and :deep != 0
    then
      select 'ROLE', null, :part1
      into :object_type, :object_owner, :object_name
      from sys.session_roles r
      where r.role = :part1
      and rownum = 1;
      return;
    end if;
  exception
    when no_data_found then null;
  end;
  :object_owner := null;
  :object_type := null;
  :object_name := null;
  :sub_object := null;
end;

结论:

综合MOS和eygle博客上的信息,判断此为一个与PL/SQL Developer有关的Bug,建议客户选择合适版本的PL/SQL Developer进行操作。

参考:
https://support.oracle.com/CSP/main/article?cmd=show&type=NOT&doctype=REFERENCE&id=420844.1
https://support.oracle.com/CSP/main/article?cmd=show&type=NOT&id=154170.1
http://www.eygle.com/archives/2009/02/ora_07445_plsql_developer.html

部署Oracle osw(OS Watcher)

Linux操作系统上的IO、内存、CPU变化如何监控呢?Oracle提供的OS Watcher可以帮助我们监控这些数据,不过我们并不能实时的通过图形看到这部分数据的变化,需要通过命令生成图形。虽然有点后知后觉,不过起码也算时“监控”了。
安装方式非常简单,从Oracle官方网站下载osw安装包,解压缩即可。

[[email protected] tmp]# cd osw/
 [[email protected] osw]# ls
 [[email protected] osw]# ls
 osw301.tar
 [[email protected] osw]# tar -xvf osw301.tar
 ./
 ./osw/
 ./osw/Exampleprivate.net
 ./osw/OSWatcher.sh
 ./osw/OSWatcherFM.sh
 ./osw/OSWgREADME.txt
 ./osw/README.txt
 ./osw/iosub.sh
 ./osw/mpsub.sh
 ./osw/oswg.jar
 ./osw/oswib.sh
 ./osw/oswlnxio.sh
 ./osw/oswlnxtop.sh
 ./osw/oswnet.sh
 ./osw/oswrds.sh
 ./osw/oswsub.sh
 ./osw/pssub.sh
 ./osw/startOSW.sh
 ./osw/stopOSW.sh
 ./osw/tarupfiles.sh
 ./osw/topaix.sh
 ./osw/topsub.sh
 ./osw/vmsub.sh
 ./osw/tmp/
 ./osw/src/
 ./osw/src/coe_logo.gif
 ./osw/src/missing_graphic.gif
 ./osw/src/oswg_input.txt
 ./osw/src/OSW_profile.htm
 ./osw/src/Thumbs.db
 ./osw/src/tombody.gif
 ./osw/src/watch.gif

sow需要用到java,对java的版本有要求。这个要求可能根据osw的版本不同而有区别。我下载的osw包内对java的版本要求为1.4.2以上,我的是1.6.0.

[[email protected] osw]# java -version
 java version "1.6.0"
 OpenJDK Runtime Environment (build 1.6.0-b09)
 OpenJDK Client VM (build 1.6.0-b09, mixed mode)

启动OSW非常简单。只要运行startOSW.sh就可以了。该shell 需要2个参数,第一个参数指定采样时间间隔,第二个指定存储数据的时间。缺省情况下(如果不输入参数),OSW采样以30秒为间隔,存储24小时的数据.
我设置的间隔时间为10秒,保留时间为240小时,生成的log保存在osw目录下的osw.log文件中。

read more »

【RMAN】I/O Read Rate of Backups

如何控制RMAN备份时的I/O速度呢?
这是在客户生产环境中遇到的现实问题,因为客户的存储实在是弱爆了,RMAN备份的时候由于I/O较高,导致应用出现停顿,严重时存储直接挂掉。所以考虑限制RMAN备份时的速度。
在Oracle的Channel Control中提示可以通过两种哦国内方式控制I/O,单位为KB/s,MB/s,GB/s
Set limits on I/O bandwidth consumption in kilobytes, megabytes, or gigabytes (ALLOCATE CHANNEL … RATE, CONFIGURE CHANNEL … RATE)
下面是Oracle对Rate设置的案例介绍
I/O Read Rate of Backups
By default, RMAN uses all available I/O bandwidth to read/write to disk. You can limit the I/O resources consumed by a backup job with the RATE option of the ALLOCATE CHANNEL or CONFIGURE CHANNEL commands. The RATE option specifies the maximum number of bytes for each second that RMAN reads on the channel.
For example, you can configure automatic channels to limit each channel to read 1 MB a second:
CONFIGURE DEVICE TYPE sbt PARALLELISM 2;
CONFIGURE DEFAULT DEVICE TYPE TO sbt;
CONFIGURE CHANNEL DEVICE TYPE sbt RATE 1M;

根据Oracle给出的提示,我们在11.2.0.2的库上分别测试I/O限制为5M,20M及不限制IO时RMAN的备份速度,借助osw观察I/O变化情况。
备份的数据文件为system01.dbf,大小约为700MB。

-bash-3.2$ ls -lh system01.dbf
 -rw-r----- 1 oracle dba 701M Nov 21 15:30 system01.dbf

操作系统的块大小为4096(4KB),数据库的块大小为8192(8KB)

[[email protected] ~]# getconf PAGESIZE
 4096
 SQL> show parameter db_block_size
NAME TYPE VALUE
 ------------------------------------ ----------- ------------------------------
 db_block_size integer 8192

开启OSW(OS Watcher),收集信息时间间隔为10秒,保留10天(240小时)。

[[email protected] osw]# ./startOSW.sh 10 240 >> osw.log &
 [1] 16589
 [[email protected] osw]#
 [1]+ Done ./startOSW.sh 10 240 >> osw.log
 [[email protected] osw]#
 [[email protected] osw]# cat osw.log
Testing for discovery of OS Utilities...
VMSTAT found on your system.
 IOSTAT found on your system.
 MPSTAT found on your system.
 NETSTAT found on your system.
 TOP found on your system.
Discovery completed.
Starting OSWatcher v3.0.1 on Mon Nov 21 15:56:22 CST 2011
 With SnapshotInterval = 10
 With ArchiveInterval = 240
OSWatcher - Written by Carl Davis, Center of Expertise, Oracle Corporation
Starting Data Collection...
osw heartbeat:Mon Nov 21 15:56:22 CST 2011

1.I/O限制为5M,备份时间为2分25秒

RMAN> configure CHANNEL DEVICE TYPE DISK RATE 5M;
new RMAN configuration parameters:
 CONFIGURE CHANNEL DEVICE TYPE DISK RATE 5 M;
 new RMAN configuration parameters are successfully stored
RMAN> show CHANNEL;
RMAN configuration parameters for database with db_unique_name ORCL are:
 CONFIGURE CHANNEL DEVICE TYPE DISK RATE 5 M;
RMAN> backup datafile '/oracle/oradata/orcl/system01.dbf';
Starting backup at 21-NOV-11
 allocated channel: ORA_DISK_1
 channel ORA_DISK_1: SID=143 device type=DISK
 channel ORA_DISK_1: starting full datafile backup set
 channel ORA_DISK_1: specifying datafile(s) in backup set
 input datafile file number=00001 name=/oracle/oradata/orcl/system01.dbf
 channel ORA_DISK_1: starting piece 1 at 21-NOV-11
 channel ORA_DISK_1: finished piece 1 at 21-NOV-11
 piece handle=/oracle/fast_recovery_area/ORCL/backupset/2011_11_21/o1_mf_nnndf_TAG20111121T155646_7dn11yc3_.bkp tag=TAG20111121T155646 comment=NONE
 channel ORA_DISK_1: backup set complete, elapsed time: 00:02:25
 channel ORA_DISK_1: throttle time: 0:02:14
 Finished backup at 21-NOV-11
Starting Control File and SPFILE Autobackup at 21-NOV-11
 piece handle=/oracle/fast_recovery_area/ORCL/autobackup/2011_11_21/o1_mf_s_767807951_7dn16hq2_.bkp comment=NONE
 Finished Control File and SPFILE Autobackup at 21-NOV-11

2.I/O限制为20M,备份时间为45秒

RMAN> configure CHANNEL DEVICE TYPE DISK RATE 20M;
old RMAN configuration parameters:
 CONFIGURE CHANNEL DEVICE TYPE DISK RATE 5 M;
 new RMAN configuration parameters:
 CONFIGURE CHANNEL DEVICE TYPE DISK RATE 20 M;
 new RMAN configuration parameters are successfully stored
 released channel: ORA_DISK_1
RMAN> show CHANNEL;
RMAN configuration parameters for database with db_unique_name ORCL are:
 CONFIGURE CHANNEL DEVICE TYPE DISK RATE 20 M;
RMAN> backup datafile '/oracle/oradata/orcl/system01.dbf';
Starting backup at 21-NOV-11
 allocated channel: ORA_DISK_1
 channel ORA_DISK_1: SID=143 device type=DISK
 channel ORA_DISK_1: starting full datafile backup set
 channel ORA_DISK_1: specifying datafile(s) in backup set
 input datafile file number=00001 name=/oracle/oradata/orcl/system01.dbf
 channel ORA_DISK_1: starting piece 1 at 21-NOV-11
 channel ORA_DISK_1: finished piece 1 at 21-NOV-11
 piece handle=/oracle/fast_recovery_area/ORCL/backupset/2011_11_21/o1_mf_nnndf_TAG20111121T160009_7dn1896h_.bkp tag=TAG20111121T160009 comment=NONE
 channel ORA_DISK_1: backup set complete, elapsed time: 00:00:45
 channel ORA_DISK_1: throttle time: 0:00:30
 Finished backup at 21-NOV-11
Starting Control File and SPFILE Autobackup at 21-NOV-11
 piece handle=/oracle/fast_recovery_area/ORCL/autobackup/2011_11_21/o1_mf_s_767808054_7dn19ptr_.bkp comment=NONE
 Finished Control File and SPFILE Autobackup at 21-NOV-11

3.RMAN I/O无限制,备份时间为15秒

 RMAN> configure CHANNEL DEVICE TYPE DISK clear;
old RMAN configuration parameters:
 CONFIGURE CHANNEL DEVICE TYPE DISK RATE 20 M;
 old RMAN configuration parameters are successfully deleted
 released channel: ORA_DISK_1
RMAN> show CHANNEL;
RMAN configuration parameters for database with db_unique_name ORCL are:
 RMAN configuration has no stored or default parameters
RMAN> backup datafile '/oracle/oradata/orcl/system01.dbf';
Starting backup at 21-NOV-11
 allocated channel: ORA_DISK_1
 channel ORA_DISK_1: SID=143 device type=DISK
 channel ORA_DISK_1: starting full datafile backup set
 channel ORA_DISK_1: specifying datafile(s) in backup set
 input datafile file number=00001 name=/oracle/oradata/orcl/system01.dbf
 channel ORA_DISK_1: starting piece 1 at 21-NOV-11
 channel ORA_DISK_1: finished piece 1 at 21-NOV-11
 piece handle=/oracle/fast_recovery_area/ORCL/backupset/2011_11_21/o1_mf_nnndf_TAG20111121T160152_7dn1cjf8_.bkp tag=TAG20111121T160152 comment=NONE
 channel ORA_DISK_1: backup set complete, elapsed time: 00:00:15
 Finished backup at 21-NOV-11
Starting Control File and SPFILE Autobackup at 21-NOV-11
 piece handle=/oracle/fast_recovery_area/ORCL/autobackup/2011_11_21/o1_mf_s_767808127_7dn1czqj_.bkp comment=NONE
 Finished Control File and SPFILE Autobackup at 21-NOV-11

根据数据文件大小列出预计的RMAN备份时间与实际RMAN备份时间:
IO test chat

可以通过OSW收集的数据,很明显的看到percent busy(PB), reads per second(RPS) and writes per second(WPS)变化
percent busy(PB)
OSWg sda OS IO PB
reads per second(RPS)
OSWg sda OS IO RPS
writes per second(WPS)
OSWg sda OS IO WPS

从OSW生成的图片的整体趋势上,已经能看到设置RATE参数对磁盘I/O的影响。
但是可能是由于一些暂时未知的原因,RPS的趋势并非如我们所愿,限制为10M后仍有个别时段物理读超出限制。
今天看到一款可以监控程序IO的软件,改天重新进行一下测试。

总结:
Oracle 11gR2在做RMAN备份时,可以通过设置RATE参数限制磁盘IO。
设置方式如下:
configure CHANNEL DEVICE TYPE DISK RATE 20M;
重置方式如下:
configure CHANNEL DEVICE TYPE DISK clear;
单位可以设置为KB,MB,GB

参考:

Oracle® Database Backup and Recovery Advanced User’s Guide 10g Release 1 (10.1) Part Number B10734-01
计算机中KB与Kb的技术差别详解
RMAN备份数据文件和控制文件
利用RATE参数限制RMAN备份的IO速度
Unix/Linux 磁盘 I/O 性能监控命令

EXP-00091 Exporting questionable statistics

导出数据库基表时遇到EXP-00091错误,虽然据说不影响导出结果,但看起来还是很让人不爽:

[[[email protected] HCscripts]$ exp "'/ as sysdba'" tables = col$,icol$,file$,ind$,indpart$,obj$,partcol$,partlob$,partobj$,seg$,seq$,tab$,tabpart$,ts$,user$,attrcol$,view$ file=basetable.dmp log=basetable.log 

Export: Release 11.2.0.2.0 - Production on Wed Nov 16 15:53:40 2011

Copyright (c) 1982, 2009, Oracle and/or its affiliates.  All rights reserved.


Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.2.0 - Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
Export done in US7ASCII character set and AL16UTF16 NCHAR character set
server uses AL32UTF8 character set (possible charset conversion)

About to export specified tables via Conventional Path ...
. . exporting table                           COL$      61078 rows exported
EXP-00091: Exporting questionable statistics.
EXP-00091: Exporting questionable statistics.
EXP-00091: Exporting questionable statistics.
EXP-00091: Exporting questionable statistics.
. . exporting table                          ICOL$       3101 rows exported
EXP-00091: Exporting questionable statistics.
EXP-00091: Exporting questionable statistics.
. . exporting table                          FILE$          8 rows exported
EXP-00091: Exporting questionable statistics.
EXP-00091: Exporting questionable statistics.
EXP-00091: Exporting questionable statistics.
. . exporting table                           IND$       1560 rows exported
EXP-00091: Exporting questionable statistics.
EXP-00091: Exporting questionable statistics.
. . exporting table                       INDPART$        572 rows exported
EXP-00091: Exporting questionable statistics.
EXP-00091: Exporting questionable statistics.
EXP-00091: Exporting questionable statistics.
. . exporting table                           OBJ$      15233 rows exported
EXP-00091: Exporting questionable statistics.
EXP-00091: Exporting questionable statistics.
EXP-00091: Exporting questionable statistics.
EXP-00091: Exporting questionable statistics.
EXP-00091: Exporting questionable statistics.
EXP-00091: Exporting questionable statistics.
. . exporting table                       PARTCOL$        200 rows exported
EXP-00091: Exporting questionable statistics.
EXP-00091: Exporting questionable statistics.
. . exporting table                       PARTLOB$          1 rows exported
EXP-00091: Exporting questionable statistics.
. . exporting table                       PARTOBJ$        149 rows exported
EXP-00091: Exporting questionable statistics.
EXP-00091: Exporting questionable statistics.
. . exporting table                           SEG$       3720 rows exported
EXP-00091: Exporting questionable statistics.
. . exporting table                           SEQ$        147 rows exported
EXP-00091: Exporting questionable statistics.
EXP-00091: Exporting questionable statistics.
. . exporting table                           TAB$       1261 rows exported
EXP-00091: Exporting questionable statistics.
EXP-00091: Exporting questionable statistics.
. . exporting table                       TABPART$        475 rows exported
EXP-00091: Exporting questionable statistics.
EXP-00091: Exporting questionable statistics.
EXP-00091: Exporting questionable statistics.
. . exporting table                            TS$         14 rows exported
EXP-00091: Exporting questionable statistics.
EXP-00091: Exporting questionable statistics.
. . exporting table                          USER$         46 rows exported
EXP-00091: Exporting questionable statistics.
EXP-00091: Exporting questionable statistics.
EXP-00091: Exporting questionable statistics.
. . exporting table                       ATTRCOL$        665 rows exported
EXP-00091: Exporting questionable statistics.
EXP-00091: Exporting questionable statistics.
. . exporting table                          VIEW$       3833 rows exported
EXP-00091: Exporting questionable statistics.
EXP-00091: Exporting questionable statistics.
Export terminated successfully with warnings.

这个问题是由于exp工具所在的环境变量中的NLS_LANG与DB中的NLS_CHARACTERSET不一致导致的。
首先查看DB中的NLS_CHARCTERSET:

[SQL> col parameter for a20
SQL> col value for a30
SQL> select * from v$nls_parameters where parameter='NLS_CHARACTERSET';

PARAMETER	     VALUE
-------------------- ------------------------------
NLS_CHARACTERSET     AL32UTF8

设置exp的环境变量NLS_LANG为对应值

[[[email protected] HCscripts]$ export NLS_LANG=AMERICAN_AMERICA.AL32UTF8
[[email protected] HCscripts]$ env | grep NLS
NLS_LANG=AMERICAN_AMERICA.AL32UTF8

再次执行导出

[[[email protected] HCscripts]$ exp "'/ as sysdba'" tables = col$,icol$,file$,ind$,indpart$,obj$,partcol$,partlob$,partobj$,seg$,seq$,tab$,tabpart$,ts$,user$,attrcol$,view$ file=basetable_new.dmp log=basetable_new.log 

Export: Release 11.2.0.2.0 - Production on Wed Nov 16 16:09:56 2011

Copyright (c) 1982, 2009, Oracle and/or its affiliates.  All rights reserved.


Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.2.0 - Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
Export done in AL32UTF8 character set and AL16UTF16 NCHAR character set

About to export specified tables via Conventional Path ...
. . exporting table                           COL$      61078 rows exported
. . exporting table                          ICOL$       3101 rows exported
. . exporting table                          FILE$          8 rows exported
. . exporting table                           IND$       1560 rows exported
. . exporting table                       INDPART$        572 rows exported
. . exporting table                           OBJ$      15233 rows exported
. . exporting table                       PARTCOL$        200 rows exported
. . exporting table                       PARTLOB$          1 rows exported
. . exporting table                       PARTOBJ$        149 rows exported
. . exporting table                           SEG$       3720 rows exported
. . exporting table                           SEQ$        147 rows exported
. . exporting table                           TAB$       1261 rows exported
. . exporting table                       TABPART$        475 rows exported
. . exporting table                            TS$         14 rows exported
. . exporting table                          USER$         46 rows exported
. . exporting table                       ATTRCOL$        665 rows exported
. . exporting table                          VIEW$       3833 rows exported
Export terminated successfully without warnings.

总结:
字符集对于我来说是个比较头疼的问题,有空还得仔细研究下

参考资料:

http://www.eygle.com/digest/2009/04/exp00091_exporting_questionabl.html

http://xiexiejiao.cn/oracle/exp-00091-error.html

普人特福的博客cnzz&51la for wordpress,cnzz for wordpress,51la for wordpress