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.

A little confusing question, but here's what I'm trying to do.

I have port forwarding setup so that we can use 1 static IP to RDP into different machines behind our firewall.

For instance

My Dev Machine 173.165.1.188:3660 -> 192.168.0.1:3389

One of our internal servers: 173.165.1.188:3661 -> 192.168.0.2:3389

What I was hoping to be able to do is to setup a dns entry that would handle the mapping for us so instead of:

173.165.1.188:3660 to get to my pc I could go to mypc.mydomain.com

Is this possible?

Disclamer: Real IP's not used here to protect the innocent.

UPDATE

If it wont work using port forwarding, is there some other option I can use? Can I setup local dns entries that take mypc.mydomain.com and map it to an internal ip?

share|improve this question

2 Answers 2

up vote 5 down vote accepted

No, this won't work - DNS entries only relate to whole IP addresses, not IP:port combinations.

The only practical way to make this work using hostnames alone is to get more IP addresses from your ISP.

share|improve this answer

It is absolutely possible. DNS only points to a particular IP address - naturally it does not care if the IP address is behind a firewall. DNS will work if the IP is assigned to a server that crashed, or even if the IP was not assigned.

Couple more points

  • I could imagine a fancy DNS server setup that checks the connectivity before giving you an answer but that's rear
  • No ports in DNS (as Alnitak mentioned)
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.