Questions and discussion about using ProcessMaker: user interface, running cases & functionality
By azatrath
#815559
hi,

i have a huge problem about pending message. Some of my mail is sent and others still pending. my sub department working with mails. now i need to check which mails are sent or which ones are pending.

i need to send all pending mails. can you help me ?
Attachments
Ekran Alıntısı.PNG
Ekran Alıntısı.PNG (14.67 KiB) Viewed 7263 times
User avatar
By amosbatto
#815593
From your screenshot it looks like you just clicked on the cron.php and tried to execute it, which is the wrong way to do it.
You need to execute the cron.php file in the way explained on the wiki.

If you are executing it the right way, then you might have bad code in one of your triggers which causes it to crash. I always test triggers by running cases inside ProcessMaker before I try executing them with cron.php.

By the way, if cron.php is already executing, you should use the +f option to force it to kill the existing job and execute again:
php cron.php +f
By azatrath
#815603
amosbatto wrote: Wed Aug 08, 2018 11:11 pm From your screenshot it looks like you just clicked on the cron.php and tried to execute it, which is the wrong way to do it.
You need to execute the cron.php file in the way explained on the wiki.

If you are executing it the right way, then you might have bad code in one of your triggers which causes it to crash. I always test triggers by running cases inside ProcessMaker before I try executing them with cron.php.

By the way, if cron.php is already executing, you should use the +f option to force it to kill the existing job and execute again:
php cron.php +f
i need to force it, ty amos
By azatrath
#815650
amosbatto wrote: Wed Aug 08, 2018 11:11 pm From your screenshot it looks like you just clicked on the cron.php and tried to execute it, which is the wrong way to do it.
You need to execute the cron.php file in the way explained on the wiki.

If you are executing it the right way, then you might have bad code in one of your triggers which causes it to crash. I always test triggers by running cases inside ProcessMaker before I try executing them with cron.php.

By the way, if cron.php is already executing, you should use the +f option to force it to kill the existing job and execute again:
php cron.php +f
amos,

i schelued task to start cron to every 15 minutes , but this mail still waiting as a pending and they not sending back. i need to send all of mails immediatly. how can i handle it?
User avatar
By amosbatto
#815657
I just tried it in PM 3.2.1 and executing cron.php doesn't seem to send out the pending emails. It used to work.

OK, the only solution is to assign one of your users the "Resend" permission in each process:
resendPermission.png
resendPermission.png (27.44 KiB) Viewed 7186 times
Then, go to Admin > Logs > Emails to search for the list of pending emails:
ListOfPendingEmails.png
ListOfPendingEmails.png (66.8 KiB) Viewed 7186 times
Then, login as the user who has the right to resend emails and open each case with a pending email. Go to Information > Messages History to see the pending email. Click on the Resend icon to the right of email message:
ResendEmail.png
ResendEmail.png (137.16 KiB) Viewed 7186 times
Click OK to confirm resending the email:
resendEmail.png
resendEmail.png (17.95 KiB) Viewed 7186 times
Then a second email should appear with its Status marked as "Sent":
ResentEmail.png
ResentEmail.png (17.48 KiB) Viewed 7186 times
By azatrath
#815679
amosbatto wrote: Mon Aug 13, 2018 10:18 pm I just tried it in PM 3.2.1 and executing cron.php doesn't seem to send out the pending emails. It used to work.

OK, the only solution is to assign one of your users the "Resend" permission in each process:
resendPermission.png

Then, go to Admin > Logs > Emails to search for the list of pending emails:
ListOfPendingEmails.png

Then, login as the user who has the right to resend emails and open each case with a pending email. Go to Information > Messages History to see the pending email. Click on the Resend icon to the right of email message:
ResendEmail.png

Click OK to confirm resending the email:
resendEmail.png

Then a second email should appear with its Status marked as "Sent":
ResentEmail.png
i have already know this solution but i had to complete 1050 times. i am trying to get short cut :/
User avatar
By amosbatto
#815693
I looked through the source code to figure this out.

cron.php only sends out pending emails which were scheduled to be sent in the last 7 days. If you want cron.php to send out earlier emails you have to set the date.

For example, the following command sends out all pending emails since January 1, 2015 on a CentOS server:
cd /opt/processmaker/workflow/engine/bin
su
su -s /bin/sh apache -c "php ./cron.php emails +d'2015-01-01 01:00:00' +force"
By azatrath
#815857
amosbatto wrote: Wed Aug 15, 2018 12:45 am I looked through the source code to figure this out.

cron.php only sends out pending emails which were scheduled to be sent in the last 7 days. If you want cron.php to send out earlier emails you have to set the date.

For example, the following command sends out all pending emails since January 1, 2015 on a CentOS server:
cd /opt/processmaker/workflow/engine/bin
su
su -s /bin/sh apache -c "php ./cron.php emails +d'2015-01-01 01:00:00' +force"
i am using windows server 2012. i tried something same but cant handle it. btw i got this problem when i am trying to what you said earlier. when i run as admin there is no problem. this problem not including in your wikia.
Attachments
Adsız.png
Adsız.png (73.23 KiB) Viewed 7133 times
User avatar
By amosbatto
#815868
Can you post the text of the error messages? It is too small for me to read it in the image. Thanks.
By azatrath
#815892
amosbatto wrote: Thu Aug 30, 2018 6:10 pm Can you post the text of the error messages? It is too small for me to read it in the image. Thanks.
Attachments
Adsız.png
Adsız.png (246.95 KiB) Viewed 7107 times
User avatar
By amosbatto
#815898
What version of PM do you have? Manual install or Bitnami install?

I don't know if this your problem, but in your gulliver/system/class.monologProvider.php:32 file change to:
Code: Select all
    public $filePermission = 0777;
Then, go to the shared/{workspace}/log directory and either delete all the processmaker-XXXX-XX-XX.log files or change all their file permissions so they are both readable and writable. Then change your shared/log/cron.log file so it is readable and writeable by all users (or delete it and it will be recreated).

Then, try to execute cron.php again.
By azatrath
#815912
amosbatto wrote: Mon Sep 03, 2018 9:27 pm What version of PM do you have? Manual install or Bitnami install?

I don't know if this your problem, but in your gulliver/system/class.monologProvider.php:32 file change to:
Code: Select all
    public $filePermission = 0777;
Then, go to the shared/{workspace}/log directory and either delete all the processmaker-XXXX-XX-XX.log files or change all their file permissions so they are both readable and writable. Then change your shared/log/cron.log file so it is readable and writeable by all users (or delete it and it will be recreated).

Then, try to execute cron.php again.
i changed windows permission to deal with problem and i think its ok right now. thank you amos.
Want to create your own meme coin?

In the world of cryptocurrencies, a unique and exc[…]

The market for cryptocurrencies is demonstrating a[…]

What's SAP FICO?

Embarking on a dissertation can be one of the most[…]

Hello. For rental housing, there are software solu[…]