Webmaster Newbie Question

I have a low end vps (128MB RAM)running on Debian.I used a bash script by ilevkov to setup the site. After some trial and error, I managed to set up a WordPress on it. Just now I found out that my VPS can't send any email. I tested using the WordPress reset password email, and it shows

The e-mail could not be sent. Possible reason: your host may have disabled the mail() function...

After some Google session I noticed that I can send email from ssh. So I tried

mail [email protected]
Subject: Halo dion
some message

and the result said

/usr/lib/sendmail: No such file or directory
"/root/dead.letter" 9/243
. . . message not sent.

The question

How can I fix my VPS mail setting?

  • Who is your host and do you have root access?
    – ionFish
    Commented Nov 2, 2012 at 13:54
  • I host my VPS in a local Indonesian hosting provider. I do have root access.
    – ifdion
    Commented Nov 2, 2012 at 22:19

4 Answers 4


I’ve checked it again, should work out of the box.

In case it doesn’t:

There is also a new version of lowendscript made by Xeoncross - https://github.com/Xeoncross/lowendscript

  • Thank you very much @ILevkov . You are right, there is no problem at all with your script. The problem was actually the pre configured exim4 setup.
    – ifdion
    Commented Nov 3, 2012 at 16:11

From the script's readme file:

"Remove excess packages (apache2, sendmail, bind9, samba, nscd, etc) and install the basic components needed for a light-weight HTTP(S) web server..."

So this is your problem. You need to install those packages again, especially sendmail.

  • Isn't exim4 is a replacement for sendmail?
    – ifdion
    Commented Nov 2, 2012 at 22:19

You'll probably need to configure a mail server which is more complicated than using a bash script. You can do that following these instructions http://www.youtube.com/watch?v=dKO4MfOpDVs or setup a plugin in WordPress http://wordpress.org/extend/plugins/wp-mail-smtp/ which you can then configure with an SMTP server. This is the better option in my opinion because if your mail server isn't configured properly your emails from the server will be flagged as spam. So if you have gmail or another email account (zoho.com) provides free email accounts with your domain. Setup the WordPress plugin and use an SMTP server. Then you'll be good to go

  • Will give it a try. How about the limitation? Is there a maximum number of email sent daily? Actually almost all of my websites uses Google Apps for their email. If I use another SMTP server (e.g Google Apps), will it reduce my server load (on action that send an email or 2)? If so, than it will be a good news for me :D.
    – ifdion
    Commented Nov 4, 2012 at 2:35
  • You'll have to contact Zoho about any mail sending limits. Though if you're not spamming you should be ok.
    – Anagio
    Commented Nov 4, 2012 at 4:41

I figured it out. The problem is not in the bash script by @ILevkov, but on the exim4 pre configuration. Since exim4 is already installed, it isn't being re configured by the script. At least that's what I thought . Please correct me I'm wrong

All I have to do is to remove the previos exim4

apt-get purge exim4

And then reinstall using @Ilevkov well written bash script

bash setup-debian.sh exim4

Thank you all for your time.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.