I guys,
I haven’t come across a straight answer to this, so my apologies if this
has been answered before.
I have a 3.6 Request Tracker instance running… (and no… updating right
now is not possible)…
I want to delete all tickets (and respective attachments, etc) that are
older than 2 years…
My approach is using rt-shredder… by installing the cpan module (
RTx::Shredder - DEPRECATED Cleanup RT database - metacpan.org )
So what is the cli command to do this? I don’t need backups… so no dump
is required…
I have about 600 Gb worth of data… 99% on the attachments table… And
want to clean all this up…
There is an answer on the mailling list about this on Jul 13, 2004… that
simply says that to delete for a giving year do:
rtx-shredder YYYY-MM-DD
But seems to old…
Can you help me? seems like a basic think to do…
Thanks in advance.
Yours trully
Flávio Moringa
Project Leader
Caixa Mágica Software
Energia Open Source
Rua Soeiro Pereira Gomes, Lote 1 - 4.º B,
Edifício Espanha, 1600-196 Lisboa - Portugal
Tel.: +351 217 921 260 Fax: +351 217 921 261
https://twitter.com/flaviomoringa
Redirecting... https://www.facebook.com/flavio.moringa
http://pt.linkedin.com/in/flaviomoringa
http://people.caixamagica.pt/flaviomoringa
Bart
April 9, 2013, 5:56am
2
This page contains the info on the command:
And some info if you want to use the API:
Another thing you might want to look at are the extension Utils:
RT::Extension::Utils - collection of command line utilities - metacpan.org
As Kevin puts it, Utils are Ruslans bag of tricks. It also contains a
commando for extracting attachments/deleting tickets, so maybe that’s what
you can use to make things a bit more easy. (the manifest page shows the
included commands)
Hope this helps a little.2013/4/8 Flavio Moringa flavio.moringa@caixamagica.pt
I guys,
I haven’t come across a straight answer to this, so my apologies if this
has been answered before.
I have a 3.6 Request Tracker instance running… (and no… updating right
now is not possible)…
I want to delete all tickets (and respective attachments, etc) that are
older than 2 years…
My approach is using rt-shredder… by installing the cpan module (
RTx::Shredder - DEPRECATED Cleanup RT database - metacpan.org )
So what is the cli command to do this? I don’t need backups… so no dump
is required…
I have about 600 Gb worth of data… 99% on the attachments table… And
want to clean all this up…
There is an answer on the mailling list about this on Jul 13, 2004…
that simply says that to delete for a giving year do:
rtx-shredder YYYY-MM-DD
But seems to old…
Can you help me? seems like a basic think to do…
Thanks in advance.
Yours trully
Flávio Moringa
Project Leader
Caixa Mágica Software
Energia Open Source
Rua Soeiro Pereira Gomes, Lote 1 - 4.º B,
Edifício Espanha, 1600-196 Lisboa - Portugal
Tel.: +351 217 921 260 Fax: +351 217 921 261
http://www.caixamagica.pt
https://twitter.com/flaviomoringa
Redirecting... https://www.facebook.com/flavio.moringa
Flávio Moringa - Mercedes-Benz.io | LinkedIn
http://people.caixamagica.pt/flaviomoringa
Bart G.
I,
thanks a lot for your help…
The util “rt-delete-tickets-mysql” seems to be perfect for what I want…
I just have to change the initial query from:
“DELETE FROM Tickets WHERE Status = deleted”
to
“DELETE FROM Tickets WHERE LastUpdate = ‘2 year ago’”
Now I just have to find the right query…
Again thanks a lot for your help… I didn’t know about that utils
package…
Cheers
Flávio Moringa
Project Leader
Caixa Mágica Software
Energia Open Source
Rua Soeiro Pereira Gomes, Lote 1 - 4.º B,
Edifício Espanha, 1600-196 Lisboa - Portugal
Tel.: +351 217 921 260 Fax: +351 217 921 261
At Caixa Mágica, we specialize in creating custom software solutions that drive growth, enhance efficiency, and spark transformation.
https://twitter.com/flaviomoringa
Redirecting... https://www.facebook.com/flavio.moringa
Flávio Moringa - Mercedes-Benz.io | LinkedIn
http://people.caixamagica.pt/flaviomoringa2013/4/9 Bart bart@pleh.info
This page contains the info on the command:
And some info if you want to use the API:
Another thing you might want to look at are the extension Utils:
RT::Extension::Utils - collection of command line utilities - metacpan.org
As Kevin puts it, Utils are Ruslans bag of tricks. It also contains a
commando for extracting attachments/deleting tickets, so maybe that’s what
you can use to make things a bit more easy. (the manifest page shows the
included commands)
Hope this helps a little.
2013/4/8 Flavio Moringa flavio.moringa@caixamagica.pt
I guys,
I haven’t come across a straight answer to this, so my apologies if this
has been answered before.
I have a 3.6 Request Tracker instance running… (and no… updating
right now is not possible)…
I want to delete all tickets (and respective attachments, etc) that are
older than 2 years…
My approach is using rt-shredder… by installing the cpan module (
RTx::Shredder - DEPRECATED Cleanup RT database - metacpan.org )
So what is the cli command to do this? I don’t need backups… so no dump
is required…
I have about 600 Gb worth of data… 99% on the attachments table…
And want to clean all this up…
There is an answer on the mailling list about this on Jul 13, 2004…
that simply says that to delete for a giving year do:
rtx-shredder YYYY-MM-DD
But seems to old…
Can you help me? seems like a basic think to do…
Thanks in advance.
Yours trully
Flávio Moringa
Project Leader
Caixa Mágica Software
Energia Open Source
Rua Soeiro Pereira Gomes, Lote 1 - 4.º B,
Edifício Espanha, 1600-196 Lisboa - Portugal
Tel.: +351 217 921 260 Fax: +351 217 921 261
http://www.caixamagica.pt
https://twitter.com/flaviomoringa
Redirecting... https://www.facebook.com/flavio.moringa
Flávio Moringa - Mercedes-Benz.io | LinkedIn
http://people.caixamagica.pt/flaviomoringa
–
Bart G.
Huumm… still didn’t try it but this query should do the trick:
DELETE FROM Tickets WHERE Created <= date_sub(NOW(), interval 2 year);
Cheers
Flávio Moringa
Project Leader
Caixa Mágica Software
Energia Open Source
Rua Soeiro Pereira Gomes, Lote 1 - 4.º B,
Edifício Espanha, 1600-196 Lisboa - Portugal
Tel.: +351 217 921 260 Fax: +351 217 921 261
At Caixa Mágica, we specialize in creating custom software solutions that drive growth, enhance efficiency, and spark transformation.
https://twitter.com/flaviomoringa
Redirecting... https://www.facebook.com/flavio.moringa
Flávio Moringa - Mercedes-Benz.io | LinkedIn
http://people.caixamagica.pt/flaviomoringa2013/4/9 Flavio Moringa flavio.moringa@caixamagica.pt
I,
thanks a lot for your help…
The util “rt-delete-tickets-mysql” seems to be perfect for what I
want… I just have to change the initial query from:
“DELETE FROM Tickets WHERE Status = deleted”
to
“DELETE FROM Tickets WHERE LastUpdate = ‘2 year ago’”
Now I just have to find the right query…
Again thanks a lot for your help… I didn’t know about that utils
package…
Cheers
Flávio Moringa
Project Leader
Caixa Mágica Software
Energia Open Source
Rua Soeiro Pereira Gomes, Lote 1 - 4.º B,
Edifício Espanha, 1600-196 Lisboa - Portugal
Tel.: +351 217 921 260 Fax: +351 217 921 261
http://www.caixamagica.pt
https://twitter.com/flaviomoringa
Redirecting... https://www.facebook.com/flavio.moringa
Flávio Moringa - Mercedes-Benz.io | LinkedIn
http://people.caixamagica.pt/flaviomoringa
2013/4/9 Bart bart@pleh.info
This page contains the info on the command:
And some info if you want to use the API:
Another thing you might want to look at are the extension Utils:
RT::Extension::Utils - collection of command line utilities - metacpan.org
As Kevin puts it, Utils are Ruslans bag of tricks. It also contains a
commando for extracting attachments/deleting tickets, so maybe that’s what
you can use to make things a bit more easy. (the manifest page shows the
included commands)
Hope this helps a little.
2013/4/8 Flavio Moringa flavio.moringa@caixamagica.pt
I guys,
I haven’t come across a straight answer to this, so my apologies if this
has been answered before.
I have a 3.6 Request Tracker instance running… (and no… updating
right now is not possible)…
I want to delete all tickets (and respective attachments, etc) that are
older than 2 years…
My approach is using rt-shredder… by installing the cpan module (
RTx::Shredder - DEPRECATED Cleanup RT database - metacpan.org )
So what is the cli command to do this? I don’t need backups… so no
dump is required…
I have about 600 Gb worth of data… 99% on the attachments table…
And want to clean all this up…
There is an answer on the mailling list about this on Jul 13, 2004…
that simply says that to delete for a giving year do:
rtx-shredder YYYY-MM-DD
But seems to old…
Can you help me? seems like a basic think to do…
Thanks in advance.
Yours trully
Flávio Moringa
Project Leader
Caixa Mágica Software
Energia Open Source
Rua Soeiro Pereira Gomes, Lote 1 - 4.º B,
Edifício Espanha, 1600-196 Lisboa - Portugal
Tel.: +351 217 921 260 Fax: +351 217 921 261
http://www.caixamagica.pt
https://twitter.com/flaviomoringa
Redirecting... https://www.facebook.com/flavio.moringa
Flávio Moringa - Mercedes-Benz.io | LinkedIn
http://people.caixamagica.pt/flaviomoringa
–
Bart G.
Don’t change the script. Change status first.
UPDATE Tickets SET Status = ‘deleted’ WHERE LastUpdated …
Also, LastUpdated is better date unless you have a reason.On Tue, Apr 9, 2013 at 2:46 PM, Flavio Moringa < flavio.moringa@caixamagica.pt> wrote:
Huumm… still didn’t try it but this query should do the trick:
DELETE FROM Tickets WHERE Created <= date_sub(NOW(), interval 2 year);
Cheers
Flávio Moringa
Project Leader
Caixa Mágica Software
Energia Open Source
Rua Soeiro Pereira Gomes, Lote 1 - 4.º B,
Edifício Espanha, 1600-196 Lisboa - Portugal
Tel.: +351 217 921 260 Fax: +351 217 921 261
http://www.caixamagica.pt
https://twitter.com/flaviomoringa
Redirecting... https://www.facebook.com/flavio.moringa
Flávio Moringa - Mercedes-Benz.io | LinkedIn
http://people.caixamagica.pt/flaviomoringa
2013/4/9 Flavio Moringa flavio.moringa@caixamagica.pt
I,
thanks a lot for your help…
The util “rt-delete-tickets-mysql” seems to be perfect for what I
want… I just have to change the initial query from:
“DELETE FROM Tickets WHERE Status = deleted”
to
“DELETE FROM Tickets WHERE LastUpdate = ‘2 year ago’”
Now I just have to find the right query…
Again thanks a lot for your help… I didn’t know about that utils
package…
Cheers
Flávio Moringa
Project Leader
Caixa Mágica Software
Energia Open Source
Rua Soeiro Pereira Gomes, Lote 1 - 4.º B,
Edifício Espanha, 1600-196 Lisboa - Portugal
Tel.: +351 217 921 260 Fax: +351 217 921 261
http://www.caixamagica.pt
https://twitter.com/flaviomoringa
Redirecting... https://www.facebook.com/flavio.moringa
Flávio Moringa - Mercedes-Benz.io | LinkedIn
http://people.caixamagica.pt/flaviomoringa
2013/4/9 Bart bart@pleh.info
This page contains the info on the command:
And some info if you want to use the API:
Another thing you might want to look at are the extension Utils:
RT::Extension::Utils - collection of command line utilities - metacpan.org
As Kevin puts it, Utils are Ruslans bag of tricks. It also contains a
commando for extracting attachments/deleting tickets, so maybe that’s what
you can use to make things a bit more easy. (the manifest page shows the
included commands)
Hope this helps a little.
2013/4/8 Flavio Moringa flavio.moringa@caixamagica.pt
I guys,
I haven’t come across a straight answer to this, so my apologies if
this has been answered before.
I have a 3.6 Request Tracker instance running… (and no… updating
right now is not possible)…
I want to delete all tickets (and respective attachments, etc) that are
older than 2 years…
My approach is using rt-shredder… by installing the cpan module (
RTx::Shredder - DEPRECATED Cleanup RT database - metacpan.org )
So what is the cli command to do this? I don’t need backups… so no
dump is required…
I have about 600 Gb worth of data… 99% on the attachments table…
And want to clean all this up…
There is an answer on the mailling list about this on Jul 13, 2004…
that simply says that to delete for a giving year do:
rtx-shredder YYYY-MM-DD
But seems to old…
Can you help me? seems like a basic think to do…
Thanks in advance.
Yours trully
Flávio Moringa
Project Leader
Caixa Mágica Software
Energia Open Source
Rua Soeiro Pereira Gomes, Lote 1 - 4.º B,
Edifício Espanha, 1600-196 Lisboa - Portugal
Tel.: +351 217 921 260 Fax: +351 217 921 261
http://www.caixamagica.pt
https://twitter.com/flaviomoringa
Redirecting... https://www.facebook.com/flavio.moringa
Flávio Moringa - Mercedes-Benz.io | LinkedIn
http://people.caixamagica.pt/flaviomoringa
–
Bart G.
Best regards, Ruslan.