2017-11-01 09:49:44.35 spid166     SQL Server has encountered 1 occurrence(s) of cachestore flush for the 'Object Plans' cachestore (part of plan cache) due to some database maintenance or reconfigure operations.
2017-11-01 09:49:47.85 spid166 SQL Server has encountered 1 occurrence(s) of cachestore flush for the 'SQL Plans' cachestore (part of plan cache) due to some database maintenance or reconfigure operations.
2017-11-01 09:49:47.85 spid166 SQL Server has encountered 1 occurrence(s) of cachestore flush for the 'Bound Trees' cachestore (part of plan cache) due to some database maintenance or reconfigure operations.

数据库ERRORLOG中出现类似记录,因此去查找相关的文档,发现SQL Server在做一些配置变更时会彻底清除一次执行计划缓存,这很好的解释了许多时候修改最大内存也会导致执行计划变更,SQL执行性能变化的现象。具体的官方文档为:https://support.microsoft.com/en-us/help/917828/you-may-experience-a-decrease-in-query-performance-after-you-perform-c

但是官网也申明此类现象只在SQL Server2005SP2之前的版本出现,以后的版本已经修复,具体表现还未可知。

文档中列出了所有可能导致此种情况出现的操作:

    • A database has the AUTO_CLOSE database option set to ON. When no user connection references or uses the database, the background task tries to close and shut down the database automatically.
    • You run several queries against a database that has default options. Then, the database is dropped.
    • A database snapshot for a source database is dropped.

      Note Database snapshots are only available in Microsoft SQL Server 2005 Enterprise Edition.

    • You change the database state to OFFLINE or ONLINE.
    • You successfully rebuild the transaction log for a database.
    • You restore a database backup.
    • You run the DBCC CHECKDB statement.

      Note This is true only in versions of SQL Server 2005 that are earlier than SQL Server 2005 SP2. After you install SQL Server 2005 SP2 or later versions, the whole procedure cache is not flushed when you run the DBCC CHECKDB statement.

    • You detach a database.
    • You specify one of the following options when you run the ALTER DATABASE statement:
      • OFFLINE
      • ONLINE
      • MODIFY FILEGROUP DEFAULT
      • MODIFY_NAME
      • MODIFY FILEGROUP READ_WRITE
      • COLLATE
      • MODIFY FILEGROUP READ_ONLY
      • READ_ONLY
      • READ_WRITE
    • The whole procedure cache is cleared if one of the following server options is changed by the RECONFIGURE statement:
      • cross db ownership chaining
      • index create memory (KB)
      • remote query timeout (s)
      • user options
      • max text repl size (B)
      • cost threshold for parallelism
      • max degree of parallelism
      • min memory per query (KB)
      • query wait (s)
      • min server memory (MB)
      • max server memory (MB)
      • query governor cost limit

      Note Procedure cache will not be cleared if the actual value does not change or if the new value for the max server memory server option is set to 0.

SQL Server has encountered 1 occurrence(s) of cachestore flush for the 'Object Plans' cachestore (part of plan cache) due to some database maintenance or reconfigure operations.的更多相关文章

  1. 缓解 SQL Server has encountered 727 occurrence(s) of I/O requests taking longer than 15 seconds

    sql server 会记录IO等待时间超过15 seconds的请求,这时application会有 time out 现象,dba需要判断是workload,concurrecy 所致还是sql ...

  2. SQL Server 磁盘请求超时的833错误原因分析以及解决

    本文出处:http://www.cnblogs.com/wy123/p/6984885.html 最近遇到一个SQL Server服务器响应极度缓慢,并且出现客户端请求报错的情况,在数据库中的erro ...

  3. Microsoft SQL Server Trace Flags

    Complete list of Microsoft SQL Server trace flags (585 trace flags) REMEMBER: Be extremely careful w ...

  4. 疑难杂症--SQL SERVER 18056的错误

    朋友遇到一个很棘手的问题,查看服务器日志,报以下错误: ::,spid296,未知,错误: ,严重性: ,状态: . ::,spid495,未知, The client was unable < ...

  5. SQL Server 内存相关博文

    Don’t confuse error 823 and error 832 本文大意:      错误832:           A page that should have been const ...

  6. RML Utilities for SQL Server

    很早以前有看到过关于使用RML Utilities工具分析SQL Trace(.trc)的文章,但一直没有具体实践.最近接管一台数据库服务器,跟踪出一批高消耗的语句,老大需要跟踪分析报表,罗列出过程( ...

  7. Migrating Oracle on UNIX to SQL Server on Windows

    Appendices Published: April 27, 2005 On This Page Appendix A: SQL Server for Oracle Professionals Ap ...

  8. Microsoft SQL Server Version List [sqlserver 7.0-------sql server 2016]

    http://sqlserverbuilds.blogspot.jp/   What version of SQL Server do I have? This unofficial build ch ...

  9. Microsoft SQL Server Version List(SQL Server 版本)

    原帖地址 What version of SQL Server do I have? This unofficial build chart lists all of the known Servic ...

随机推荐

  1. Java Web中提交表单之后跳转到WebContent目录下的子目录里的jsp文件

    最近在做一个系统,需要完成登录动能进行跳转到另一个页面.在这个项目里面,我把 jsp,css,js文件都统一放在 WebContent 目录下的一个 WebPage 里面. 按照以前的习惯,写好了 s ...

  2. solr调用lucene底层实现倒排索引源码解析

    1.什么是Lucene? 作为一个开放源代码项目,Lucene从问世之后,引发了开放源代码社群的巨大反响,程序员们不仅使用它构建具体的全文检索应用,而且将之集成到各种系统软件中去,以及构建Web应用, ...

  3. spring学习(二) ———— AOP之AspectJ框架的使用

    前面讲解了spring的特性之一,IOC(控制反转),因为有了IOC,所以我们都不需要自己new对象了,想要什么,spring就给什么.而今天要学习spring的第二个重点,AOP.一篇讲解不完,所以 ...

  4. Go基础系列:双层channel用法示例

    Go channel系列: channel入门 为select设置超时时间 nil channel用法示例 双层channel用法示例 指定goroutine的执行顺序 双层通道的解释见Go的双层通道 ...

  5. 【转载】阿里云轻量应用型服务器和ECS服务器比较

    在采购阿里云服务器的时候,我们会发现阿里云服务器分好多种,如GPU服务器.ECS服务器.轻量应用型服务器等.ECS服务器和轻量应用型服务器很多人无法搞明白其中的差别,个人的观点是轻量应用型服务器适合入 ...

  6. PHP之单例模式

    之前记得有写过PHP的几种这模式.这几天看群里在问单列模式,觉得还是有必要再深入写清楚下..其实单例模式很好理解滴哦 单例模式顾名思义,就是只有一个实例,作为对象的创建模式,单例模式确保某一个类只有一 ...

  7. [leetcode](4.21)1. 有序数组中的缺失元素

    给出一个有序数组 A,数组中的每个数字都是 独一无二的,找出从数组最左边开始的第 K 个缺失数字. 示例 1: 输入:A = [4,7,9,10], K = 1 输出:5 解释: 第一个缺失数字为 5 ...

  8. JavaWeb学习日记----XML的解析

    XML的解析简介: 在学习JavaScript时,我们用的DOM来解析HEML文档,根据HTML的层级结构在内存中分配一个树形结构,把HTML的标签啊,属性啊和文本之类的都封装成对象. 比如:docu ...

  9. react学习(一)

    组件和属性(props) 函数式组件: function Welcome(props) { return <h1>Hello, {props.name}</h1>; } 渲染一 ...

  10. Laravel条件查询数据单条数据first,多条数据get

    使用DB查询,必须use Illuminate\Support\Facades\DB; 多数组条件查询单条数据 first() //提交加入我们数据 public function ajax_join ...