[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: host aliases

On Mon, 19 Mar 2007 08:44:23 +0100
Matus UHLAR - fantomas <uhlar@fantomas.sk> wrote:

> On 18.03.07 16:15, Celejar wrote:
> > I want to configure a system-wide host alias. Say there's a host whose
> > DNS name is 'foo.bar'. I want any network application that asks for
> > 'baz' to get 'foo.bar'. I know I can do this for individual apps; in
> > ssh, for example, I include these 2 lines in 'config':
> > 
> > Host		baz
> > HostName	foo.bar
> > 
> > But is this possible on an app-independent, system-wide basis? If the
> > host is accessed by several different apps, it would be a pain to do
> > this separately for each one, and a greater pain to adjust if the alias
> > ever changed.
> > 
> > /etc/hosts allows aliases of names to IP addresses, but not,
> > apparently, of one name to another without an IP address. Is there any
> > way to do what I want (preferably without needing to install a DNS
> > server, even a lightweight one such as dnsmasq)?
> I don't know about any. Even dnsmasq can't do that.
> Why do you want to map name to another name? Why isn't mapping to IP enough
> for you?

I don't, in general, know the IP address. I have a system on my LAN,
accessible on the internet via a dynamic DNS name. I want to refer to
it by a short nickname. That's exactly what the 'HostName' option in
the ssh 'config' file does, so someone finds this useful, and I was
wondering if there's any way to do this on an application-independent


ssuds.sourceforge.net - Home of Ssuds and Ssudg, a Simple Sudoku Solver
and Generator

Reply to: