Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2008 Forums
 Transact-SQL (2008)
 2008 Express - Auto Close?

Author  Topic 

bpsintl
Posting Yak Master

132 Posts

Posted - 2009-04-14 : 12:14:03
I have a production db running on sql 2008 express. It's not massively busy yet so I have auto close set to true in db options.

Is that a bad thing? IF I set it to false and there was no db activity for a while, would that not be bad for server resources etc?

bpsintl
Posting Yak Master

132 Posts

Posted - 2009-04-15 : 09:34:52
Anyone?
Go to Top of Page

SwePeso
Patron Saint of Lost Yaks

30421 Posts

Posted - 2009-04-15 : 10:01:58
Yes. It is mostly bad for performance.

When all users are logged out and next user logs on, it will take some time to open the database again.


E 12°55'05.63"
N 56°04'39.26"
Go to Top of Page

bpsintl
Posting Yak Master

132 Posts

Posted - 2009-04-15 : 10:09:26
So are you saying to leave auto close to true or false? I don't notice any performance hit by leaving it to true at the moment
Go to Top of Page

bpsintl
Posting Yak Master

132 Posts

Posted - 2009-04-27 : 11:10:59
If I set autoclose to false, and there is no db activity for a while, will that use up much server resources etc?
Go to Top of Page

bpsintl
Posting Yak Master

132 Posts

Posted - 2009-04-29 : 16:01:40
Anyone?
Go to Top of Page

tkizer
Almighty SQL Goddess

38200 Posts

Posted - 2009-04-29 : 16:12:25
Never use autoclose, even on test systems and especially not on production. It doesn't provide any noticeable benefit but does provide a noticeable negative.

Tara Kizer
Microsoft MVP for Windows Server System - SQL Server
http://weblogs.sqlteam.com/tarad/

Subscribe to my blog

"Let's begin with the premise that everything you've done up until this point is wrong."
Go to Top of Page

bpsintl
Posting Yak Master

132 Posts

Posted - 2009-04-29 : 16:19:06
Is there no negative effect on server resources if there is a period of no website activity, ie the server keeps the db connection open etc?
Go to Top of Page

tkizer
Almighty SQL Goddess

38200 Posts

Posted - 2009-04-29 : 16:26:48
Who cares if there are connections sitting their idle? We're talking extremely low resources being consumed. It simply is not worth it to ever use autoclose. Autoclose in a production environment is a very bad idea.

Tara Kizer
Microsoft MVP for Windows Server System - SQL Server
http://weblogs.sqlteam.com/tarad/

Subscribe to my blog

"Let's begin with the premise that everything you've done up until this point is wrong."
Go to Top of Page

bpsintl
Posting Yak Master

132 Posts

Posted - 2009-04-29 : 16:34:25
Ah ok, wasnt sure. If they use very low resources when idle I'm not too bothered
Go to Top of Page
   

- Advertisement -