Showing posts with label timeouts. Show all posts
Showing posts with label timeouts. Show all posts

Sunday, March 11, 2012

Database Maintenance Plans and shrink database

I have read that having databases auto shrink can cause performance
problems, timeouts and fragmentation. I was wondering if using the "Remove
unused space from database files" from the Optimizations tab in Database
Maintenance Plans had the same affect. Should I avaoid using those two
settings?
Thanks
Yes (although maintenance plans are usually scheduled out of core business
hours). Have a look at http://www.karaszi.com/sqlserver/info_dont_shrink.asp
HTH
Jasper Smith (SQL Server MVP)
http://www.sqldbatips.com
I support PASS - the definitive, global
community for SQL Server professionals -
http://www.sqlpass.org
"Alison Blackburn" <alison.blackburn@.thalerus.com> wrote in message
news:Ohn3boEFFHA.2756@.TK2MSFTNGP15.phx.gbl...
>I have read that having databases auto shrink can cause performance
>problems, timeouts and fragmentation. I was wondering if using the "Remove
>unused space from database files" from the Optimizations tab in Database
>Maintenance Plans had the same affect. Should I avaoid using those two
>settings?
> Thanks
>

Database Maintenance Plans and shrink database

I have read that having databases auto shrink can cause performance
problems, timeouts and fragmentation. I was wondering if using the "Remove
unused space from database files" from the Optimizations tab in Database
Maintenance Plans had the same affect. Should I avaoid using those two
settings?
ThanksYes (although maintenance plans are usually scheduled out of core business
hours). Have a look at http://www.karaszi.com/sqlserver/info_dont_shrink.asp
--
HTH
Jasper Smith (SQL Server MVP)
http://www.sqldbatips.com
I support PASS - the definitive, global
community for SQL Server professionals -
http://www.sqlpass.org
"Alison Blackburn" <alison.blackburn@.thalerus.com> wrote in message
news:Ohn3boEFFHA.2756@.TK2MSFTNGP15.phx.gbl...
>I have read that having databases auto shrink can cause performance
>problems, timeouts and fragmentation. I was wondering if using the "Remove
>unused space from database files" from the Optimizations tab in Database
>Maintenance Plans had the same affect. Should I avaoid using those two
>settings?
> Thanks
>

Database Maintenance Plans and shrink database

I have read that having databases auto shrink can cause performance
problems, timeouts and fragmentation. I was wondering if using the "Remove
unused space from database files" from the Optimizations tab in Database
Maintenance Plans had the same affect. Should I avaoid using those two
settings?
ThanksYes (although maintenance plans are usually scheduled out of core business
hours). Have a look at http://www.karaszi.com/sqlserver/info_dont_shrink.asp
HTH
Jasper Smith (SQL Server MVP)
http://www.sqldbatips.com
I support PASS - the definitive, global
community for SQL Server professionals -
http://www.sqlpass.org
"Alison Blackburn" <alison.blackburn@.thalerus.com> wrote in message
news:Ohn3boEFFHA.2756@.TK2MSFTNGP15.phx.gbl...
>I have read that having databases auto shrink can cause performance
>problems, timeouts and fragmentation. I was wondering if using the "Remove
>unused space from database files" from the Optimizations tab in Database
>Maintenance Plans had the same affect. Should I avaoid using those two
>settings?
> Thanks
>

Friday, February 17, 2012

database locking malaise / restarting SQL Server fine points

Our company, primarily a software dev house, also manages an SQL Server
DB for one of our clients. A few days ago, we experienced repeated
timeouts in our .NET web and desktop applications, which threw this
error:
System.Data.SqlClient.SqlException: Timeout expired. The timeout
period elapsed prior to completion of the operation or the server is
not responding.
The timeouts seemed to be caused by locks placed on the database by a
stored proc which adds a new customers, when an order is placed. These
locks could be seen in Enterprise Manager / Management / Current
Activity / Locks, some of the locks' properties pointing to this stored
proc.
Now the strange part: we rebooted the server in question, which had no
apparent effect, ie still lots of locks, timeouts, etc. But a few
hours later, we pushed "Stop" and "Start" in the SQL Server Service
Manager - and everything magically started working again, no further
problems since then (24 hours).
So my key question: when you reboot your machine, does SQL server try
to "retain state" in a way that could have retained these locks? And
when you Stop/Start in "Service Manager", is that a different kind of
restart, which may have cleared the state / fixed these issues?
If the answer to these questions is yes, then we can rest a bit easy,
just say the DB got screwy, we had to restart it, but otherwise, we
have some serious investigating to do, to try to prevent this
recurring.
Thanks very much for any advice.
Harlan Wood
sfk3ml4x9w35
_____at_____
thegoldensun.comwhen you reboot your machine, does SQL server try
to "retain state" in a way that could have retained these locks? And
when you Stop/Start in "Service Manager", is that a different kind of
restart, which may have cleared the state / fixed these issues?
--both do the same thing, there is nothing that SQL will retain the
locks..in any case, SQL will release the locks..