May 20, 2003 at 11:36 am
How can I tell when auto grow last occurred on a database?
Thanks.
May 20, 2003 at 2:39 pm
The only method I'm aware of is to have a Profiler trace running against your database and capture the events Database\Data File Auto Grow and Database\Log File Auto Grow.
David R Buckingham, MCDBA,MCSA,MCP
May 20, 2003 at 2:42 pm
Does the database file modified date change when auto grow occurs?
May 21, 2003 at 1:25 am
Hi,
a quick look in Explorer tells me, the file date is yesterday 22:42. A time where no autogrow can occur, because nobody works at that time. At this time the server is restarted. I keep an eye on that.
Cheers,
Frank
--
Frank Kalis
Microsoft SQL Server MVP
Webmaster: http://www.insidesql.org/blogs
My blog: http://www.insidesql.org/blogs/frankkalis/[/url]
May 21, 2003 at 2:39 am
Positive,
date modified changes when an autogrow occurs.
Cheers,
Frank
--
Frank Kalis
Microsoft SQL Server MVP
Webmaster: http://www.insidesql.org/blogs
My blog: http://www.insidesql.org/blogs/frankkalis/[/url]
May 21, 2003 at 4:06 am
How about checking the file size too, if it's larger, you know it was a grow and not a shrink?
Andy
May 28, 2003 at 7:14 am
Also, the date/time stamp of the files change when you stop/start your SQL Server (or a reboot occurs). If you have your services configured to auto-restart upon failure, that would mislead you into believing an auto-grow occurred unless you capture the size of the files as Andy Warren suggested.
If you also have the auto-shrink option set as well, you could run into a situation where it shrinks it 2MB and then grows it 1MB (numbers arbitrary of course) before your next date/time/size capture cycle, you would be misled.
Back to my earlier comment, the only method I'm aware of that will accurately capture the events is to use a Profiler trace.
David R Buckingham, MCDBA,MCSA,MCP
May 28, 2003 at 7:24 am
Hi DRBuckingham,
quote:
Also, the date/time stamp of the files change when you stop/start your SQL Server (or a reboot occurs).
that's true, but in my case no error/restart or similar occured, so it must be autogrow. But you're right this isn't a water-proof solution. More like quick'n'dirty as a starting point to dig deeper.
Cheers,
Frank
--
Frank Kalis
Microsoft SQL Server MVP
Webmaster: http://www.insidesql.org/blogs
My blog: http://www.insidesql.org/blogs/frankkalis/[/url]
May 28, 2003 at 1:44 pm
E-Mail me...
I have a solution in place that monitors file growth and alerts me prior to it happening.
Jeff
"Keep Your Stick On the Ice" ..Red Green
May 29, 2003 at 11:37 am
I usually keep an eye on free space. Another way to see is when you notice loss of free disk space on the server. Then you can check the free space percentage on the MDF as compared to used space on the MDF. The percentage should be around the same percentage that you have set in your auto-grow property of the DB.
May 29, 2003 at 2:33 pm
Here is a good Source code By Peter Schmitz
http://www.planetsourcecode.com/vb/scripts/ShowCode.asp?txtCodeId=592&lngWId=5
Shas3
May 29, 2003 at 6:13 pm
Just to verify - Does the Date Time Modified only get updated when an Auto Grow takes place or when the SQL Server Service is stopped/restarted.
Thanks.
June 2, 2003 at 12:15 am
Hi jrose,
quote:
Just to verify - Does the Date Time Modified only get updated when an Auto Grow takes place or when the SQL Server Service is stopped/restarted.
I've never investigated on this, but it might also occur on autoshrink (which seems pretty logical to me)!
Cheers,
Frank
--
Frank Kalis
Microsoft SQL Server MVP
Webmaster: http://www.insidesql.org/blogs
My blog: http://www.insidesql.org/blogs/frankkalis/[/url]
Viewing 13 posts - 1 through 12 (of 12 total)
You must be logged in to reply to this topic. Login to reply