Happens when trying to send an email invite when an emailer plugin isn't activated.
Either (or both):
NodeBB is trying to use the default sendmail handler, but we can't detect whether sendmail itself is installed (... as far as I know...).
Same kind of thing happens when you use mail() in PHP, except it swallows the error, because PHP :smile:
Yeah I'm cool with this going to admin user, but this is a potential message shown to end-user
@julianlam I'm getting the same error as an administrator on a hosted instance.
Does hosted instances use sendmail, or do I need to install an email plugin?
@AmrEldib Can you try again? I've updated the sendmail executable in your instance.
Still have this problem ("Spawn sendmail ENOENT") with 1.0.3. It worked until recently. How can I provide further information?
Ensure that the running user can access the sendmail executable. ENOENT suggests the executable was not found
Ensure that the running user can access the sendmail executable. ENOENT suggests the executable was not found
Access was available. After a restart of NodeBB, it now works again… Any hints what I can do when it stops working again?
Please reopen, this still happens with NodeBB 1.2.1, see #5181
Happens again with NodeBB 1.6.0. No emails sent, logs:
21/9 11:33:28 [1338] - error: Error: spawn sendmail ENOENT
at exports._errnoException (util.js:1024:11)
at Process.ChildProcess._handle.onexit (internal/child_process.js:192:19)
at onErrorNT (internal/child_process.js:374:16)
at _combinedTickCallback (internal/process/next_tick.js:138:11)
at process._tickCallback (internal/process/next_tick.js:180:9)
So you have sendmail installed? What emailer plugin are you using?
So you have sendmail installed? What emailer plugin are you using?
Didn't install a special plugin, because I want sendmail to be used.
I did a ./nodebb upgrade and restarted NodeBB and now it works again, but let's see for how long.
There was also an OS minor update (FreeBSD 11.0 → 11.1) some days ago, but userland shouldn't be affected and all other services etc. didn't need recompiling or something like that. Maybe that's completely unrelated.
I had the same issue
First of all you must install sendmail package on your machine
then if you type sudo which sendmail it gives you /usr/sbin/sendmail
It means that if you are not a root user you could not access sendmail and so your nodebb instance.
So you must add the given path to your user's $PATH variable.
You can append export PATH=$PATH:/usr/sbin to the end of ~/.profile file and then close your terminal and reopen another one to reload your environment variables.