Reputation: 1567
I have few cronjob that summarize data and validate data for my site. Some of them have processes that needs to be run in background.
Example:
cronjob1.php execute cronjob2.php using exec
This cronjob2.php runs another cronjob3.php using exec
and cronjob3 needs to be completed then cronjob2 and then cronjob finish.
I currently have an issue where the cronjob1.php takes 2 hours to finish.
is there a better way to run this so it run faster?
Thank You
Upvotes: 10
Views: 322
Reputation: 1894
if cronjob1 have many database operation than create store procedures for that and make indexing on most use table fields
this increase your cronjob performance....
Upvotes: 0
Reputation: 27323
There is few things that you can do:
Upvotes: 18