Jump to content

Cronjob stops working after creating invoices


mbsmt

Recommended Posts

Hi.

I have WHMCS version 5.2.17. I have problem on sending invoice emails to customers.

Cronjob works well even for everything, and sends reports every day to my email address. But when an invoice needs to be created, after its creation, cronjob stops working.

Below is a snapshot after running cron job using SSH.

Capture.JPG

Please help me.

Link to comment
Share on other sites

  • 3 weeks later...
Try running it with a debug option (php -q /your whmcs path/admin/cron.php debug) and look for errors.

 

I ran this code before. Again I ran it and this is the result:

 

Starting (Time: 0.72 Memory: 12.13)

Running Pre-Cron Hooks (Time: 0 Memory: 12.13)

Starting Generating Invoices (Time: 0 Memory: 12.13)

Invoicing Loop Service ID 58 - 1 of 7 (Time: 0.01 Memory: 12.13)

Invoicing Loop Service ID 115 - 2 of 7 (Time: 0 Memory: 12.13)

Invoicing Loop Service ID 114 - 3 of 7 (Time: 0 Memory: 12.13)

Invoicing Loop Service ID 110 - 4 of 7 (Time: 0 Memory: 12.13)

Invoicing Loop Service ID 111 - 5 of 7 (Time: 0 Memory: 12.13)

Invoicing Loop Service ID 112 - 6 of 7 (Time: 0 Memory: 12.13)

Invoicing Loop Service ID 113 - 7 of 7 (Time: 0 Memory: 12.13)

Generated Invoice #2159 (Time: 0 Memory: 12.13)

 

And here command stoped running and stayed with not more action ...

Link to comment
Share on other sites

  • WHMCS Support Manager

Hi,

As you see some Cron Job entries but no "Cron Job: Completed" entry this suggests the cron is being terminated prematurely by your server. Please increase the memory_limit setting in your server's php.ini to 64M or 128MB which should easily be sufficient. It would also be worth increasing the max_execution_time setting. Then see if things improve and you start getting the cron job report again over the next few days.

Link to comment
Share on other sites

Hi,

As you see some Cron Job entries but no "Cron Job: Completed" entry this suggests the cron is being terminated prematurely by your server. Please increase the memory_limit setting in your server's php.ini to 64M or 128MB which should easily be sufficient. It would also be worth increasing the max_execution_time setting. Then see if things improve and you start getting the cron job report again over the next few days.

 

Current memory_limit is 128MB and max_execution_time is 30. Also I checked running Cron job. It received to generating first invoice after just some seconds (about 3-5 second) and stopped working after that. So execution time must not be the issue. It's a strange problem ...

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated