02-24-2012 01:27 PM
Our organization uses journaling. We have an unlimited retention category for the journal vault. Now the organization has decided that we would need to only have 1 year retained in the journal. The journal vault size is pushing 2TB currently. Is there a way to start purging the journal vault a little bit at a time? Basically need to know how to start with maybe a 10 year, then a 5 year, etc... purge. Any ideas are appreciated. Thanks.
Solved! Go to Solution.
02-24-2012 01:55 PM
Yes, it is resource intensive so you might want to schedule it on a weekend outside of your archive schedule. You could run this query against the Journal Vault store to see how many items you have by year. This give you the age of items by the item date, so if you are basing expiry on Modified date, it will work.
select "ItemDate" = left (convert (varchar, IdDateTime,20),4), "Count" = count (*)
from saveset
--where IdDateTime > dateadd("hh", -24, getdate ())
group by left (convert (varchar, IdDateTime,20),4)
order by "ItemDate" Desc
If basing expiry by Archive Date use this one.
select "ArchiveDate" = left (convert (varchar, ArchivedDate,20),4),
"Count" = count (*)
from saveset
--where ArchivedDate > dateadd("hh", -24, getdate ())
group by left (convert (varchar, ArchivedDate,20),4)
order by "ArchiveDate" Desc
02-24-2012 01:35 PM
The length of time is set on the Retention Category so when you adjust the time on the category it will take effect immediately so the next time storage expiry runs items the meet the criteria will be removed.
So if you change it to 10 years and you have mail older than 10 years in the journal they will be expired when Expiry runs.
02-24-2012 01:44 PM
That's what I thought. However, what if I have 1 million items that meet that criteria? Will it take my system to its knees or is there some sort of throttle setting that I can set? I appreciate your time.
02-24-2012 01:55 PM
Yes, it is resource intensive so you might want to schedule it on a weekend outside of your archive schedule. You could run this query against the Journal Vault store to see how many items you have by year. This give you the age of items by the item date, so if you are basing expiry on Modified date, it will work.
select "ItemDate" = left (convert (varchar, IdDateTime,20),4), "Count" = count (*)
from saveset
--where IdDateTime > dateadd("hh", -24, getdate ())
group by left (convert (varchar, IdDateTime,20),4)
order by "ItemDate" Desc
If basing expiry by Archive Date use this one.
select "ArchiveDate" = left (convert (varchar, ArchivedDate,20),4),
"Count" = count (*)
from saveset
--where ArchivedDate > dateadd("hh", -24, getdate ())
group by left (convert (varchar, ArchivedDate,20),4)
order by "ArchiveDate" Desc
02-24-2012 02:09 PM
That's great. Even running this query will take a while right? There is almost 2TB of data. That in itself will be intensive going through all of the indexes. Is there a way to check each index rather than the whole journal vault store?
02-24-2012 02:19 PM
The sql will take a bit to run against the database but it doesn't run against the EV indexes themselves.
How many items are in the journal vault store? I mean the number of items, not the size.
02-24-2012 02:30 PM
There are two Journal mailboxes that go to the one journal vault store and they equal a total of 29,844,467 items.
02-24-2012 02:31 PM
02-24-2012 02:41 PM
Agreed with JW2 in regards to gradually lowering the expiry date.
I don't running the sql query would be too much overhead on your sql server. I was running queries last week against a journal vault store with over 50 million items and they were taking just a few minutes.
02-24-2012 02:41 PM
I was looking to do it in increments. I wasn't sure what the impact on the system would be or if possible at all. We would like to run in report mode to see how much space we could regain by doing such increments. We use Snap manager and when there are significant changes, we fill that space as well. So if we could get an feel for how much space we would free up by doing an expiry incrementally that would give us some numbers to work with. This is going to take a while I'm sure.
02-24-2012 02:44 PM
I will give the SQL Query a try. And the org with 50 million makes me feel better about my system...
03-05-2012 04:29 PM
We ran the SQL queries and got some odd results. We actually migrated from Groupwise to Exchange 2007 in 2009. So we got results from the two queries and decided to start a expiry based on Archive date of 34 months which removed 21 items. I was expecting quite a bit more. However it is a start. Now we are going with 32 months and the expiry did not find any items to delete. Is there something that needs to be done to make the expiry find the items? Do I need to resychronize or something since I actually created a new retention category and assigned it to the journal? Any assitance is most appreciated.
ITEM DATE
2038,27
2030,1
2012,2073270
2011,11384947
2010,10553570
2009,6115977
2008,256
2007,10
2006,11
2005,3
2004,4
2003,2
2002,7
1970,3
Here is what we got for Archive date which is more realistic.
2012,2073382
2011,11384730
2010,10553923
2009,6115943