My meteor app is running behind a firewall and my smtp settings for gmail are not getting through:
e.g. process.env.MAIL_URL = "smtp://user#gmail.com:password#smtp.googlemail.com:465"
I get 'Exception while invoking method 'sendEmail' Error: connect EHOSTUNREACH'
I gather I need to set SSL but don't know where/how to do this.
Any ideas?
many thanks
Max
You're doing it correctly but the user:password part can't have an '#' symbol in it or the system gets confused.
This should do what you want:
process.env.MAIL_URL = "smtp://user%40gmail.com:password#smtp.googlemail.com:465"
Thanks -
FWIW, I wanted to use meteor to access a local mail server on my linux box. (My VPN won't let me access mailgun or any other remote mail server.)
This turned out to be pretty simple: process.env.MAIL_URL = "smtp://localhost:25"
Note, this is on a local mail server without authentication.
take care
Max
Related
I have set up SMTP server with gmail account. It was working fine till few days back. When I checked the logs I found below entry in it:
SMTP Error: 454 4.7.0 Too many login attempts, please try again later.
I have restarted SMTP service twice. I have checked the configuration that was set up using this link. Everything is same as we have set up. I have restarted the SMTP server & the machine too.
I have checked for 2 step verification settings. It is not enabled. I have checked for "less secure" apps settings and it is set to Enabled as suggested here.
I have checked apps enabled as suggested here using below link.
https://security.google.com/settings/security/permissions?pli=1
But no apps are added. Can anyone suggest anything that I need to look for? Thanks in advance.
It is because you are attempting to create a new smtp connection for each email. You need to use SMTP pool.
Please see:
DELIVERING BULK MAIL
POOLED SMTP
Pooled smtp is mostly useful when you have a large number of messages that you want to send in batches or your provider allows you to only use a small amount of parallel connections.
If you are using Node-mailer:
const transporter = nodemailer.createTransport({
host: 'smtp.gmail.com',
port: 465,
secure: true,
pool: true, // This is the field you need to add
auth: {
user: 'test#test.com',
pass: 'your_password'
}});
Then, you need to close the pool once you send all the emails.
transporter.close();
I had the same issue. When I checked the Mail queue there were many unprocessed mails in the queue.
So I deleted the bulk mails and restarted the instance. Once the Mail Queue is cleared then it started to send mails as usual.
Hope this will be useful for anybody to have the above issue.
The Issue resolved with the TCP port changing to 587 from 25 in Outbound Connections settings in SMTP Server.
please follow the instructions below:
Open Gmail from a browser and only sign into the account you're
trying to add. Be sure to be signed out of all your other accounts
Go to this link: https://accounts.google.com/b/0/displayunlockcaptcha and click
Continue or confirm.
Now Test your program it will work fine
The Issue resolved change the password mail server password
It may be because the mail's size is greater than the allowed size (25MB).
Can anybody suggest me a way to receive mail from commandline and save it to a file. i have tried some tool but those were of no use. i tried getmail and popclient. but every time i get an error. may be my syntax is wrong.
in getmail i tried this command
getmail -u myemail#gmail.com -pw password -s imap.gmail.com -port 110
and got error of winsock.dll
i have also tried it with port 993 and in this case it gave error of possible time out
and in popclient i also used this type of settings in config.xml but i got the same error of server not responding.can anybody figure out what's the problem?
The port number is wrong for gmail, and you need to use the POP access feature of gmail and the POP email server to connect to (not via imap).
Gmail uses a secure port and also SSL security. Enable the POP retrieval/access in Gmail configuration and read the Gmail help on how to access via POP (for any client) - it will list the port number and server name and security encryption.
I've got Jenkins ver 1.524 installed on a Windows 7 box and I'm trying to configure email but the "Test configuration" is reporting errors. Jenkins is running as a service under my own domain account.
My settings are as follows:
SMTP server: smtp.corpdomain.com
Default user email suffix: #corpdomain.com
Not using authentication
Not using SSL
SMTP port: 25
Reply-To Address: tools#corpdomain.com
Charset: UTF-8
When I test the configuration, I usually get the following exception:
javax.mail.MessagingException: Could not connect to SMTP host: smtp.amazon.com, port: 25;
nested exception is:
java.net.ConnectException: Connection timed out: connect
Yet every once in a while I receive the following instead:
com.sun.mail.smtp.SMTPSendFailedException: 553 5.1.8 <nobody#nowhere>... Domain of sender address nobody#nowhere does not exist
;
nested exception is:
com.sun.mail.smtp.SMTPSenderFailedException: 553 5.1.8 <nobody#nowhere>... Domain of sender address nobody#nowhere does not exist
However, I am able to send mail from the command line without errors via both python script and java (using javax.mail) without authentication, and I'm able to telnet to the SMTP server on port 25, so I don't see how it could be a firewall issue.
One other note that may be related: When I try to install a plug-in via the Jenkins web interface, I receive a 403 response for the URL "http://updates.jenkins-ci.org/update-center.json?uctest". However, I'm able to connect to that URL from a browser on the same machine.
Could this be a Tomcat configuration issue? I'm not familiar with Tomcat so I'm not sure where to even start looking. Maybe a Jenkins configuration that I've missed? Any other ideas?
Thanks in advance!
FWIW The nobody#nowhere address is the default address Jenkins comes with for the system admin email address (which is used as the from address when sending emails)
you can change it at
Manage Jenkins > Configure System > Jenkins Location
first, use port 465
second, get your email verified in AWS SES, and change your default sending email from here:
Jenkins -> Configure System -> Jenkins Location -> System Admin e-mail address
Still looks to me like your firewall is blocking Jenkins' service from accessing those ports -
especially as the connection times-out, which is typical for such cases.
Suggest you try to disable the firewall completely and see if there is any change.
Cheers
To check for conectivity problems from Jenkins, I would go to the Script Console at Manage Jenkins -> Script Console, and there, try to connect to the port you want to test (25 in your case), with a Groovy script like:
s = new Socket()
s.setSoTimeout(200)
s.connect(new InetSocketAddress("smtp.corpdomain.com", 25), 200)
s.close()
If you don't receive any kind of IOError, then there is no problem with the conectivity.
Note: I could have used simply new Socket("smtp.corpdomain.com", 25) but it will try forever to connect if the Firewall ignores your attempts.
For the SMTPSendFailedException you eventually receive, as #paul-henry mention:
The nobody#nowhere address is the default address Jenkins comes with for the system admin email address (which is used as the from address when sending emails)
you can change it at
Manage Jenkins > Configure System > Jenkins Location
Resources:
Networking with Groovy
Add a timeout when creating a new Socket
Thanks for submitting an edit. It is only visible to you until it’s been approved by trusted community members
first, use port 465 second, get your email verified in AWS SES, and change your default sending email from here: Jenkins -> Configure System -> Jenkins Location -> System Admin e-mail address
Thanks. It helps me!
My problem was "550-Verification failed for "
I got this project "skpsmtpmessage" and I tried to send mail first. So I changed all the mail id to gmail id. But replay host is problem. I tried smtp.gmail.com, smtp.google.com, smtp.googletalk.com. But when I run my program, I get error that "Unable to connect server"
Which relay host should I use for gmail.
The correct SMTP server for Gmail is smtp.gmail.com, but I don't know how to help you further, the question is pretty vague.
You can also take a look at the configuration instructions for using Gmail on the iPhone to see if you're making a mistake with another parameter.
I want to create a mail server, but my ISP does not allow reverse-IP record, so I ordered a VPS with such function. But I want use VPS only as a relaying server and my own server as an actual mail server (so it should have things like web-mail, and some other). I did not find any guides, but looks like VPS will be called a "smart-host". So I installed Axigen on my server, but it requires login and password for connecting to a smart-host. I tried to use postfix for relaying but I did non figure out how to properly configure it. What are my options?
Thank you!
To securely enable postfix as a mail forwarding server, you'll have to enable and configure SASL authentication. The postfix SASL README has all the details. I suggest dovecot as the backend, as it's the simplest to setup. After that, just create a new system user (adduser mail-forwarding) and configure Axigen to use that user for forwarding.
If I understand correctly, your goal is to forward outgoing mail from your local server to the VPS while incoming mail should be stored on the local server. This is possible, but not necessarily simple. Mail needs to be handled differently depending on how it reaches your local server, otherwise you might end up with a mail loop, with your servers playing pingping using mail sent back and forth.