SQL Server with Mr. Denny

Nov 28 2011   2:00PM GMT

Using CNAMEs with clustered file share resources

Denny Cherry Denny Cherry Profile: Denny Cherry


One of the questions that I see on the forums every once in a while is how to get a CNAME working with a network share.  For example if you have a cluster where the server names are “SERVER1 and SERVER2” and the virtual name is “VIRT1” how can I allow users to connect to the network shares by using the server name “FILESERVER” so that they don’t need to change their mapped drives, etc. after the server FILESERVER has been migrated to the cluster.

The old way of doing this would have been to simple add a CNAME to the internal DNS server so that the name FILESERVER simply pointed to the name VIRT1.  However in Windows 2008 and higher this doesn’t work any more without doing some registry hacking.  While the registry hacking will work, this is a pain to maintain as every time you migrate another server to the cluster you need to go and edit the registry key on all the nodes of the cluster, then reboot all the nodes of the cluster.  Not exactly the easiest solution to implement.

Fortunately there is a much easier technique which can be used.  Simply add another network name to the cluster pointing to the network IP address of the virtual world.  This will add another DNS entry so that your users can resolve the network name correctly and register the network name with the cluster so that it knows to accept this network name as a valid name for the cluster without needing to restart the nodes of the cluster or to edit the registry on all the nodes of the cluster.

To do this open the failover cluster manger and right click on the service or application and select “Add a Resource” from the context menu.  Then select “1 – Client Access Point”.  The wizard that opens will allow you to add a network name to the cluster resource group.


4  Comments on this Post

There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when other members comment.
  • sergioza

    Do you happen to know if CNAME ashould work in SQL server 2014? we try to do openrowset and bulkinsert from CNAMEd share which worked ok in SQL 2008 but now faisl with File Acces denied in 2014.
    Many Thanx
    20 pointsBadges:
  • Denny Cherry
    For connecting to SQL a CNAME should work just fine.  If you are trying to access a network share based on the CNAME name that won't work by default on newer versions of Windows.
    69,125 pointsBadges:
  • sergioza

    Thank You Much Denny,

    Yes we are trying to access network share based on CNAME from SQL 2014. You said it'd not work by default. Do you know if there are steps/settings which would make it work?

    Thank you


    20 pointsBadges:
  • Denny Cherry

    Yes, here's the MSKB document that has the registry key that needs to be changed.


    69,125 pointsBadges:

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

Share this item with your network: