We are happy to announce that Vesta is back under active development as of 25 February 2024. We are working on Vesta 2.0 and expect to release it by the end of 2024. Read more about it: https://vestacp.com/docs/vesta-2-development
Cron Is Generating Frozen Messages
Cron Is Generating Frozen Messages
I have a cron job for user username that runs every 15 minutes. Cron job is set using Vesta admin panel.
This cron job generates frozen email messages to [email protected], because there is no such address. So they pile up very quickly.
Notifications are turned off and the CRON job does not send any messages itself.
How can i stop this? Is this normal? Is it because of Vesta or something on the server? I haven't changed much from the default Debian installation.
here is one of the messages generated and viewed by exim -Mvb 1b2xZF-0000RA-EG
Debian version 8.4
I don't know if that helps, but i recently moved this vesta account from one server (also Vesta) to another.
This cron job generates frozen email messages to [email protected], because there is no such address. So they pile up very quickly.
Notifications are turned off and the CRON job does not send any messages itself.
How can i stop this? Is this normal? Is it because of Vesta or something on the server? I haven't changed much from the default Debian installation.
here is one of the messages generated and viewed by exim -Mvb 1b2xZF-0000RA-EG
Code: Select all
1b2xZF-0000RA-EG-D
This message was created automatically by mail delivery software.
A message that you sent could not be delivered to one or more of its
recipients. This is a permanent error. The following address(es) failed:
[email protected]
Unrouteable address
------ This is a copy of the message, including all the headers. ------
Return-path: <[email protected]>
Received: from pepe by prom01.partneris.net with local (Exim 4.84_2)
(envelope-from <[email protected]>)
id 1b2xZF-0000R6-DU
for [email protected]; Wed, 18 May 2016 12:15:01 +0300
From: [email protected] (Cron Daemon)
To: [email protected]
Subject: Cron <username@hostname> php -q /home/username/web/webdir.com/public_html/cronscript.php
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-Cron-Env: <SHELL=/bin/sh>
X-Cron-Env: <HOME=/home/pepe>
X-Cron-Env: <PATH=/usr/bin:/bin>
X-Cron-Env: <LOGNAME=pepe>
Message-Id: <[email protected]>
Date: Wed, 18 May 2016 12:15:01 +0300
Last Run: 2016-05-18 09:15:01 - Processed 143 entries in 0.23913216590881 seconds.
I don't know if that helps, but i recently moved this vesta account from one server (also Vesta) to another.
Last edited by xguntis on Thu May 19, 2016 6:38 am, edited 1 time in total.
-
- Collaborator
- Posts: 783
- Joined: Mon May 11, 2015 8:43 am
- Contact:
- Os: CentOS 6x
- Web: apache + nginx
Re: Cron Is Generating Frozen Messages
I guess your script is failing. add >/dev/null 2>&1 add the end of your cron command.
eg.:
eg.:
Code: Select all
php -q /home/web..../....php >/dev/null 2>&1
Re: Cron Is Generating Frozen Messages
no the script does not fail - you can see the output of the script at the end of generated email:tjebbeke wrote:I guess your script is failing. add >/dev/null 2>&1 add the end of your cron command.
Code: Select all
Last Run: 2016-05-18 09:15:01 - Processed 143 entries in 0.23913216590881 seconds.
Last edited by xguntis on Thu May 19, 2016 6:39 am, edited 1 time in total.
Re: Cron Is Generating Frozen Messages
What do you get with a
Code: Select all
exim -bt <email sending to>
Re: Cron Is Generating Frozen Messages
Try creating a mail domain for the full qualified host, create a user called root, add your email address to the forwards text box. Check "Do not store forwarded mail".
Check your exim4.conf.template
Modify
Under ACL - comment out
Add
if getting lots of warnings about environment
Restart Exim4 service.
Check your exim4.conf.template
Modify
Code: Select all
hostlist relay_from_hosts = localhost
Code: Select all
# require verify = sender
Code: Select all
keep_environment =
Restart Exim4 service.
Re: Cron Is Generating Frozen Messages
That way i will receive email every 15 minutes, won't I? The problem is that CRON is sending email to non-existing e-mail where it shouldn't.Try creating a mail domain for the full qualified host, create a user called root, add your email address to the forwards text box.
Why is it sending email? The notifications are OFF and user's email is not [email protected]
Re: Cron Is Generating Frozen Messages
that is my question, i don't know why it is sending mailkathleencjustice wrote:I exactly want to know about why it is sending email?
Re: Cron Is Generating Frozen Messages
One my experiment: when i turn notifications on, i stop receiving mail to [email protected], instead i recieve the mail to the email address associated to the account (as expected). And as soon as i turn notifications off, i stop receiving mail to the address associated to the account, but start receiving it to [email protected].
Any ideas how to figure out who and why is sending these emails when it shouldn't?
Any ideas how to figure out who and why is sending these emails when it shouldn't?
-
- Collaborator
- Posts: 783
- Joined: Mon May 11, 2015 8:43 am
- Contact:
- Os: CentOS 6x
- Web: apache + nginx
Re: Cron Is Generating Frozen Messages
If you don't want to receive emails you need to use mailto="" in crontab. VestaCP set the mailto line only when the notifications are ON.
https://github.com/serghey-rodin/vesta/ ... #L527-L529
As I said before, use > /dev/null 2>& 1 as work around.
https://github.com/serghey-rodin/vesta/ ... #L527-L529
As I said before, use > /dev/null 2>& 1 as work around.
tjebbeke wrote:Add >/dev/null 2>&1 add the end of your cron command.
eg.:Code: Select all
php -q /home/web..../....php >/dev/null 2>&1
Re: Cron Is Generating Frozen Messages
Yes, this works, thanks! Yet it is just workaround and i need to remember to do it for all my users. I wish Vesta could do mailto="" itself.