Hello,<br><br>I'd like to ask the mysql experts for any tips that would help improving rtx-shredder performance.<br><br>There database are already has indexes in an attempt to improve the performence:<br>
<br>
CREATE INDEX objectcf_type_id on ObjectCustomFieldValues(Objectid, ObjectType);<br>
CREATE INDEX acl_type_id on ACL(Objectid, ObjectType);<br>
CREATE INDEX acl_princid on ACL(PrincipalId);<br>
<br>Right now, the removal of only one ticket takes between 1:33min. and 1:40min., in the lastest measurements.<br><br>$ /usr/bin/time -h sudo ./rtx-shredder --plugin 'Tickets=status,deleted;queue,general;limit,1'<br>
Next objects would be deleted:<br> RT::Ticket-37203 object<br>Do you want to proceed? [y/N] y<br> 1m33,81s real 1,13s user 0,17s sys<br>------------------<br><br>Last weekend, removing 2.000 tickets took two days:<br>
<br>$ /usr/bin/time -h sudo ./rtx-shredder --plugin 'Tickets=status,deleted;queue,general;limit,2000'<br>2d1h9m24,94s real 11m35,93s user 47,71s sys<br><br><br>The strange part is that four months ago, removing 7.000 tickets too half of this time in another mysql instance running in the very same hardware:<br>
<br># /usr/bin/time -h ./rtx-shredder --plugin 'Tickets=status,deleted;queue,general;limit,7000'<br>21h59m55,19s real 53m14,32s user 1m22,57s sys<br><br>Relevant info:<br>O.S.: FreeBSD-6.2-RELEASE / RT Version: 3.6.5 (installed via FreeBSD ports) / MySQL version: 5.0.51 / Mason: 1.35 / Apache: 1.3.37 (w/ mod_ssl-2.8.28) / Hardware: Dell PowerEdge 2850, CPU: Intel Xeon 3GHz, RAM: 2GB <br>
<br>-------------------------<br># mysql-duplicate-key-checker --databases rt3 <br><br>DATABASE TABLE ENGINE OBJECT TYPE STRUCT PARENT COLUMNS<br>rt3 Attachments MyISAM Attachments1 KEY BTREE NULL `Parent`<br>
rt3 Attachments MyISAM Attachments3 KEY BTREE NULL `Parent`,`TransactionId`<br>rt3 CachedGroupMembers MyISAM DisGrouMem KEY BTREE NULL `GroupId`,`MemberId`,`Disabled`<br>rt3 CachedGroupMembers MyISAM GrouMem KEY BTREE NULL `GroupId`,`MemberId`<br>
rt3 ObjectCustomFieldValues MyISAM TicketCustomFieldValues1 KEY BTREE NULL `CustomField`,`ObjectId`,`Content`<br>rt3 ObjectCustomFieldValues MyISAM TicketCustomFieldValues2 KEY BTREE NULL `CustomField`,`ObjectId`<br>
rt3 Tickets MyISAM PRIMARY KEY BTREE NULL `id`<br>rt3 Tickets MyISAM Tickets4 KEY BTREE NULL `id`,`Status`<br>rt3 Tickets MyISAM Tickets5 KEY BTREE NULL `id`,`EffectiveId`<br>
rt3 Tickets MyISAM Tickets3 KEY BTREE NULL `EffectiveId`<br>rt3 Tickets MyISAM Tickets6 KEY BTREE NULL `EffectiveId`,`Type`<br>rt3 Users MyISAM PRIMARY KEY BTREE NULL `id`<br>
rt3 Users MyISAM Users3 KEY BTREE NULL `id`,`EmailAddress`<br>rt3 Users MyISAM Users1 KEY BTREE NULL `Name`<br>rt3 Users MyISAM Users2 KEY BTREE NULL `Name`<br>-------------------------<br>
<br>The database still have more than 72.278 tickets to be removed. And I'd appreciate any tips that can help improving the removal performance, so we won't have to wait weeks before this cleanup ends.<br><br>Thanks in advance,<br>
<br>Alex<br>