How to warm up a sleeping SQL Server database

前端 未结 3 1211
北海茫月
北海茫月 2021-01-02 10:57

We have a job which runs every morning in CruiseControl.net to import a datafile into a DB. Our problem seems to be that some nights the DB goes to sleep over night. When we

相关标签:
3条回答
  • 2021-01-02 11:39

    Could you schedule a query 30 minutes before your build process runs to "warm up" the server?

    Also- is this database running on a server or desktop? If it's a desktop you might check the power management settings.

    0 讨论(0)
  • 2021-01-02 11:57
    ALTER DATABASE myDB SET AUTO_CLOSE OFF
    go
    
    0 讨论(0)
  • 2021-01-02 12:01

    Which version of SQL Server is this? It sounds like the database has the Auto Close setting on, which is the default for EXPRESS but can lead to behaviour like this.

    0 讨论(0)
提交回复
热议问题