转载 Some indexes or index [sub]partitions of table VAS.TAB_PUB_CALLLOG have been marked unusable
http://www.xifenfei.com/2011/12/some-indexes-or-index-subpartitions-of-table-vas-tab_pub_calllog-have-been-marked-unusable.html
1、检查alert日志发现错误
Wed Nov 30 13:36:47 2011Some indexes or index [sub]partitions of table VAS.TAB_PUB_CALLLOG have been marked unusableWed Nov 30 13:36:48 2011Some indexes or index [sub]partitions of table VAS.TAB_PUB_CALLLOG have been marked unusableWed Nov 30 13:36:48 2011Some indexes or index [sub]partitions of table VAS.TAB_PUB_CALLLOG have been marked unusableWed Nov 30 13:36:49 2011Some indexes or index [sub]partitions of table VAS.TAB_PUB_CALLLOG have been marked unusableWed Nov 30 13:36:50 2011Some indexes or index [sub]partitions of table VAS.TAB_PUB_CALLLOG have been marked unusableWed Nov 30 13:36:51 2011Some indexes or index [sub]partitions of table VAS.TAB_PUB_CALLLOG have been marked unusableWed Nov 30 13:36:52 2011Some indexes or index [sub]partitions of table VAS.TAB_PUB_CALLLOG have been marked unusableWed Nov 30 13:36:52 2011Some indexes or index [sub]partitions of table VAS.TAB_PUB_CALLLOG have been marked unusableWed Nov 30 13:36:53 2011Some indexes or index [sub]partitions of table VAS.TAB_PUB_CALLLOG have been marked unusableWed Nov 30 13:36:54 2011Some indexes or index [sub]partitions of table VAS.TAB_PUB_CALLLOG have been marked unusableWed Nov 30 13:36:55 2011Some indexes or index [sub]partitions of table VAS.TAB_PUB_CALLLOG have been marked unusableWed Nov 30 13:36:56 2011Some indexes or index [sub]partitions of table VAS.TAB_PUB_CALLLOG have been marked unusableWed Nov 30 13:36:56 2011Some indexes or index [sub]partitions of table VAS.TAB_PUB_CALLLOG have been marked unusableWed Nov 30 13:36:57 2011Some indexes or index [sub]partitions of table VAS.TAB_PUB_CALLLOG have been marked unusableWed Nov 30 13:36:57 2011Some indexes or index [sub]partitions of table VAS.TAB_PUB_CALLLOG have been marked unusableWed Nov 30 13:36:58 2011Some indexes or index [sub]partitions of table VAS.TAB_PUB_CALLLOG have been marked unusableWed Nov 30 13:37:12 2011Some indexes or index [sub]partitions of table VAS.TAB_PUB_CALLLOG have been marked unusableWed Nov 30 22:00:09 2011…………Wed Nov 30 22:00:15 2011GATHER_STATS_JOB encountered errors. Check the trace file.Wed Nov 30 22:00:15 2011Errors in file /opt/oracle/admin/ora9i/bdump/ora9i_j001_21372.trc:ORA-20000: index "VAS"."XN_CALLLOG_ANALYSIS_PK" or partition of such index is in unusable state |
2、查看trace文件
/opt/oracle/admin/ora9i/bdump/ora9i_j001_21372.trcOracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bit ProductionWith the Partitioning, OLAP, Data Mining and Real Application Testing optionsORACLE_HOME = /opt/oracle/product/10.2.0/db_1System name: LinuxNode name: localhost.localdomainRelease: 2.6.18-92.el5Version: #1 SMP Tue Apr 29 13:16:15 EDT 2008Machine: x86_64Instance name: ora9iRedo thread mounted by this instance: 1Oracle process number: 42Unix process pid: 21372, image: oracle@localhost.localdomain (J001)*** 2011-11-30 22:00:15.782*** ACTION NAME:(GATHER_STATS_JOB) 2011-11-30 22:00:15.763*** MODULE NAME:(DBMS_SCHEDULER) 2011-11-30 22:00:15.763*** SERVICE NAME:(SYS$USERS) 2011-11-30 22:00:15.763*** SESSION ID:(532.60095) 2011-11-30 22:00:15.763ORA-20000: index "VAS"."XN_CALLLOG_ANALYSIS_PK" or partition of such index is in unusable state*** 2011-11-30 22:00:15.782GATHER_STATS_JOB: GATHER_TABLE_STATS('"VAS"','"TAB_XN_CALLLOG_ANALYSIS"','""', ...)ORA-20000: index "VAS"."XN_CALLLOG_ANALYSIS_PK" or partition of such index is in unusable state |
3、日志初步结论
通过alert日志,感觉应该是对分区表操作,导致”VAS”.”XN_CALLLOG_ANALYSIS_PK”索引变成了unusable state,然后在数据库自动收集统计信息的时候报错(最大可能是全局index导致)
4、验证猜测是否正确
SQL> SELECT owner,index_name,table_name,status FROM DBA_indexes 2 WHERE index_name='XN_CALLLOG_ANALYSIS_PK' AND owner='VAS'; OWNER INDEX_NAME TABLE_NAME STATUS------------------------------ ------------------------------ ------------------------------ --------VAS XN_CALLLOG_ANALYSIS_PK TAB_XN_CALLLOG_ANALYSIS UNUSABLE |
5、解决相关问题问题
SELECT 'ALTER INDEX ' || INDEX_OWNER || '.' || INDEX_NAME ||'REBUILD PARTITION ' || PARTITION_NAME || ' NOLOGGING online;'FROM DBA_IND_PARTITIONSWHERE INDEX_OWNER NOT IN ('SYS', 'SYSTEM', 'PUBLIC')AND STATUS = 'UNUSABLE'UNION ALLSELECT 'alter index ' ||OWNER || '.' || A.INDEX_NAME || ' REBUILD online nologging;'FROM DBA_INDEXES AWHERE OWNER NOT IN ('SYS', 'SYSTEM', 'PUBLIC')AND STATUS = 'UNUSABLE'; |
执行生成sql,解决相关index unusable问题
转载 Some indexes or index [sub]partitions of table VAS.TAB_PUB_CALLLOG have been marked unusable的更多相关文章
- How MySQL Uses Indexes CREATE INDEX SELECT COUNT(*)
MySQL :: MySQL 5.7 Reference Manual :: 9.3.1 How MySQL Uses Indexeshttps://dev.mysql.com/doc/refman/ ...
- Hashed Indexes Geospatial Index
Indexes — MongoDB Manual https://docs.mongodb.com/manual/indexes/ 地理索引 哈希索引
- dbms_redefinition在线重定义表结构 可以在表分区的时候使用
dbms_redefinition在线重定义表结构 (2013-08-29 22:52:58) 转载▼ 标签: dbms_redefinition 非分区表转换成分区表 王显伟 在线重定义表结构 在线 ...
- dbms_redefinition在线重定义表结构
dbms_redefinition在线重定义表结构 (2013-08-29 22:52:58) 转载▼ 标签: dbms_redefinition 非分区表转换成分区表 王显伟 在线重定义表结构 在线 ...
- logminer使用测试库进行挖掘分析,10.2.0.5
上一篇测试是在dg环境进行测试挖掘,但是如果客户存在一个测试库,那样使用日志挖掘的影响性更小.本篇进行测试分析. 测试环境介绍: oracle linux 5.6,vmware虚拟机,安装两套单实例 ...
- [Hive - LanguageManual] Create/Drop/Grant/Revoke Roles and Privileges / Show Use
Create/Drop/Grant/Revoke Roles and Privileges Hive Default Authorization - Legacy Mode has informati ...
- InnoDB On-Disk Structures(二)--Indexes (转载)
转载.节选于 https://dev.mysql.com/doc/refman/8.0/en/innodb-indexes.html This section covers topics relate ...
- GC Buffer Busy Waits处理(转载)
与单实例不同,在RAC环境中,由于多节点的原因,会因为节点间的资源争用产生GC类的等待,而这其中,GC Buffer Busy Waits又是最为常见的,从性能角度上说,RAC是把双刃剑,用的好,能够 ...
- PostgreSQL Partitions
why we need partitions The first and most demanding reason to use partitions in a database is to inc ...
随机推荐
- Entity Framework Tutorial Basics(7):DBContext
DBContext: As you have seen in the previous Create Entity Data Model section, EDM generates the Scho ...
- HtmlAgilityPack HTML操作类库的使用
HtmlAgilityPack是.NET下的一个开源的HTML解析类库.支持用XPath来解析HTML.命名空间:HtmlAgilityPack. 1.读取网络中html网页内容,获取网页中元素bod ...
- Ping命令的设计与实现
ping命令的设计与实现 发表于 C++ Socket TCP/IP 2016-05-15 19:07 字数: 10796 阅读量: 528 ping 命令使用的相关 TCP/IP 协议 ping 命 ...
- Elasticsearch suggester搜索建议初步
环境 Elasticsearch 2.3.5 Elasticsearch-ik-plugin 实现 搜索建议的对象 假设有以下两个json对象,需要对其中tags字段进行搜索建议: //对象Produ ...
- ASP.NET MVC底层原理与框架
前言 鄙人有一毛病,喜欢钻研原理性的东西,感觉只知道怎么用还不太够,更想知道如何实现的以及为什么会这样. 暑假的时候做积分系统是第一次接触MVC,感觉MVC就是一个框架,分为Module ,view和 ...
- Binder学习笔记(四)—— ServiceManager如何响应checkService请求
这要从frameworks/native/cmds/servicemanager/service_manager.c:347的main函数说起,该文件编译后生成servicemanager. int ...
- java线程池的使用(转)
在前面的文章中,我们使用线程的时候就去创建一个线程,这样实现起来非常简便,但是就会有一个问题: 如果并发的线程数量很多,并且每个线程都是执行一个时间很短的任务就结束了,这样频繁创建线程就会大大降低系统 ...
- ASP.NET-GridView分页排序显示
前期我们分别介绍了gridview怎么进行固定表多行数据显示,以及怎么设计花样表头.下面我们介绍怎么利用gridview进行分页显示的同时还可以进行排序显示. 显示效果 前端DEMO <span ...
- linux中sigsuspend和pause的区别
pause和sigsuspend都是用于等待信号的发生 简单的说,sigsuspend = unblock + pause sigsuspend 函数是用于需要先接触 某个信号的阻塞状态 然后等待该信 ...
- J.U.C AQS(abstractqueuedssynchronizer--同步器)
J.U.C AQS(abstractqueuedssynchronizer--同步器) 同步器是用来构建锁和其他同步组件的基础框架,它的实现主要依赖一个int成员变量来表示同步状态以及通过一个FI ...