1

I have a temporary need to consolidate 2 currently separate servers onto a single machine. I am considering using VMs, but it would be far less work if I could just have 2 different server names point to the same machine.

The services themselves don't overlap, so that is not a concern. One is a file server and the other is a web server.

This is a private, behind-the-firewall scenario, on a primarily Windows network.

ErikE
  • 4,676
  • 1
  • 19
  • 25
  • Potential duplicate of http://serverfault.com/questions/517501/is-it-possible-for-two-hostnames-share-the-same-ip-address? Do you have a DNS server in this network? – Michael Bailey Aug 13 '15 at 05:04
  • @michael yes but there are some Windows-specific considerations – john Aug 13 '15 at 05:53
  • There _is_ a DNS server in the picture, but I was mainly concerned with Windows-specific services. Although on further though, it may not matter. – Scott Trotter Aug 13 '15 at 06:38

1 Answers1

3

It is possible, but it's not like you describe it. You can add a CNAME DNS record, known as an alias. This just points a second name to the original server's DNS name. So the server does not think about itself as being ServerB and ServerA, but DNS clients will find the server's IP address using either name.

You are better off using the name of the file server as the real name of the server (the name that you configure on the server itself) and using an alias for the web-server, because IIS is designed to listen on various DNS addresses. I've had issues with accessing file servers using aliases in the past (see here).

john
  • 1,995
  • 1
  • 17
  • 30
  • Another way to phrase the questions would be "is there a Windows equivalent to a DNS CNAME?" – Scott Trotter Aug 13 '15 at 06:39
  • The notion of using the real name for the file server and having the web server name as a DNS entry may be the solution. (I was going to say that I need to use RDP to access both machines, but Duh! they're the same system in this case.) – Scott Trotter Aug 13 '15 at 06:45
  • It _is_ the solution. The 'Windows equivalent to a DNS CNAME' is a DNS CNAME, especially so when the windows service concerned is IIS. Simply set your Windows server name to the one you need for file sharing, create your DNS alias, configure IIS to listen for that in its host headers (not strictly necessary but I like to be tidy) and continue on with your day. – Rob Moir Aug 13 '15 at 06:48
  • Yes I believe that this will work for my particular problem. But now I'm curious and I can foresee other situations where this might come in handy. For example, what if instead of IIS, the "other" service was Exchange or Sharepoint? – Scott Trotter Aug 13 '15 at 07:24
  • @Scott. Each application is likely to handle this differently, based on what it does and how it is configured. It would be best to check the best practices for each. – john Aug 13 '15 at 07:35
  • Disabling `Strict Name Checking` as suggested in the link is a very good idea when configuring multiple dns names for the same host. – ErikE Aug 13 '15 at 10:05