Re: IP address variable

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

 



On Wed, 2005-02-16 at 11:38 -0500, Matt Morgan wrote:
> On Wed, 16 Feb 2005 09:36:47 -0600, Thomas Cameron
> <thomas.cameron@xxxxxxxxxxxxxxx> wrote:
---<snip>
> > 
> > Why not just use hostname -i?
> 
> This would help me out too, so I tried this. I get 127.0.0.1 :-). How
> can I fix that so that command gives me the address I actually want?
> man hostname doesn't help me. Thanks.

Check your /etc/hosts file. If localhost IP includes your hostname,
that's what you'll get. Change it to this:

127.0.0.1       localhost.<localdomain>   localhost

And if you have a static IP address, and not using a local DNS to
resolve IP addresses, then put a separate line for the address of your
NIC.

-- 
C. Linus Hicks <lhicks at nc dot rr dot com>


[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux