Robert Heller <[email protected]> wrote:
> At Sun, 5 Jul 2026 20:19:12 +0100 Chris Green <[email protected]> wrote:
>
> >
> > This isn't a problem as such but I don't understand why it's happening
> > and I'd like to understand.
> >
> > I have a VPS called isbd.biz and I access it using ssh. My user
> > account on both my local machine (desktop and laptop) is 'chris' and
> > my user account on isbd.biz is also 'chris'.
> >
> > I have account 'chris' on isbd.biz set up to allow login only using
> > public key authentication.
> >
> > The ip address of isbd.biz is 213.171.194.64.
> >
> > If I log in with 'ssh 213.171.194.64' I, correctly, get prompted for
> > my local system's public key passphrase and I can log in successfully.
> >
> > However if I try 'ssh isbd.biz' I get prompted for "[email protected]'s
> > password" which doesn't exist and I can't log in.
> >
> > 'host isbd.biz' returns the correct IP address for isbd.biz so why
> > does ssh not work using the name rather than the IP address?
> >
>
> This probably relates to the contents of ~/.ssh/known_hosts. 213.171.194.64
> is in ~/.ssh/known_hosts, but isbd.biz is not.
>
None of my systems have a known_hosts file, I have it disabled as
follows:-
HashKnownHosts no
StrictHostKeyChecking no
UserKnownHostsFile=/dev/null
LogLevel=ERROR
Like quite a few people nowadays I find it more of a nusiance than a
help.
I can log in to other systems using the hostname rather than the IP
address. E.g. I have another VPS at gvps.uk and I can log in to that
using 'ssh gvps.uk'. I can't see any real difference between the
setup of gvps.uk and isbd.biz in my ~/.ssh/config file but one works
OK using the hostname and the other doesn't.
--
Chris Green
ยท