[rt-users] Mail Loop 1000+ Bad Tickets

Bruce Campbell bruce_campbell at ripe.net
Wed Nov 21 11:11:45 EST 2001


On Wed, 21 Nov 2001, Jason Maderios wrote:

> My RT (1..0.6) got into a debate with a PVCS ticket system.  Apparently
> they were arguing over who could get the last "Thank You- We recv'd your
> response and it is being handled" in.  Now I have 1000+ open tickets
> clogging my queue.  Anyone know the SQL statement to mysql in witch to
> kill all tickets where requestor = "bad.boy at pvcs.machine" in a manner
> where I do not break anything in RT?

Something like this will do.  You could also add commands within the loop
to remove those RT1 transaction files which are clogging up your disk.

$ for rt in `rtq queuename -open -user bad.boy at pvcs.machine | \
  perl -e 'while(<>){chomp;print "$1\n" if(m/^\s*(\d+)\s+/);}'` ; do \
	echo "yes" | rt -kill $rt ; \
 done

-- 
                             Bruce Campbell                            RIPE
                                                                        NCC
                                                                 Operations





More information about the rt-users mailing list