HiveBrain v1.2.0
Get Started
← Back to all entries
patternsqlModerate

Does restoring database clear buffer cache and stored proc cache

Submitted by: @import:stackexchange-dba··
0
Viewed 0 times
storedrestoringdatabasecacheprocdoesclearandbuffer

Problem

on our development server, we refresh database (restore from production backup) every week. my question is does restore db clear its buffer cache/stored procedure cache from sql memory? Does it have the same/similar effect of DBCC FREEPROCCACHE and DBCC DROPCLEANBUFFERS

Thanks.

Solution

Yes. The buffer and plan cache associated with the database before restore are not related to the database post-restore, so they will be cleared. To all intents and purposes the restored database is a completely separate, unrelated entity. There is nothing in cache that can be reused.

Context

StackExchange Database Administrators Q#53739, answer score: 13

Revisions (0)

No revisions yet.