question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Error to send email to hotmail address

See original GitHub issue

Hi !

I’m currently using node-sendmail to send emails which don’t need any answer. I have tried with my personal address but I have some troubles. So, I hope you can help me 😃 (it’s not necessarily a bug, maybe I’m doing something wrong)

Expected Behavior

Normally, the email should be sent and receive in my personnal mailbox.

Current Behavior

Actually, I have the following error:

mx resolved:  [ { exchange: 'mx1.hotmail.com', priority: 5 },
  { exchange: 'mx4.hotmail.com', priority: 5 },
  { exchange: 'mx2.hotmail.com', priority: 5 },
  { exchange: 'mx3.hotmail.com', priority: 5 } ]
Error on connectMx for:  { exchange: 'mx1.hotmail.com', priority: 5 } { Error: connect ETIMEDOUT 65.55.37.88:25
    at Object.exports._errnoException (util.js:1023:11)
    at exports._exceptionWithHostPort (util.js:1046:20)
    at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1090:14)
  code: 'ETIMEDOUT',
  errno: 'ETIMEDOUT',
  syscall: 'connect',
  address: '65.55.37.88',
  port: 25 }
Error on connectMx for:  { exchange: 'mx4.hotmail.com', priority: 5 } { Error: connect ETIMEDOUT 104.44.194.235:25
    at Object.exports._errnoException (util.js:1023:11)
    at exports._exceptionWithHostPort (util.js:1046:20)
    at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1090:14)
  code: 'ETIMEDOUT',
  errno: 'ETIMEDOUT',
  syscall: 'connect',
  address: '104.44.194.235',
  port: 25 }
Error on connectMx for:  { exchange: 'mx2.hotmail.com', priority: 5 } { Error: connect ETIMEDOUT 65.55.92.152:25
    at Object.exports._errnoException (util.js:1023:11)
    at exports._exceptionWithHostPort (util.js:1046:20)
    at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1090:14)
  code: 'ETIMEDOUT',
  errno: 'ETIMEDOUT',
  syscall: 'connect',
  address: '65.55.92.152',
  port: 25 }
Error on connectMx for:  { exchange: 'mx3.hotmail.com', priority: 5 } { Error: connect ETIMEDOUT 104.44.194.237:25
    at Object.exports._errnoException (util.js:1023:11)
    at exports._exceptionWithHostPort (util.js:1046:20)
    at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1090:14)
  code: 'ETIMEDOUT',
  errno: 'ETIMEDOUT',
  syscall: 'connect',
  address: '104.44.194.237',
  port: 25 }
error on connectMx Error: can not connect to any SMTP server
    at tryConnect (E:\Cours année 2015 - 2017\Mémoire\mookup\node_modules\sendmail\sendmail.js:86:49)
    at Socket.<anonymous> (E:\Cours année 2015 - 2017\Mémoire\mookup\node_modules\sendmail\sendmail.js:92:13)
    at emitOne (events.js:96:13)
    at Socket.emit (events.js:189:7)
    at emitErrorNT (net.js:1280:8)
    at _combinedTickCallback (internal/process/next_tick.js:74:11)
    at process._tickCallback (internal/process/next_tick.js:98:9)
Error: can not connect to any SMTP server
    at tryConnect (E:\Cours année 2015 - 2017\Mémoire\mookup\node_modules\sendmail\sendmail.js:86:49)
    at Socket.<anonymous> (E:\Cours année 2015 - 2017\Mémoire\mookup\node_modules\sendmail\sendmail.js:92:13)
    at emitOne (events.js:96:13)
    at Socket.emit (events.js:189:7)
    at emitErrorNT (net.js:1280:8)
    at _combinedTickCallback (internal/process/next_tick.js:74:11)
    at process._tickCallback (internal/process/next_tick.js:98:9)

Steps to Reproduce (for bugs)

  1. I use this piece of code
const sendmail = require("sendmail")();

exports.sendEmail = function(destinataire){
    return new Promise(function(resolve, reject){
        sendmail({
            from: 'no-reply@alexandrie.com',
            to: destinataire,
            subject: 'validation de votre inscription',
            html: 'Mail of test sendmail ',
        }, function(err, reply) {
            if(err){
                console.log(err);
                reject(err);
            }
            resolve(reply);
        })
    })
};
  1. destinataire is an email address. In my case, this is my personal address with the following form xxx@hotmail.com

Context

I’m trying to send an email to check the validity of an inscription on my website. Now, I’m just trying to send email and receive it. Later, I will provide a special link in the email to validate the inscription.

Your Environment

  • Version used: node-sendmail 1.1.1
  • Environment name and version (e.g. Chrome 39, node.js 5.4): Chrome Version 56.0.2924.87; Node.JS 7.5.0
  • Operating System and version (desktop or mobile): Windows 7 integral edition (64 bits)

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:7 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
ghostcommented, Feb 13, 2017

I think I have found the problem (thanks to @Geex-Renzo ). I don’t use sendmail (I was thinking it was no needed because node-sendmail don’t use smtp server).

Before closing this ticket, can you explain why Sendmail (or postix) is needed ? Thank you very for your help 😃

1reaction
sankulkacommented, Feb 13, 2017

I am too facing this issue. It sends mail to corporate address but not to personal Gmail account. Any quick resolution would be highly appreciated.

Read more comments on GitHub >

github_iconTop Results From Across the Web

I can't send email from my hotmail account : Error
Hello, when i send mail from my hotmail account , i always get this message " Delivery has failed to these recipients or...
Read more >
Unable to send email to some domains, such as Hotmail ...
The most common reason for mail not being accepted by servers such as Hotmail, Yahoo, Gmail, AOL, etc. is due to a temporary...
Read more >
Error While Sending Emails from Hotmail SMTP - Stack Overflow
It looks like the email address you were trying to use, is not allowed to send an email under the name Sansal@SansalPC.mshome.net, ...
Read more >
Hotmail Not Working? Here's Why & The Fix! - UpPhone
Hotmail Not Working On Mail for iPhone · Open Settings. · Navigate to Passwords & Accounts. · Find your Hotmail account. · Tap...
Read more >
Hotmail Not Working 2023? Fixes and Explanation Here
Open Outlook application. Go to File> Account Settings and then click on Account Settings. outlook account settings · Check out email accounts ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found