[SOLVED] Change SSH login from an ip address to a domain name
Linux - NetworkingThis forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Change SSH login from an ip address to a domain name
Centos 7
Amazon EC2
two ip addresses static and elastic. elastic is public ip which is what I currently ssh into. I want something easier to remember to login with.
I have a registered domain name / vhost on this server. I want to change my ssh login from 'name@public-ip' to 'name@mydomain.com'
Not sure if that makes sense. I'm not sure what to look up to fix this. Not sure if it's a Centos thing, an amazon thing, or both.
If someone could point me in the right direction, that would be great.
host returned the right ip address. I noticed that host only worked with www in front of the domain, so I tried ssh user@www.domain.com instead of ssh user@domain.com. it works. not sure why it won't work without www, but it's not that big of a deal. My ftp and other programs remember the ip address. I however don't, and I have to search for it when using the terminal. Now I don't have to. thanks again for your help.
Technically what it means is that DNS has an A record for www.mydomain.com, but there is only an NS record for mydomain.com. Most web domains have the same A record for both so you don't have to type the "www." to get to the website.
I added an A record for mydomain.com without the www to amazon route 53, and it works. I have a zone file with mediatemple because that is where the domain is registered. Amazon requires the same info in their "Route 53" section. It appears that the Amazon requires nameserver info installed on mediatemple, but the "Route 53" zone info seems to override the mediatemple zone file. That confused me just writing it. thanks again
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.