Sending email to gmail from cron
Looking for help sending email to a gmail address from my cron. At the top of crontab
MAILTO="obfuscated@gmail.com"
But no mail comes. Checking /var/log/maillog, I see
Dec 17 22:46:36 myserver postfix/pickup[30426]: CC21261C6E: uid=501 from=<root>
Dec 17 22:46:36 myserver postfix/cleanup[30486]: CC21261C6E: message-id=<20181217224636.CC21261C6E@myserver.novalocal>
Dec 17 22:46:36 myserver postfix/qmgr[11071]: CC21261C6E: from=<root@myserver.novalocal>, size=5920, nrcpt=1 (queue active)
Dec 17 22:46:37 myserver postfix/smtp[30488]: connect to gmail-smtp-in.l.google.com[2607:f8b0:400e:c03::1b]:25: Network is unreachable
Dec 17 22:46:37 myserver postfix/smtp[30488]: CC21261C6E: enabling PIX workarounds: disable_esmtp delay_dotcrlf for gmail-smtp-in.l.google.com[74.125.197.26]:25
Dec 17 22:46:37 myserver postfix/smtp[30488]: CC21261C6E: to=<obfuscated@gmail.com>, relay=gmail-smtp-in.l.google.com[74.125.197.26]:25, delay=221, delays=220/0.02/0.34/0.39, dsn=2.0.0, status=sent (250 2.0.0 OK 1545086797 31si11773098plk.310 - gsmtp)
Dec 17 22:46:37 myserver postfix/qmgr[11071]: CC21261C6E: removed
So, clearly, the IPv6 version is blocked, but the fallback gets a success message, yet no mail ever arrives. Same messages if I try using the command-line mail command. However, I can use the command-line mail program to successfully send mail to my company email address.
mail -s "test1" obfuscated@mycompany.com
test1
EOT
The telnet trick seems to indicate I can access the gmail server:
$ telnet gmail-smtp-in.l.google.com 25
Trying 108.177.98.26...
Connected to gmail-smtp-in.l.google.com.
Escape character is '^]'.
220 *************************************************
^]
telnet> quit
Connection closed.
My IP tables look like this
Chain INPUT (policy ACCEPT)
target prot opt source destination
ACCEPT all -- anywhere anywhere state RELATED,ESTABLISHED
ACCEPT icmp -- anywhere anywhere
ACCEPT all -- anywhere anywhere
ACCEPT tcp -- anywhere anywhere state NEW tcp dpt:ssh
ACCEPT tcp -- anywhere anywhere state NEW tcp dpt:http
REJECT all -- anywhere anywhere reject-with icmp-host-prohibited
Chain FORWARD (policy ACCEPT)
target prot opt source destination
REJECT all -- anywhere anywhere reject-with icmp-host-prohibited
Chain OUTPUT (policy ACCEPT)
target prot opt source destination
Any help on this will be greatly appreciated.
email gmail cron
add a comment |
Looking for help sending email to a gmail address from my cron. At the top of crontab
MAILTO="obfuscated@gmail.com"
But no mail comes. Checking /var/log/maillog, I see
Dec 17 22:46:36 myserver postfix/pickup[30426]: CC21261C6E: uid=501 from=<root>
Dec 17 22:46:36 myserver postfix/cleanup[30486]: CC21261C6E: message-id=<20181217224636.CC21261C6E@myserver.novalocal>
Dec 17 22:46:36 myserver postfix/qmgr[11071]: CC21261C6E: from=<root@myserver.novalocal>, size=5920, nrcpt=1 (queue active)
Dec 17 22:46:37 myserver postfix/smtp[30488]: connect to gmail-smtp-in.l.google.com[2607:f8b0:400e:c03::1b]:25: Network is unreachable
Dec 17 22:46:37 myserver postfix/smtp[30488]: CC21261C6E: enabling PIX workarounds: disable_esmtp delay_dotcrlf for gmail-smtp-in.l.google.com[74.125.197.26]:25
Dec 17 22:46:37 myserver postfix/smtp[30488]: CC21261C6E: to=<obfuscated@gmail.com>, relay=gmail-smtp-in.l.google.com[74.125.197.26]:25, delay=221, delays=220/0.02/0.34/0.39, dsn=2.0.0, status=sent (250 2.0.0 OK 1545086797 31si11773098plk.310 - gsmtp)
Dec 17 22:46:37 myserver postfix/qmgr[11071]: CC21261C6E: removed
So, clearly, the IPv6 version is blocked, but the fallback gets a success message, yet no mail ever arrives. Same messages if I try using the command-line mail command. However, I can use the command-line mail program to successfully send mail to my company email address.
mail -s "test1" obfuscated@mycompany.com
test1
EOT
The telnet trick seems to indicate I can access the gmail server:
$ telnet gmail-smtp-in.l.google.com 25
Trying 108.177.98.26...
Connected to gmail-smtp-in.l.google.com.
Escape character is '^]'.
220 *************************************************
^]
telnet> quit
Connection closed.
My IP tables look like this
Chain INPUT (policy ACCEPT)
target prot opt source destination
ACCEPT all -- anywhere anywhere state RELATED,ESTABLISHED
ACCEPT icmp -- anywhere anywhere
ACCEPT all -- anywhere anywhere
ACCEPT tcp -- anywhere anywhere state NEW tcp dpt:ssh
ACCEPT tcp -- anywhere anywhere state NEW tcp dpt:http
REJECT all -- anywhere anywhere reject-with icmp-host-prohibited
Chain FORWARD (policy ACCEPT)
target prot opt source destination
REJECT all -- anywhere anywhere reject-with icmp-host-prohibited
Chain OUTPUT (policy ACCEPT)
target prot opt source destination
Any help on this will be greatly appreciated.
email gmail cron
1
gmail dropping it due to spam, etc? can gmail connect back to you to send an "undeliverable" message? Can you send yourself gmail the same way usingmail
that works for your work email account?
– ivanivan
Dec 18 '18 at 23:31
Complain to gmail as recipient.
– AnFi
Dec 18 '18 at 23:49
add a comment |
Looking for help sending email to a gmail address from my cron. At the top of crontab
MAILTO="obfuscated@gmail.com"
But no mail comes. Checking /var/log/maillog, I see
Dec 17 22:46:36 myserver postfix/pickup[30426]: CC21261C6E: uid=501 from=<root>
Dec 17 22:46:36 myserver postfix/cleanup[30486]: CC21261C6E: message-id=<20181217224636.CC21261C6E@myserver.novalocal>
Dec 17 22:46:36 myserver postfix/qmgr[11071]: CC21261C6E: from=<root@myserver.novalocal>, size=5920, nrcpt=1 (queue active)
Dec 17 22:46:37 myserver postfix/smtp[30488]: connect to gmail-smtp-in.l.google.com[2607:f8b0:400e:c03::1b]:25: Network is unreachable
Dec 17 22:46:37 myserver postfix/smtp[30488]: CC21261C6E: enabling PIX workarounds: disable_esmtp delay_dotcrlf for gmail-smtp-in.l.google.com[74.125.197.26]:25
Dec 17 22:46:37 myserver postfix/smtp[30488]: CC21261C6E: to=<obfuscated@gmail.com>, relay=gmail-smtp-in.l.google.com[74.125.197.26]:25, delay=221, delays=220/0.02/0.34/0.39, dsn=2.0.0, status=sent (250 2.0.0 OK 1545086797 31si11773098plk.310 - gsmtp)
Dec 17 22:46:37 myserver postfix/qmgr[11071]: CC21261C6E: removed
So, clearly, the IPv6 version is blocked, but the fallback gets a success message, yet no mail ever arrives. Same messages if I try using the command-line mail command. However, I can use the command-line mail program to successfully send mail to my company email address.
mail -s "test1" obfuscated@mycompany.com
test1
EOT
The telnet trick seems to indicate I can access the gmail server:
$ telnet gmail-smtp-in.l.google.com 25
Trying 108.177.98.26...
Connected to gmail-smtp-in.l.google.com.
Escape character is '^]'.
220 *************************************************
^]
telnet> quit
Connection closed.
My IP tables look like this
Chain INPUT (policy ACCEPT)
target prot opt source destination
ACCEPT all -- anywhere anywhere state RELATED,ESTABLISHED
ACCEPT icmp -- anywhere anywhere
ACCEPT all -- anywhere anywhere
ACCEPT tcp -- anywhere anywhere state NEW tcp dpt:ssh
ACCEPT tcp -- anywhere anywhere state NEW tcp dpt:http
REJECT all -- anywhere anywhere reject-with icmp-host-prohibited
Chain FORWARD (policy ACCEPT)
target prot opt source destination
REJECT all -- anywhere anywhere reject-with icmp-host-prohibited
Chain OUTPUT (policy ACCEPT)
target prot opt source destination
Any help on this will be greatly appreciated.
email gmail cron
Looking for help sending email to a gmail address from my cron. At the top of crontab
MAILTO="obfuscated@gmail.com"
But no mail comes. Checking /var/log/maillog, I see
Dec 17 22:46:36 myserver postfix/pickup[30426]: CC21261C6E: uid=501 from=<root>
Dec 17 22:46:36 myserver postfix/cleanup[30486]: CC21261C6E: message-id=<20181217224636.CC21261C6E@myserver.novalocal>
Dec 17 22:46:36 myserver postfix/qmgr[11071]: CC21261C6E: from=<root@myserver.novalocal>, size=5920, nrcpt=1 (queue active)
Dec 17 22:46:37 myserver postfix/smtp[30488]: connect to gmail-smtp-in.l.google.com[2607:f8b0:400e:c03::1b]:25: Network is unreachable
Dec 17 22:46:37 myserver postfix/smtp[30488]: CC21261C6E: enabling PIX workarounds: disable_esmtp delay_dotcrlf for gmail-smtp-in.l.google.com[74.125.197.26]:25
Dec 17 22:46:37 myserver postfix/smtp[30488]: CC21261C6E: to=<obfuscated@gmail.com>, relay=gmail-smtp-in.l.google.com[74.125.197.26]:25, delay=221, delays=220/0.02/0.34/0.39, dsn=2.0.0, status=sent (250 2.0.0 OK 1545086797 31si11773098plk.310 - gsmtp)
Dec 17 22:46:37 myserver postfix/qmgr[11071]: CC21261C6E: removed
So, clearly, the IPv6 version is blocked, but the fallback gets a success message, yet no mail ever arrives. Same messages if I try using the command-line mail command. However, I can use the command-line mail program to successfully send mail to my company email address.
mail -s "test1" obfuscated@mycompany.com
test1
EOT
The telnet trick seems to indicate I can access the gmail server:
$ telnet gmail-smtp-in.l.google.com 25
Trying 108.177.98.26...
Connected to gmail-smtp-in.l.google.com.
Escape character is '^]'.
220 *************************************************
^]
telnet> quit
Connection closed.
My IP tables look like this
Chain INPUT (policy ACCEPT)
target prot opt source destination
ACCEPT all -- anywhere anywhere state RELATED,ESTABLISHED
ACCEPT icmp -- anywhere anywhere
ACCEPT all -- anywhere anywhere
ACCEPT tcp -- anywhere anywhere state NEW tcp dpt:ssh
ACCEPT tcp -- anywhere anywhere state NEW tcp dpt:http
REJECT all -- anywhere anywhere reject-with icmp-host-prohibited
Chain FORWARD (policy ACCEPT)
target prot opt source destination
REJECT all -- anywhere anywhere reject-with icmp-host-prohibited
Chain OUTPUT (policy ACCEPT)
target prot opt source destination
Any help on this will be greatly appreciated.
email gmail cron
email gmail cron
asked Dec 18 '18 at 23:24
rcrewsrcrews
263
263
1
gmail dropping it due to spam, etc? can gmail connect back to you to send an "undeliverable" message? Can you send yourself gmail the same way usingmail
that works for your work email account?
– ivanivan
Dec 18 '18 at 23:31
Complain to gmail as recipient.
– AnFi
Dec 18 '18 at 23:49
add a comment |
1
gmail dropping it due to spam, etc? can gmail connect back to you to send an "undeliverable" message? Can you send yourself gmail the same way usingmail
that works for your work email account?
– ivanivan
Dec 18 '18 at 23:31
Complain to gmail as recipient.
– AnFi
Dec 18 '18 at 23:49
1
1
gmail dropping it due to spam, etc? can gmail connect back to you to send an "undeliverable" message? Can you send yourself gmail the same way using
mail
that works for your work email account?– ivanivan
Dec 18 '18 at 23:31
gmail dropping it due to spam, etc? can gmail connect back to you to send an "undeliverable" message? Can you send yourself gmail the same way using
mail
that works for your work email account?– ivanivan
Dec 18 '18 at 23:31
Complain to gmail as recipient.
– AnFi
Dec 18 '18 at 23:49
Complain to gmail as recipient.
– AnFi
Dec 18 '18 at 23:49
add a comment |
1 Answer
1
active
oldest
votes
Thank you @ivanivan. Gmail was organizing all my cron output into the Spam folder, which is not displayed in the Gmail interface by default. (This seems like the right thing to be doing since the sender "root@myserver.novalocal" is pretty sketchy.) Once I displayed the Spam folder and looked inside, I saw all the cron output. (Look at me telnet'ing into mail servers and reviewing iptables.) Doh! ... Thank you again ever so much.
add a comment |
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "3"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f1385733%2fsending-email-to-gmail-from-cron%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
Thank you @ivanivan. Gmail was organizing all my cron output into the Spam folder, which is not displayed in the Gmail interface by default. (This seems like the right thing to be doing since the sender "root@myserver.novalocal" is pretty sketchy.) Once I displayed the Spam folder and looked inside, I saw all the cron output. (Look at me telnet'ing into mail servers and reviewing iptables.) Doh! ... Thank you again ever so much.
add a comment |
Thank you @ivanivan. Gmail was organizing all my cron output into the Spam folder, which is not displayed in the Gmail interface by default. (This seems like the right thing to be doing since the sender "root@myserver.novalocal" is pretty sketchy.) Once I displayed the Spam folder and looked inside, I saw all the cron output. (Look at me telnet'ing into mail servers and reviewing iptables.) Doh! ... Thank you again ever so much.
add a comment |
Thank you @ivanivan. Gmail was organizing all my cron output into the Spam folder, which is not displayed in the Gmail interface by default. (This seems like the right thing to be doing since the sender "root@myserver.novalocal" is pretty sketchy.) Once I displayed the Spam folder and looked inside, I saw all the cron output. (Look at me telnet'ing into mail servers and reviewing iptables.) Doh! ... Thank you again ever so much.
Thank you @ivanivan. Gmail was organizing all my cron output into the Spam folder, which is not displayed in the Gmail interface by default. (This seems like the right thing to be doing since the sender "root@myserver.novalocal" is pretty sketchy.) Once I displayed the Spam folder and looked inside, I saw all the cron output. (Look at me telnet'ing into mail servers and reviewing iptables.) Doh! ... Thank you again ever so much.
answered Dec 19 '18 at 0:57
rcrewsrcrews
263
263
add a comment |
add a comment |
Thanks for contributing an answer to Super User!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f1385733%2fsending-email-to-gmail-from-cron%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
1
gmail dropping it due to spam, etc? can gmail connect back to you to send an "undeliverable" message? Can you send yourself gmail the same way using
mail
that works for your work email account?– ivanivan
Dec 18 '18 at 23:31
Complain to gmail as recipient.
– AnFi
Dec 18 '18 at 23:49