Avast SQL Database is 9GB in size!

Our Avast Database (full version Microsoft SQL) is 9GB in size. Upon examination, it appears the “Clean Old Records Older Than 1 Month” task has not been running every week, even though it’s scheduled. I’ve tried running this task manually, but it only frees up 100MB or so. It’s not clear if the task actually finishes or is timing out. So, I have a couple questions:

  1. What information is being stored that would take up 9GB of space? Event logs?

  2. Do you have any other suggestions for reducing the current database size? A last resort for us would be to delete it and start over; although I’m not sure what we’d lose.

Thanks in advance,

Brandon

The space may be taken by reports. Do you generate reports with the “session” as destination? (i.e. to the DB)?

Also, how do you measure the DB size? Just by the size of the underlying files? Or using the SQL Enterprise Manager? Because normally, when you delete data from a database, the space on disk is NOT freed…

Thanks
Vlk

We haven’t generated any reports, at least not manually.

We’re measuring the DB size using the SQL Enterprise Manager, although the avast.mdf file also measures 9GB in size. The last steps taken by our server admin were as follows:

  • Ran “Clean Old Records Older Than 1 Month” task via ADNM Console, let run overnight.
  • Ran “Shrink Database” command from within SQL Enterprise Manager

End result was only a 100MB savings.

Thanks,
Brandon

I’m also curious what’s taking up so much space…

Try running this in the Query Analyser:

use avast
create table #temp (
table_name sysname,
row_count int,
reserved varchar(50),
data varchar(50),
index_size varchar(50),
unused varchar(50)
)
insert #temp
exec sp_msforeachtable ‘sp_spaceused ‘’?’‘’
select * from #temp

That should list space used by each and every table in the avast database

Thanks
Vlk

I see that this thread just died without a resolution…

however, our DB is now 7GB, gaining about a GB every month. we installed in April 2008 on SQL 2005 (not express) and it’s been growing steadily since.

like the previous user running the ADNM cleanup task doesn’t regain much space and I’m not even going to try to delete and restore because the data will come right back. I am right on the verge of just deleting the DB and creating it new and rebuilding it the hard way but we have 50+ clients and I’m not really looking forward to it. I will if there’s no other solution.

I would really like to know why this is happening. I have other client’s installs on SQL 2005 and this hasn’t been a problem before.

additional info:
when looking at it in SQL Mngmt Studio, all the massive data is in a table called dbo.event, can I just clear this table because it won’t shrink or defragment (only 10% fragmented)? well, it will, but just doesn’t really help.

and also running your size query yields:

table_name row_count reserved data index_size unused
Engine 52 40 KB 24 KB 16 KB 0 KB
Property 2497 800 KB 456 KB 256 KB 88 KB
Event 13061179 6462496 KB 5906400 KB 555120 KB 976 KB
LongName 0 0 KB 0 KB 0 KB 0 KB
ShortName 197 352 KB 136 KB 152 KB 64 KB
sysdiagrams 0 0 KB 0 KB 0 KB 0 KB
Session 87 40 KB 24 KB 16 KB 0 KB
Result 217 160 KB 72 KB 40 KB 48 KB
Queue 322 56 KB 40 KB 16 KB 0 KB
ScanStat 189 40 KB 24 KB 16 KB 0 KB
InstallStat 3 16 KB 8 KB 8 KB 0 KB
File 14 5376 KB 5344 KB 8 KB 24 KB
AssocObject 2 16 KB 8 KB 8 KB 0 KB
AccessControlList 110 16 KB 8 KB 8 KB 0 KB
User 3 16 KB 8 KB 8 KB 0 KB
Object 178 144 KB 72 KB 24 KB 48 KB
EngGroup 6 16 KB 8 KB 8 KB 0 KB