Re: network manager spamming logs with repetitive messages

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

 



Tim:
>> Just out of curiosity, is it only applying localhost.localdomain to
>> your 127.0.0.1 loopback interface (like it should), or is it trying
>> to apply it to an ethernet or wifi interface (which it shouldn't)?

You didn't answer the above query.



Frank:
> Here's the situation this morning. Following a suggestion from John
> Quirke
> 
> I added a line to /etc/NetManager/NetManager.conf hostname-mode=none.
> 
> That has stopped the repeated logging, but now when I click on the
> netmanager icon in the tray it tells me the network has been
> disconnected. Actually it hasn't been so I don't know what is up with
> that.
> 
> I also do not understand why the repeated logging started as no
> changes were made to anything network-related.

Perhaps you should reboot your router.  Maybe it glitched.

Maybe you should remove the connection info network manager has set for
your interface, and let it freshly create a new one from your DHCP
server.

> This is now my hosts file in /etc
> 127.0.0.1   localhost localhost.localdomain localhost4 localhost4.localdomain4
> ::1         localhost localhost.localdomain localhost6 localhost6.localdomain6
> 
> I do not understand the references to localhost4 and localhost6 in
> that file.

That looks fine.  The localhost 4 and 6 gubbins seems to be some new-
fangled stuff that someone thinks is a good idea.  I've never heard of
anything using it.

The local loopback interface is on 127.0.0.1, and is traditionally
given the hostname "localhost".  For some reason, Linux adds an extra
localhost.localdomain alias to it, perhaps to satisfy some daemons that
insist on having at least one dot in a hostname.

The loopback interface is how the computer communicates within itself. 
If there's any purely internal network traffic inside the computer, it
doesn't even go through any of the network hardware.  And it uses that
IP address, and gives it a "localhost" name.  It's like you looking at
yourself in the mirror and saying, "that's me," talking inside your
head.

Other interfaces (ethernet or wifi) should have their own completely
independent IP addresses and hostnames.  i.e. They should *NOT* be
called localhost.  If your DHCP server is working right, it should all
this properly for you.

> I connect to the internet on a wired connection to my providers
> router via DHCP. There is no wireless or other networks involved.

A DHCP server should give you an IP, hopefully (for you) the same one
each time.  And it may also give that interface a hostname.  It may
not, some routers only do a half-hearted job at it.

The https://unix.stackexchange.com/a/513413/452882 link provided
earlier tries to stop your computer listening the DHCP server regarding
a hostname.  Essentially the idea is that you name the computer
yourself, and hope to keep a consistent hostname.  That link then goes
on about them getting the computer to be localhost and
localhost.localdomain, on the non localhost interface which is leading
a networking nightmare.

If you can, configure your router to give you an IP and hostname.  If
you can't, then configure your computer to have its own hostname, and
don't call it localhost, nor localhost.localdomain.  Normally, I've
found Fedora would carry on using your assigned hostname if nothing
else changed it.  i.e. A DHCP server that only gives you an IP without
a name, will give you an IP, and you'll keep using the hostname you
manually set.

Try reading "man hostname" about manually setting a hostname (I reckon
you'll *need* to "su -" and do this as the root user, or through sudo).

When a computer doesn't have a hostname, and hasn't been given one to
use, one thing it can do is a reverse lookup on its assigned IP.

e.g. Your DHCP server says:  you are 192.168.1.23
     Your computer asks its DNS server, what's the name for 192.168.1.23
     Your DNS server says that's:  george.example.com
     Your computer refers to itself as george (the hostname) and
     george.example.com (as a fully-qualified domain name).

Without a fully functional DHCP server, and a co-operating DNS server
(your ISP's won't help, its outside of your DHCP server), you'll have
to manage some of that yourself.  And that's much easier if your
computer always gets given the same IP address.  A simple approach is
to use the hostname command to name your computer, and put its name
into your /etc/hosts file.

e.g. Under the two existing lines, add something like:

192.168.1.23  george

  or, like this:

192.168.1.23  george   george.example.com

The first info is your IP, use *YOUR* actual IP.
The thing next to it (george) is the name you want it known as.
It can be followed by aliases (alternative names it can respond to).

Now your computer will consult its hosts file to find its name, rather
than try to get an answer from a DNS server that isn't going to give it
one.

If your computer is the only thing on your network (after the router),
you could just set a manual address and completely ignore DHCP.  You
can do that through the NetworkManager interface.  Pick an IP that's
not in use, and in the same range as the router.

-- 
 
uname -rsvp
Linux 3.10.0-1160.25.1.el7.x86_64 #1 SMP Wed Apr 28 21:49:45 UTC 2021 x86_64
 
Boilerplate:  All unexpected mail to my mailbox is automatically deleted.
I will only get to see the messages that are posted to the mailing list.
 
_______________________________________________
users mailing list -- users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to users-leave@xxxxxxxxxxxxxxxxxxxxxxx
Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: https://lists.fedoraproject.org/archives/list/users@xxxxxxxxxxxxxxxxxxxxxxx
Do not reply to spam on the list, report it: https://pagure.io/fedora-infrastructure



[Index of Archives]     [Older Fedora Users]     [Fedora Announce]     [Fedora Package Announce]     [EPEL Announce]     [EPEL Devel]     [Fedora Magazine]     [Fedora Summer Coding]     [Fedora Laptop]     [Fedora Cloud]     [Fedora Advisory Board]     [Fedora Education]     [Fedora Security]     [Fedora Scitech]     [Fedora Robotics]     [Fedora Infrastructure]     [Fedora Websites]     [Anaconda Devel]     [Fedora Devel Java]     [Fedora Desktop]     [Fedora Fonts]     [Fedora Marketing]     [Fedora Management Tools]     [Fedora Mentors]     [Fedora Package Review]     [Fedora R Devel]     [Fedora PHP Devel]     [Kickstart]     [Fedora Music]     [Fedora Packaging]     [Fedora SELinux]     [Fedora Legal]     [Fedora Kernel]     [Fedora OCaml]     [Coolkey]     [Virtualization Tools]     [ET Management Tools]     [Yum Users]     [Yosemite News]     [Gnome Users]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Fedora Sparc]     [Libvirt Users]     [Fedora ARM]

  Powered by Linux