Unable to shred a ticket


I am trying to shred a ticket but am getting the following regarding dependencies.

"[root@rt bin]# /opt/rt5/sbin/rt-shredder --plugin ‘Tickets=query,id = 477091’
SQL dump file is ‘/opt/rt5/bin/20220718T154600-0001.sql’
Next 1 objects would be deleted:
RT::Ticket-SGUL-477091 object
Do you want to proceed? [y/N] y

ERROR: Dependencies list has reached its limit.
See $RT::DependenciesLimit in RT::Shredder docs.

[419366] [Mon Jul 18 15:46:05 2022] [warning]: Too late to safely run transaction-batch scrips! This is typically caused by using ticket objects at the top-level of a script which uses the RT API. Be sure to explicitly undef such ticket objects, or put them inside of a lexical scope. at /opt/rt5/sbin/…/lib/RT/Ticket.pm line 2757, line 1 during global destruction. (/opt/rt5/sbin/…/lib/RT/Ticket.pm:2757)

Does anyone know how I increase the dependencies for RT? I can’t find it in the documentation.

Thanks in advance.

Kind regards

Is there possibly a circular dependency of some sort? For example you’re trying to delete ticket A, which depends on ticket B, which depends on ticket C which depends on ticket A. Might be worth checking.

Do you have an explanation why I receive the same message by remove old users with

/opt/rt4/sbin/rt-shredder --plugin "Users=no_tickets,1;status,any;replace_relations,Nobody;not_member_of,Privileged;limit,2500" --force

or even

/opt/rt4/sbin/rt-shredder --plugin "Users=no_ticket_transactions,1;status,any;replace_relations,Nobody;not_member_of,Privileged;limit,10000" --force

Honestly, I feel a bit lost.

Did you look at the docs for RT::Shredder? Specifically RT::Shredder - RT 5.0.1 Documentation - Best Practical ? If you’ve got tickets with lots of transactions/attachments against them you might be hitting the 1000 dependency limit.

But why is this relevant If I’m deleting “Users” with “No Tickets”?

We have ~150,000 users, >800,000 Tickets, and 2,500,000 Transactions in the database. I’m sure that at least ~30 % are coming from Spam.

Yes, I read all documentation and comments in the lib/RT/Shredder/Plugins/*.pm files. There are still options for improvement, for example, introducing an option for deleting a user that fits not to a specific mask. We are still on 4.4.3 but planing to migrate by first solving the utf8/utf8mb4 issue on Debian 10.