Avatar of gd6627
gd6627Flag for United States of America

asked on 

Adding a port to the cname record

How can i create a cname record to a web server that uses a particular port ?

I already have the dns record but i need to create a cname can i add the port number to the FDQN section of the cname?
DNSActive Directory

Avatar of undefined
Last Comment
gd6627
Avatar of Cliff Galiher
Cliff Galiher
Flag of United States of America image

Can't be done. That isn't the intent of DNS and the DNS standards offer no means to do this nor would a client understand what it means if you did.
ASKER CERTIFIED SOLUTION
Avatar of Coolie Sheppard
Coolie Sheppard
Flag of United States of America image

Blurred text
THIS SOLUTION IS ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
Avatar of noci
noci

Browsers use hardcoded ports 80 for http & 443 for https. UNLESS otherwise specified in the URL.
So your users will need to type it.
Avatar of Alan
Alan
Flag of New Zealand image

Hi,

You could setup a presite page which contains a link / redirect with the port number hardcoded.

Users would go there first (for such a simple page, you might even use free hosting or at least very cheap), then get sent on to the real site using the non standard port number.

Alan.
Avatar of noci
noci

DNS only is about hostnames.. ( and then only for humans, machines don't care about the names, the real communication is using IP addresses.
Avatar of Shaun Vermaak
Shaun Vermaak
Flag of Australia image

No need for additional IP addresses.

In bindings of site add a host header. This way you can have multiple sites on same port and IP, similar to shared hosting

User generated image
Avatar of Jeff Glover
Jeff Glover
Flag of United States of America image

The only way I know of to accomplish this is available via GoDaddy or by making your own website. If you use GoDaddy as DNS, there is a feature called domain/subdomain forwarding. You list the subdomain you want to forward (like www) and list the entire URL you want it to go to. You can include a port on the end of the URL there.
  You can do the same thing by creating a redirect site in IIS. Simply make an empty site there and use IIS redirection to redirect traffic to the correct port.
  This may be available via other DNS hosting providers, not sure. We only use GoDaddy.
Avatar of noci
noci

The question was about a port... not a different name.
Avatar of Jeff Glover
Jeff Glover
Flag of United States of America image

And we answered him about that. Can't be done in DNS with a cname record. Period. However, as is our way, we suggest ways around it.
Avatar of gd6627
gd6627
Flag of United States of America image

ASKER

Thanks everyone I get that you cant assign a port in DNS but I was trying to make the user experience better by not having them type the FQDN literally so I created a friendly CNAME record but I didn't know how to direct the user to the actual port of the app on the server .

I wanted to know how to do that without having to deploy or create a short cut with the port assigned in the url.
I wanted the user to open a browser and type for example  MYApp and it would just go to the UI of the server

Cooli had the explanation I needed
Active Directory
Active Directory

Active Directory (AD) is a Microsoft brand for identity-related capabilities. In the on-premises world, Windows Server AD provides a set of identity capabilities and services, and is hugely popular (88% of Fortune 1000 and 95% of enterprises use AD). This topic includes all things Active Directory including DNS, Group Policy, DFS, troubleshooting, ADFS, and all other topics under the Microsoft AD and identity umbrella.

86K
Questions
--
Followers
--
Top Experts
Get a personalized solution from industry experts
Ask the experts
Read over 600 more reviews

TRUSTED BY

IBM logoIntel logoMicrosoft logoUbisoft logoSAP logo
Qualcomm logoCitrix Systems logoWorkday logoErnst & Young logo
High performer badgeUsers love us badge
LinkedIn logoFacebook logoX logoInstagram logoTikTok logoYouTube logo