On Thu, 12 Dec 2002 09:58:03 +0000, the artist formerly known as Russell
> So if I do `hostname google.com` and then go to work, I should be able
> right? Don't think so...
No, you won't. But the hostname of your machine will be
Quote:> Maybe I am confusing host name with domain name (shrug)?
Quote:> What I want is
> for hostname to not give me my mac address, but rather
> 12-210-154-154.client.attbi.com. I can get this via host `ifconfig ...`,
> but I'm wondering why hostname doesn't work in the first place.
This can be done, because I had this happen to my accidentally on a red
hat 7.x series, but I don't know how you set it up, but don't worry, cuz
thereps more coming...
Quote:> I want to be able to look at my command prompt, or login screen, or type
> hostname, or anywhere else it's SUPPOSED to be correct, and see what my
> hostname is (since it changes every now and then) so I can ssh in from
> school or work. Not to mention that gnome already complains that the
> host name isn't correct.
All 12-210-154-154.client.attbi.com, is, in your example, is your IP
address plus other info at&t is giving you. To reach your machine, all
you need is the IP address portion. If you want to ssh to your machine
from work, you would just ssh to 18.104.22.168.
> It's also entirely possible that I'm missing the point of what a host
> name is completely. Maybe you can clarify. An example. At school we have
> a solaris machine named clyde (and its partner bonnie). When you login,
> it says "Welcome to clyde". The hostname command outputs "clyde". When I
> the machine's hostname is set to clyde have anything to do with the URL
That is because the university owns the entire domain, thus they are in
control of their DNS server/records and clyde.domain.edu is always mapping
to IP address 22.214.171.124 (whatever the actual IP address is). So when you do
and the machine is actually doing an ssh to 126.96.36.199. Humans speak words,
computers speak numbers. The reason you can't use the name/hostname for
your home machine is you don't own the attbi.com domain, and as such, you
are getting a different ip address dynamically. So if you set your
hostname to you.domain.com, that will be 188.8.131.52 one day, and 184.108.40.206 the
Quote:> I use to connect to it? Or is it just a coincidence? For example, if the
> sys admin did a `hostname bob`, the login screen would say "Welcome to
> bob", but the URL I would use to connect would still be
> clyde.domain.edu, right?
Most likely yes, unless the sysadmin also updated the dns records to point
bob.domain.edu to the same box/ip address.
Quote:> It is my understanding that hostname is used to get the URL of the
> machine. Perhaps this is where I am steering off into the weeds.
Like I said earlier, the hostname can be anything, it is what is in the
DNS records that matters. For convenience (and sanity's sake) the
university is mapping clyde.domain.edu in the DNS records, to the box with
hostname cyde.domain.edu. They *could* map clyde.domain.edu to
anymachine.domain.edu that they wanted.
Hope that makes sense and I haven't added to your confusion.
> Thanks for your help.
One OS to rule them all, One Passport to find them,
DRM to bring them all and with the EULA bind them.