Bind IP to qmail

How do I bind an IP address to qmail?

I have multiple IP addresses on my machine and I want set eth0:1 as the mail server address. My DNS is pointing to the correct IP but qmail is picking the address on eth0 to send from which obviously is failing in some spam filters.

Any help would be greatly appreciated.


I found your old thread searching google for a way to bind IP to sendmail.

Looks like interworx already has qmail patched (thankfully) and you can do it. Follow the instructions in the second post of this thread:

Reboot SMTP server after creating the file and it works beautifully.

Hi deheleri

Many thanks

Yes, the patch was added many years ago and you can bind ip to any IPv4 address, even have different domains bind to different ip addresses

Many thanks


May I ask a question? Why do you want to do this, I mean multiply the IP?

Hi zandry

Good question

The answer is many reasons from separating email to hosting ip, to using email on another server etc… it?s also handy if your email server ip gets blacklisted

Many thanks