[Skip to main content](#vessel-content)

#   cron job changing run time

##

- **[Udo](/forum/user/29928-udo "View Udo's Profile")**
- [![Udo's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/29928-udo "View Udo's Profile") Topic Author
- [ Offline](/forum/user/29928-udo)

Less More

- Posts: 220
- Thank you received: 8
-
-
-

4 years 1 week ago [\#346776](#346776) by [Udo](/forum/user/29928-udo "View Udo's Profile")  *[cron job changing run time](/forum/44-mass-actions/905392-cron-job-changing-run-time#346776 "-- HikaShop version -- : 4.5.0 -- Joomla version -- : 3.10.6 -- PHP version -- : 7.4.33  Hi,  I'm using the Hikashop cron service. &#42; The cron of the Out of stock notification plugin is set to run at 02. 59 h &#42; 2 mass actions with the trigger &quot;every day&quot; are set to run one hour later, at 04.00 h (unix timestamp in namekey massaction&#95;last&#95;trigger&#95;days)  This works fine in the first night : plugin at 03.08h and massaction at 04.07h But after that the time is changing. In the second and third night:: plugin at 04.07h and massaction at 05.08h. However in the fourth night: plugin at 05.08h and massaction at 05.08h In the fifth night: plugin at 06.08h and massaction at 06.08h In the sixthh night: plugin at 076.08h and massaction at 07.08h  So the time difference between the two jobs disappears, and every subsequent night the jobs are running one hour later. How to correct this undesirable behaviour?  Configuration cron task: The minimum delay item between two crown tasks is 15 minutes The frequency is every 1 hour. Sometimes it runs at xx.07h and sometimes at xx.08h  Kind regards, Udo")* was created by *[Udo](/forum/user/29928-udo "View Udo's Profile")*

-- HikaShop version -- : 4.5.0
-- Joomla version -- : 3.10.6
-- PHP version -- : 7.4.33

Hi,

I'm using the Hikashop cron service.
* The cron of the Out of stock notification plugin is set to run at 02. 59 h
* 2 mass actions with the trigger "every day" are set to run one hour later, at 04.00 h (unix timestamp in namekey massaction_last_trigger_days)

This works fine in the first night : plugin at 03.08h and massaction at 04.07h
But after that the time is changing.
In the second and third night:: plugin at 04.07h and massaction at 05.08h.
However in the fourth night: plugin at 05.08h and massaction at 05.08h
In the fifth night: plugin at 06.08h and massaction at 06.08h
In the sixthh night: plugin at 076.08h and massaction at 07.08h

So the time difference between the two jobs disappears, and every subsequent night the jobs are running one hour later.
How to correct this undesirable behaviour?

Configuration cron task:
The minimum delay item between two crown tasks is 15 minutes
The frequency is every 1 hour. Sometimes it runs at xx.07h and sometimes at xx.08h

Kind regards,
Udo

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtL21hc3MtYWN0aW9ucy85MDUzOTItY3Jvbi1qb2ItY2hhbmdpbmctcnVuLXRpbWU/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png?1793428657)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Offline](/forum/user/63-nicolas)

Less More

- Posts: 86589
- Thank you received: 14327
-
-

4 years 1 week ago [\#346781](#346781) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[cron job changing run time](/forum/44-mass-actions/905392-cron-job-changing-run-time#346781 "-- HikaShop version -- : 4.5.0 -- Joomla version -- : 3.10.6 -- PHP version -- : 7.4.33  Hi,  I'm using the Hikashop cron service. &#42; The cron of the Out of stock notification plugin is set to run at 02. 59 h &#42; 2 mass actions with the trigger &quot;every day&quot; are set to run one hour later, at 04.00 h (unix timestamp in namekey massaction&#95;last&#95;trigger&#95;days)  This works fine in the first night : plugin at 03.08h and massaction at 04.07h But after that the time is changing. In the second and third night:: plugin at 04.07h and massaction at 05.08h. However in the fourth night: plugin at 05.08h and massaction at 05.08h In the fifth night: plugin at 06.08h and massaction at 06.08h In the sixthh night: plugin at 076.08h and massaction at 07.08h  So the time difference between the two jobs disappears, and every subsequent night the jobs are running one hour later. How to correct this undesirable behaviour?  Configuration cron task: The minimum delay item between two crown tasks is 15 minutes The frequency is every 1 hour. Sometimes it runs at xx.07h and sometimes at xx.08h  Kind regards, Udo")*

Hi,

The dates you set in the plugin and in the config for the mass actions is the "last time the process was run". And to be able to check if the process can run, it checks that the current date is bigger than the "last time the process was run" + the frequency.
So if a process runs at 1h00 one day and you have a cron task running once every hour at 00 minutes each hour, it means that the next day, when the the cron is triggered at 1h00, it won't be bigger than the "last time the process was run" + 1day, and thus is will want for the next cron task at 2h00.
To mitigate that, you could configure your cron task to run every minute. For example, this service can do it for you: [ cron-job.org/en/](https://cron-job.org/en/)
That way, the process will only shift by 1 minute every day.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtL21hc3MtYWN0aW9ucy85MDUzOTItY3Jvbi1qb2ItY2hhbmdpbmctcnVuLXRpbWU/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[Udo](/forum/user/29928-udo "View Udo's Profile")**
- [![Udo's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/29928-udo "View Udo's Profile") Topic Author
- [ Offline](/forum/user/29928-udo)

Less More

- Posts: 220
- Thank you received: 8
-
-
-

4 years 1 week ago [\#346805](#346805) by [Udo](/forum/user/29928-udo "View Udo's Profile")  Replied by *[Udo](/forum/user/29928-udo "View Udo's Profile")* on topic *[cron job changing run time](/forum/44-mass-actions/905392-cron-job-changing-run-time#346805 "-- HikaShop version -- : 4.5.0 -- Joomla version -- : 3.10.6 -- PHP version -- : 7.4.33  Hi,  I'm using the Hikashop cron service. &#42; The cron of the Out of stock notification plugin is set to run at 02. 59 h &#42; 2 mass actions with the trigger &quot;every day&quot; are set to run one hour later, at 04.00 h (unix timestamp in namekey massaction&#95;last&#95;trigger&#95;days)  This works fine in the first night : plugin at 03.08h and massaction at 04.07h But after that the time is changing. In the second and third night:: plugin at 04.07h and massaction at 05.08h. However in the fourth night: plugin at 05.08h and massaction at 05.08h In the fifth night: plugin at 06.08h and massaction at 06.08h In the sixthh night: plugin at 076.08h and massaction at 07.08h  So the time difference between the two jobs disappears, and every subsequent night the jobs are running one hour later. How to correct this undesirable behaviour?  Configuration cron task: The minimum delay item between two crown tasks is 15 minutes The frequency is every 1 hour. Sometimes it runs at xx.07h and sometimes at xx.08h  Kind regards, Udo")*

Hi,
Thanks for your information.

If I understand correctly, it is impossible that crons jobs run every day at the same time.
If I set the Hikashop cron task at a frequency of 15 minutes then the run time will shift 15 minutes every day.

Isn't it overload to run a cron taks every minute?
Then the server is triggered 1440 times each day while only 2 moments a job has to be executed.
Does this slow the website down?

regards,
Udo

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtL21hc3MtYWN0aW9ucy85MDUzOTItY3Jvbi1qb2ItY2hhbmdpbmctcnVuLXRpbWU/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png?1793428657)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Offline](/forum/user/63-nicolas)

Less More

- Posts: 86589
- Thank you received: 14327
-
-

4 years 1 week ago [\#346817](#346817) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[cron job changing run time](/forum/44-mass-actions/905392-cron-job-changing-run-time#346817 "-- HikaShop version -- : 4.5.0 -- Joomla version -- : 3.10.6 -- PHP version -- : 7.4.33  Hi,  I'm using the Hikashop cron service. &#42; The cron of the Out of stock notification plugin is set to run at 02. 59 h &#42; 2 mass actions with the trigger &quot;every day&quot; are set to run one hour later, at 04.00 h (unix timestamp in namekey massaction&#95;last&#95;trigger&#95;days)  This works fine in the first night : plugin at 03.08h and massaction at 04.07h But after that the time is changing. In the second and third night:: plugin at 04.07h and massaction at 05.08h. However in the fourth night: plugin at 05.08h and massaction at 05.08h In the fifth night: plugin at 06.08h and massaction at 06.08h In the sixthh night: plugin at 076.08h and massaction at 07.08h  So the time difference between the two jobs disappears, and every subsequent night the jobs are running one hour later. How to correct this undesirable behaviour?  Configuration cron task: The minimum delay item between two crown tasks is 15 minutes The frequency is every 1 hour. Sometimes it runs at xx.07h and sometimes at xx.08h  Kind regards, Udo")*

Hi,

It's not overload. When you call the cron task URL, HikaShop will see if there is any processing to do. If there is none it won't do anything. So it's better to have a high frequency like "every minute" if you want as less time shift as possible, and it won't add any load on the website.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtL21hc3MtYWN0aW9ucy85MDUzOTItY3Jvbi1qb2ItY2hhbmdpbmctcnVuLXRpbWU/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

Board Categories HikaShop Install &amp; Update Product &amp; Category Display Content Creation Sales and Orders Orders management Reports &amp; Statistics Customers Checkout Payment Methods Shipping Methods Import &amp; Export (CSV, XLS…) Specific Features Affilation Taxes Wishlist Vote Carousel &amp; Slider Mass Actions Filters &amp; Search Discount &amp; Coupon Feature Request Integrations Showcase General Talk about HikaShop Development HikaShop 3.0 Beta Translation Commercial Jobs HikaShop Components HikaMarket Market: Feature requests Market: How to? Market: Bug Report HikaSerial General talk about HikaSerial Serial: Bug Report Serial: How to? Support en Français de HikaSerial (French Support) HikaSubscription HikaAuction Auction: Feature requests Auction: How to? Auction: Bug report Hikashop around the world Support en Français (French Support) Russian FAQ. Курс выживания с Hikashop. Частые вопросы и о Расширения Hikashop Наши сайты на Hikashop 日本語版サポート(Japanese Support) Thai German Archives Bug Report How to?

[](/forum/topics/feed/mode-topics?format=feed&type=rss)

Time to create page: 0.048 seconds

[Powered by](/forum/credits) [Kunena Forum](https://www.kunena.org)
