Change Daily Execution of Position History deletion

Gps man5 years ago

How can I change the daily execution of Position History Deletion or How can I change it to some other time instead of server restart time that is taken by default......

Anton Tananaev5 years ago

Change the code. There is no configuration for it.

Gps man5 years ago

In this case how can we disable this process and execute it manually over a period of 7 days.....

Gps man5 years ago

The major issue is that during this period real-time tracking gets blocked

Anton Tananaev5 years ago

Just disable cleanup in Traccar and use an external script. In fact that's what we do for most of our servers. You can have a script that deletes by 10k rows at a time to avoid blocking anything.

Gps man5 years ago

Thanks for the prompt response. How do I disable cleanup ? Where can I find the script that deletes 10k rows at a time ?

Anton Tananaev5 years ago

How did you enable it? You disable by removing that config parameter.

Gps man5 years ago

So I remove position history line <entry key='database.positionsHistoryDays'>90</entry>
from the traccar.xml ? And where can I find that script that deletes 10k record and how do I setup the same externally. Pl guide

Anton Tananaev5 years ago

Well, you'll have to write that script.

Gps man5 years ago

Can I get that through your professional service ?

Anton Tananaev5 years ago

Yes, of course.