[rt-users] Any way to speed up shredding?

Christian Loos cloos at netcologne.de
Fri Jun 10 07:03:25 EDT 2016


Am 10.06.2016 um 12:02 schrieb Robert Waldner:
> Hi,
> 
> I'm trying to get rid of old crud (deleted and rejected tickets, mostly
> spam) in our RT-DB, and so use rt-shredder. Which seems to work fine,
> but is so slow that my best estimate for it to finish wiping ~80k
> tickets is "upwards of 6 months":
> 
> time ( rt-shredder --force --plugin "Tickets=query,(status = 'rejected'
> OR status = 'deleted') AND id <610000;limit,10")
> 
> real    9m33.764s
> user    0m6.984s
> sys     0m0.708s
> 
> Any hints on possibilities to speed this up?
> 
> (rt-shredder from RT 3.8 (Debian), incl. RT-IR 2.4, postgres backend)

There are some database indexes suggested:
https://docs.bestpractical.com/rt/4.4.1/RT/Shredder.html#Database-Indexes

I use just some if them, es they improve shredding tickets enough for me:
CREATE INDEX SHREDDER_CGM3 ON CachedGroupMembers (Via, Id);
CREATE UNIQUE INDEX SHREDDER_GM1 ON GroupMembers(MemberId, GroupId);
CREATE INDEX SHREDDER_TXN3 ON Transactions(TYPE, OldValue);
CREATE INDEX SHREDDER_TXN4 ON Transactions(TYPE, NewValue);


Chris



More information about the rt-users mailing list