I have just observed the IP address change. I pasted the output from
journalctl -b --no-pager --full
here:
https://paste.opensuse.org/pastes/4b163fb49ac1
I notice the following:
Mar 09 13:26:25 venere NetworkManager[682]: [1710019585.4831] dhcp4 (eth1): state changed extended → expire
Mar 09 13:26:25 venere NetworkManager[682]: [1710019585.4840] device (eth1): DHCPv4: trying to acquire a new lease within 90 seconds
Mar 09 13:26:30 venere NetworkManager[682]: [1710019590.3044] dhcp4 (eth1): address 192.168.1.146
Mar 09 13:26:30 venere NetworkManager[682]: [1710019590.3045] dhcp4 (eth1): plen 24 (255.255.255.0)
Mar 09 13:26:30 venere NetworkManager[682]: [1710019590.3045] dhcp4 (eth1): gateway 192.168.1.1
Mar 09 13:26:30 venere NetworkManager[682]: [1710019590.3045] dhcp4 (eth1): lease time 86400
Mar 09 13:26:30 venere NetworkManager[682]: [1710019590.3045] dhcp4 (eth1): nameserver ‘75.75.75.75’
Mar 09 13:26:30 venere NetworkManager[682]: [1710019590.3045] dhcp4 (eth1): nameserver ‘75.75.76.76’
Mar 09 13:26:30 venere NetworkManager[682]: [1710019590.3046] dhcp4 (eth1): nameserver ‘192.168.1.1’
Mar 09 13:26:30 venere NetworkManager[682]: [1710019590.3046] dhcp4 (eth1): domain name ‘hsd1.wa.comcast.net .’
Mar 09 13:26:30 venere NetworkManager[682]: [1710019590.3046] dhcp4 (eth1): state changed expire → bound, address=192.168.1.146
Mar 09 13:26:30 venere avahi-daemon[680]: Withdrawing address record for 192.168.1.128 on eth1.
Mar 09 13:26:30 venere avahi-daemon[680]: Leaving mDNS multicast group on interface eth1.IPv4 with address 192.168.1.128.
Mar 09 13:26:30 venere avahi-daemon[680]: Interface eth1.IPv4 no longer relevant for mDNS.
Mar 09 13:26:30 venere dbus-daemon[681]: [system] Activating via systemd: service name=‘org.freedesktop.nm_dispatcher’ unit=‘dbus-org.freedesktop.nm-dispatcher.service’ requested by ‘:1.3’ (uid=0 pid=682 comm="/usr/sbin/NetworkManager --no-daemon ")
Mar 09 13:26:30 venere systemd[1]: Starting Network Manager Script Dispatcher Service…
Mar 09 13:26:30 venere avahi-daemon[680]: Joining mDNS multicast group on interface eth1.IPv4 with address 192.168.1.146.
Mar 09 13:26:30 venere avahi-daemon[680]: New relevant interface eth1.IPv4 for mDNS.
Mar 09 13:26:30 venere avahi-daemon[680]: Registering new address record for 192.168.1.146 on eth1.IPv4.
Mar 09 13:26:30 venere dbus-daemon[681]: [system] Successfully activated service ‘org.freedesktop.nm_dispatcher’
Mar 09 13:26:30 venere systemd[1]: Started Network Manager Script Dispatcher Service.
Mar 09 13:26:41 venere systemd[1]: NetworkManager-dispatcher.service: Deactivated successfully.
On my small local network I set use IP4 in /etc/hosts
IP-Address Full-Qualified-Hostname Short-Hostname
BTW, admit not yet figured out how to write IP6’s…
.
.
Mar 08 09:39:28 venere NetworkManager[682]: <info> [1709919568.6331] dhcp4 (eth1): lease time 86400
...
Mar 09 13:26:25 venere NetworkManager[682]: <info> [1710019585.4831] dhcp4 (eth1): state changed extended -> expire
Mar 09 13:26:25 venere NetworkManager[682]: <info> [1710019585.4840] device (eth1): DHCPv4: trying to acquire a new lease within 90 seconds
Lease time is 24 hours. If you look at the previous logs, NetworkManager refreshed address before lease expired. In this case for whatever reason it could not do it (system was not up?) so it requested new address. What address was allocated is entirely up to your DHCP server.
You are mistaken. When DHCPv4 client requests new lease it does not send any existing address. It only does it when extending the currently valid lease (and DHCP server can still refuse to do it).
No, (Internet) connectivity check has nothing to do with IP address allocation.
1 Like
Lease time is 24 hours.
Is this set by the OS or the router?
If you look at the previous logs, NetworkManager refreshed address before lease expired. In this case for whatever reason it could not do it (system was not up?) so it requested new address.
I am still puzzled why this is happening with openSUSE 15.4. I have an old installation of openSUSE 15.2 (also with NetworkManager) and openSUSE 12.2 (wicked). In both cases, I keep getting the exact same dynamic IP address from the router even if I have not booted in weeks.
It is set by router.
It would be interesting to compare network packet capture of DHCP transaction in each case.
What are the host settings? The first thing that comes to mind is that you have defined a client id on some hosts and not others.
What are the host settings? The first thing that comes to mind is that you have defined a client id on some hosts and not others.
Not sure what “host settings” are. Is there a place where I can look that up? This is the content of /etc/hosts:
127.0.0.1 localhost
# special IPv6 addresses
::1 localhost ipv6-localhost ipv6-loopback
fe00::0 ipv6-localnet
ff00::0 ipv6-mcastprefix
ff02::1 ipv6-allnodes
ff02::2 ipv6-allrouters
ff02::3 ipv6-allhosts
No, you’d need to look at NetworkManagers or wickeds configurations.
No, you’d need to look at NetworkManagers or wickeds configurations.
This is what I see with nmcli con show
connection.id: Wired connection 1
connection.uuid: 7d944fd7-a379-374a-b242-f170dd8f8cf2
connection.stable-id: –
connection.type: 802-3-ethernet
connection.interface-name: eth1
connection.autoconnect: yes
connection.autoconnect-priority: -999
connection.autoconnect-retries: -1 (default)
connection.multi-connect: 0 (default)
connection.auth-retries: -1
connection.timestamp: 1709599848
connection.read-only: no
connection.permissions: –
connection.zone: –
connection.master: –
connection.slave-type: –
connection.autoconnect-slaves: -1 (default)
connection.secondaries: –
connection.gateway-ping-timeout: 0
connection.metered: unknown
connection.lldp: default
connection.mdns: -1 (default)
connection.llmnr: -1 (default)
connection.wait-device-timeout: -1
802-3-ethernet.port: –
802-3-ethernet.speed: 0
802-3-ethernet.duplex: –
802-3-ethernet.auto-negotiate: no
802-3-ethernet.mac-address: –
802-3-ethernet.cloned-mac-address: –
802-3-ethernet.generate-mac-address-mask:–
802-3-ethernet.mac-address-blacklist: –
802-3-ethernet.mtu: auto
802-3-ethernet.s390-subchannels: –
802-3-ethernet.s390-nettype: –
802-3-ethernet.s390-options: –
802-3-ethernet.wake-on-lan: default
802-3-ethernet.wake-on-lan-password: –
802-3-ethernet.accept-all-mac-addresses:-1 (default)
ipv4.method: auto
ipv4.dns: –
ipv4.dns-search: bioeng.washington.edu
ipv4.dns-options: –
ipv4.dns-priority: 0
ipv4.addresses: –
ipv4.gateway: –
ipv4.routes: –
ipv4.route-metric: -1
ipv4.route-table: 0 (unspec)
ipv4.routing-rules: –
ipv4.ignore-auto-routes: no
ipv4.ignore-auto-dns: no
ipv4.dhcp-client-id: –
ipv4.dhcp-iaid: –
ipv4.dhcp-timeout: 0 (default)
ipv4.dhcp-send-hostname: yes
ipv4.dhcp-hostname: –
ipv4.dhcp-fqdn: –
ipv4.dhcp-hostname-flags: 0x0 (none)
ipv4.never-default: no
ipv4.may-fail: yes
ipv4.required-timeout: -1 (default)
ipv4.dad-timeout: -1 (default)
ipv4.dhcp-vendor-class-identifier: –
ipv4.dhcp-reject-servers: –
ipv6.method: auto
ipv6.dns: –
ipv6.dns-search: –
ipv6.dns-options: –
ipv6.dns-priority: 0
ipv6.addresses: –
ipv6.gateway: –
ipv6.routes: –
ipv6.route-metric: -1
ipv6.route-table: 0 (unspec)
ipv6.routing-rules: –
ipv6.ignore-auto-routes: no
ipv6.ignore-auto-dns: no
ipv6.never-default: no
ipv6.may-fail: yes
ipv6.required-timeout: -1 (default)
ipv6.ip6-privacy: -1 (unknown)
ipv6.addr-gen-mode: stable-privacy
ipv6.ra-timeout: 0 (default)
ipv6.dhcp-duid: –
ipv6.dhcp-iaid: –
ipv6.dhcp-timeout: 0 (default)
ipv6.dhcp-send-hostname: yes
ipv6.dhcp-hostname: –
ipv6.dhcp-hostname-flags: 0x0 (none)
ipv6.token: –
proxy.method: none
proxy.browser-only: no
proxy.pac-url: –
proxy.pac-script: –
GENERAL.NAME: Wired connection 1
GENERAL.UUID: 7d944fd7-a379-374a-b242-f170dd8f8cf2
GENERAL.DEVICES: eth1
GENERAL.IP-IFACE: eth1
GENERAL.STATE: activated
GENERAL.DEFAULT: yes
GENERAL.DEFAULT6: yes
GENERAL.SPEC-OBJECT: –
GENERAL.VPN: no
GENERAL.DBUS-PATH: /org/freedesktop/NetworkManager/ActiveConnection/1
GENERAL.CON-PATH: /org/freedesktop/NetworkManager/Settings/2
GENERAL.ZONE: –
GENERAL.MASTER-PATH: –
IP4.ADDRESS[1]: 192.168.1.128/24
IP4.GATEWAY: 192.168.1.1
IP4.ROUTE[1]: dst = 0.0.0.0/0, nh = 192.168.1.1, mt = 100
IP4.ROUTE[2]: dst = 192.168.1.0/24, nh = 0.0.0.0, mt = 100
IP4.DNS[1]: 75.75.75.75
IP4.DNS[2]: 75.75.76.76
IP4.DNS[3]: 192.168.1.1
IP4.DOMAIN[1]: hsd1.wa.comcast.net
IP4.SEARCHES[1]: bioeng.washington.edu
DHCP4.OPTION[1]: broadcast_address = 192.168.1.255
DHCP4.OPTION[2]: dad_wait_time = 0
DHCP4.OPTION[3]: dhcp_lease_time = 86400
DHCP4.OPTION[4]: dhcp_message_type = 5
DHCP4.OPTION[5]: dhcp_server_identifier = 192.168.1.1
DHCP4.OPTION[6]: domain_name = hsd1.wa.comcast.net .
DHCP4.OPTION[7]: domain_name_servers = 75.75.75.75 75.75.76.76 192.168.1.1
DHCP4.OPTION[8]: expiry = 1709662136
DHCP4.OPTION[9]: ip_address = 192.168.1.128
DHCP4.OPTION[10]: network_number = 192.168.1.0
DHCP4.OPTION[11]: next_server = 0.0.0.0
DHCP4.OPTION[12]: requested_broadcast_address = 1
DHCP4.OPTION[13]: requested_domain_name = 1
DHCP4.OPTION[14]: requested_domain_name_servers = 1
DHCP4.OPTION[15]: requested_domain_search = 1
DHCP4.OPTION[16]: requested_host_name = 1
DHCP4.OPTION[17]: requested_interface_mtu = 1
DHCP4.OPTION[18]: requested_ms_classless_static_routes = 1
DHCP4.OPTION[19]: requested_nds_context = 1
DHCP4.OPTION[20]: requested_nds_servers = 1
DHCP4.OPTION[21]: requested_nds_tree_name = 1
DHCP4.OPTION[22]: requested_netbios_dd_server = 1
DHCP4.OPTION[23]: requested_netbios_name_servers = 1
DHCP4.OPTION[24]: requested_netbios_node_type = 1
DHCP4.OPTION[25]: requested_netbios_scope = 1
DHCP4.OPTION[26]: requested_nis_domain = 1
DHCP4.OPTION[27]: requested_nis_servers = 1
DHCP4.OPTION[28]: requested_ntp_servers = 1
DHCP4.OPTION[29]: requested_rfc3442_classless_static_routes = 1
DHCP4.OPTION[30]: requested_root_path = 1
DHCP4.OPTION[31]: requested_routers = 1
DHCP4.OPTION[32]: requested_static_routes = 1
DHCP4.OPTION[33]: requested_subnet_mask = 1
DHCP4.OPTION[34]: requested_wpad = 1
DHCP4.OPTION[35]: routers = 192.168.1.1
DHCP4.OPTION[36]: subnet_mask = 255.255.255.0
IP6.ADDRESS[1]: 2002:1811:3d42:0:d2e3:ff96:d9c:5a0e/64
IP6.ADDRESS[2]: 2002:1811:3d42:0:c912:6c3:e:6b72/64
IP6.ADDRESS[3]: fe80::f1b6:2149:a20e:32e/64
IP6.GATEWAY: fe80::5a6d:8fff:fe56:412a
IP6.ROUTE[1]: dst = 2002:1811:3d42::/64, nh = ::, mt = 100
IP6.ROUTE[2]: dst = ::/0, nh = fe80::5a6d:8fff:fe56:412a, mt = 20100
IP6.ROUTE[3]: dst = fe80::/64, nh = ::, mt = 100
I have decided to explicitly reserve a IP address for the MAC address of my network card. I did this in the router settings. This was the same suggestion as by Fraser_ball above. Hopefully, the IP address will be stable now.
1 Like
From the title of your post, that’s exactly the solution. @Fraser_Bell
I am still curious why this happens. Is this a bug or a new feature, or just a combination of things? I have always observed that the IP address provided by a home router stays always the same even when assigned dynamically.
Provide network capture of DHCP transaction in “good” and “bad” cases.
That’s completely by chance, I have no idea how (so far) it got stuck assigning you the same IP address from the DHCP server’s configured pool of IPs. It can’t be chance, right? So maybe there was some internal logic where it assigned you a certain IP and then when the lease was up, reassigned you the same one. Perhaps an update changed this behavior.
Ok, so that’s one host, can’t compare configurations when you provide just one.
The interesting parts would be just these.
DHCP4.OPTION dhcp_lease_time might be interesting too.
Now this is assuming your assertion that -
is true. That would mean there would have to be something the client is providing allowing the DHCP server to track the connections. You can rule out MAC address unless you’re changing the MAC on your NIC regularly.
gianluca44:
Where do I find that?
You capture them, but if you have no prior experience at all it may be complicated.
OK, enable tracing on both “good” and “bad” system with NetworkManager, trigger lease expiration (suspend, wait for 24 hours), provide full journalctl -b --no-pager --full
ouptut. It is better to reboot after enabling tracing to minimize log size.
To enable trace, create file /etc/NetworkManager/conf.d/trace.conf
with the content
[logging]
level=TRACE
domains=ALL
You need to restart NetworkManager or reboot.
system
Closed
April 11, 2024, 12:50pm
38
This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.