Binding to multiple IPs
Posted on February 9, 2009
Filed Under MDaemon | 2 Comments
Say you want to bind to multiple IPs assigned to your server, but not all IPs, and aren’t quite sure how? As it turns out, this is easy.
In the Default Domain GUI you have your “Domain IP” to which you can then “Restrict connections to this IP”, which will bind MDaemon to a single IP address.
You can’t add multiple DomainIP lines to the INI file, but there is a trick you can use, we rely on the fact that each secondary domain can be bound to it’s own IP address, but those IPs will service requests for all domains as long as the user logs in using their full email address.
To bind 10.0.0.1 and 10.0.0.2 to MDaemon but not 10.0.03, bind 10.0.0.1 to your primary domain, then bind 10.0.0.2 to a secondary domain called mail-2.example.com (where example.com is your real domain, and mail-2.example.com is the DNS record assigned to 10.0.0.2), rinse and repeat for each additional domain.
Hope this helps.
Comments
2 Responses to “Binding to multiple IPs”
Leave a Reply
Hi guys. Im trying to configure two domains on mdaemon, but i need to send from diferent ips. Is this posible ?? Thanks
matias,
Why? There is no technical need to keep outbound sending from separate IPs.
Anyway, if you enable outbound socket binding, it should be possible.