You are not logged in.
Pages: 1
Hello, I use GLPI in XAMPP and I'm having problems sending emails from the notification queue. I searched some solutions here in the forum and I couldn't solve the problem.
I was instructed to create a script with this information:
php C:\xampp\htdocs\helpdesk\front\cron.php --force mailgate
php C:\xampp\htdocs\helpdesk\front\cron.php --force queuedmail
but it doesn't work either. Can anyone help me?
Offline
too little information.
First of all: is email follow up configuration done? Does "send test mail" work?
Offline
Hello, the settings are ok, I can send the emails from the queue manually, the problem is that it does not send automatically.
When I select the email and click send it works. The problem I believe is in cron jobs, it does not make automatic submissions I need to do it manually.
Offline
Did you put the cron script inside windows tasks?
Is "automatic actions" -> "queuednotification" set to "cli" and "scheduled"?
Offline
Hello Kaya 84, thank you very much for your attention and I apologize for the delay in getting back to you.
I configured the windows task scheduler, the task is completed and the result of the last run is reported with the code (0x1).
Even if I run the script manually, the emails from the queue are not sent.
I use GLPI in XAMPP on windows server, the script I'm using is the one below:
php C:\xampp\htdocs\helpdesk\front\cron.php -- force mailgate
php C:\xampp\htdocs\helpdesk\front\cron.php -- force queuedmail
Could you help me, please?
Offline
First:
Try in console the command.
And post the output
Second:
" -- force " there is a blank space between -- and force. The parameter is without blank space " --force"
Offline
Hello, I did the test as requested and the console reported me the following messages:
"C:\xampp\php>php C:\xampp\htdocs\helpdesk\front\cron.php --force mailgate
Cannot load Zend OPcache - it was already loaded
C:\xampp\php>php C:\xampp\htdocs\helpdesk\front\cron.php --force queuedmail
Cannot load Zend OPcache - it was already loaded"
I checked the notifications queue and the emails were not sent
Offline
Go in notification queue, opene one of them. Go to action (top right) and click send.
Is the notification sent?
In glpi -> automatic actions -> queuded notification is seto to CLI, scheduled ?
What is written in "next run " ? and "last run"?
Has the user a valid email address ? and "Notifications for my changes" is set to yes?
Offline
Go in notification queue, open one of them. Go to action (top right) and click send.
Is the notification sent? YES
In glpi -> automatic actions -> queuded notification is set to CLI, scheduled ? YES
What is written in "next run" ? AS SOON AS POSSIBLE (07/12/2023 09:24)
and "last run"? 12-07-2023 09:23 (I clicked the "run" button earlier)
Has the user a valid email address ? YES
and "Notifications for my changes" is set to yes? I didn't understand
When I go to the notification queue and select an email, I click send, the email is sent normally, the problem is in the automatic task itself
Offline
Try without params.
Only:
C:\xampp\php>php C:\xampp\htdocs\helpdesk\front\cron.php
And post output and logs!..
Offline
Hello, when running this command at the prompt it worked normally.
But when I double click to run the script it doesn't work. How can I create the script?
Offline
I got it, it worked. I needed to create the following script below:
CD..
CD..
cd xampp
cd php
php C:\xampp\htdocs\helpdesk\front\cron.php
Thank you for your help!
Offline
Pages: 1