Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

Is this possible? If I have only one ip address then changing the MX record shouldn't matter as it's the same as the www. But my email is on a different machine altogether.

share|improve this question

3 Answers 3

up vote 10 down vote accepted

Do you have a single server sitting directly on the Internet with its public IP address, or do you have a private network with a router connecting it to the outside?

If you only have one public server, then there's nothing you can do: only one server can be using a given public IP at the same time.

If you have a LAN behind a router, then this router handles the public IP address for you and usually (99% of the times) can be configured to forward specific connetions to internal servers; in this case, you'd need to configure it to forward TCP port 80 (HTTP) to your web server's internal IP address and TCP port 25 (SMTP) to your mail server's one.

Of course, if you are in the first scenario, you can always move to the second one by putting a router between your server(s) and the rest of the world.

share|improve this answer

You would need to forward port 80 to your web server, and port 25 to your mail server on your router.

share|improve this answer

I believe you can also forward requests to port 25 on your web server to mail server. The reverse can be done, too (mail server forwards port 80 requests to web server).

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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