Page 1 of 2 12 LastLast
Results 1 to 10 of 16

Thread: Network manager and wicked working at same time: two IPS for eth0

  1. #1

    Default Network manager and wicked working at same time: two IPS for eth0

    I have IP for eth0 cofigured with static IP with wicked. But when booting my computer gets an IP through dhcp.
    I have seen with ip adress that eth0 has then tro different addresses, the static adress and a dynamic adress.
    I can solve the problem with

    Code:
    # systemctl stop NetworkManager
    But when booting it gets again the dhcp IP.
    I ca't find where to disable network manager permanently.

    Any help?

    thanks

  2. #2
    Join Date
    Jan 2014
    Location
    Erlangen
    Posts
    740

    Default Re: Network manager and wicked working at same time: two IPS for eth0

    Quote Originally Posted by fperal View Post
    I have IP for eth0 cofigured with static IP with wicked. But when booting my computer gets an IP through dhcp.
    I have seen with ip adress that eth0 has then tro different addresses, the static adress and a dynamic adress.
    I can solve the problem with

    Code:
    # systemctl stop NetworkManager
    But when booting it gets again the dhcp IP.
    I ca't find where to disable network manager permanently.

    Any help?

    thanks
    Code:
    erlangen:~ # systemctl disable NetworkManager
    Removed /etc/systemd/system/dbus-org.freedesktop.nm-dispatcher.service.
    erlangen:~ # systemctl status NetworkManager
    ● NetworkManager.service - Network Manager
       Loaded: loaded (/usr/lib/systemd/system/NetworkManager.service; disabled; vendor preset: disabled)
      Drop-In: /usr/lib/systemd/system/NetworkManager.service.d
               └─NetworkManager-ovs.conf
       Active: inactive (dead)
         Docs: man:NetworkManager(8)
    erlangen:~ #
    AMD Athlon 4850e (2009), openSUSE 13.1, KDE 4, Intel i3-4130 (2014), i7-6700K (2016), i5-8250U (2018), openSUSE Tumbleweed, KDE Plasma 5

  3. #3
    Join Date
    Jun 2008
    Location
    Netherlands
    Posts
    24,381

    Default Re: Network manager and wicked working at same time: two IPS for eth0

    While the above answer to stop NM from being started on boot is correct, I am a bit confused by your post.

    You say that you have a static IP, but that om boot DHCP provides a new IP. Then your consclusion seems to be that that is done by NM, but you show no prove of that. DHCP is not restrcted to be used ny NM.

    So check with YaST > Network Devices > Network Settings if you have the correct choice between Wicked and NM and also what is configured about DHCP.

    Also, next time, show what you tell. E.g. we miss here
    Code:
    ip address
    Last edited by hcvv; 08-Feb-2019 at 05:58.
    Henk van Velden

  4. #4

    Default Re: Network manager and wicked working at same time: two IPS for eth0

    Quote Originally Posted by hcvv View Post
    While the above answer to stop NM from being started on boot is correct, I am a bit confused by your post.

    You say that you have a static IP, but that om boot DHCP provides a new IP. Then your consclusion seems to be that that is done by NM, but you show no prove of that. DHCP is not restrcted to be used ny NM.

    So check with YaST > Network Devices > Network Settings if you have the correct choice between Wicked and NM and also what is configured about DHCP.

    Also, next time, show what you tell. E.g. we miss here
    Code:
    ip address


    Code:
    #ifconfig
    
    eth0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
            inet 192.168.2.112  netmask 255.255.255.0  broadcast 192.168.2.255
            inet6 fe80::8a3a:18ad:330e:a12  prefixlen 64  scopeid 0x20<link>
            ether 20:cf:30:c0:39:4b  txqueuelen 1000  (Ethernet)
            RX packets 203  bytes 41644 (40.6 KiB)
            RX errors 0  dropped 0  overruns 0  frame 0
            TX packets 222  bytes 43935 (42.9 KiB)
            TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0
    
    lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536
            inet 127.0.0.1  netmask 255.0.0.0
            loop  txqueuelen 1000  (Local Loopback)
            RX packets 0  bytes 0 (0.0 B)
            RX errors 0  dropped 0  overruns 0  frame 0
            TX packets 0  bytes 0 (0.0 B)
            TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0
    
    vmnet1: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
            inet 172.16.172.1  netmask 255.255.255.0  broadcast 172.16.172.255
            ether 00:50:56:c0:00:01  txqueuelen 1000  (Ethernet)
            RX packets 0  bytes 0 (0.0 B)
            RX errors 0  dropped 0  overruns 0  frame 0
            TX packets 11  bytes 0 (0.0 B)
            TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0
    
    vmnet8: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
            inet 172.16.17.1  netmask 255.255.255.0  broadcast 172.16.17.255
            ether 00:50:56:c0:00:08  txqueuelen 1000  (Ethernet)
            RX packets 0  bytes 0 (0.0 B)
            RX errors 0  dropped 0  overruns 0  frame 0
            TX packets 11  bytes 0 (0.0 B)
            TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0


    Code:
    #ip address
    1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
        link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
        inet 127.0.0.1/8 scope host lo
           valid_lft forever preferred_lft forever
    2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000
        link/ether 20:cf:30:c0:39:4b brd ff:ff:ff:ff:ff:ff
        inet 192.168.2.112/24 brd 192.168.2.255 scope global noprefixroute dynamic eth0
           valid_lft 443sec preferred_lft 443sec
        inet 192.168.2.3/24 brd 192.168.2.255 scope global secondary noprefixroute eth0
           valid_lft forever preferred_lft forever
        inet6 fe80::8a3a:18ad:330e:a12/64 scope link noprefixroute 
           valid_lft forever preferred_lft forever
    3: vmnet1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UNKNOWN group default qlen 1000
        link/ether 00:50:56:c0:00:01 brd ff:ff:ff:ff:ff:ff
        inet 172.16.172.1/24 brd 172.16.172.255 scope global vmnet1
           valid_lft forever preferred_lft forever
    4: vmnet8: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UNKNOWN group default qlen 1000
        link/ether 00:50:56:c0:00:08 brd ff:ff:ff:ff:ff:ff
        inet 172.16.17.1/24 brd 172.16.17.255 scope global vmnet8
           valid_lft forever preferred_lft forever

    In yast I have the following

    https://susepaste.org/9194479


    https://susepaste.org/59157912





    Then I disable network manager
    Code:
    # systemctl stop NetworkManager

    and after
    Code:
    #ifdown eth0
    #ifup eth0

    Code:
    #ip address
    1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
        link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
        inet 127.0.0.1/8 scope host lo
           valid_lft forever preferred_lft forever
    2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000
        link/ether 20:cf:30:c0:39:4b brd ff:ff:ff:ff:ff:ff
        inet 192.168.2.3/24 brd 192.168.2.255 scope global eth0
           valid_lft forever preferred_lft forever
    3: vmnet1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UNKNOWN group default qlen 1000
        link/ether 00:50:56:c0:00:01 brd ff:ff:ff:ff:ff:ff
        inet 172.16.172.1/24 brd 172.16.172.255 scope global vmnet1
           valid_lft forever preferred_lft forever
    4: vmnet8: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UNKNOWN group default qlen 1000
        link/ether 00:50:56:c0:00:08 brd ff:ff:ff:ff:ff:ff
        inet 172.16.17.1/24 brd 172.16.17.255 scope global vmnet8
           valid_lft forever preferred_lft forever

    I have done
    Code:
    # systemctl disable NetworkManager
    #
    I does not report anything.

  5. #5
    Join Date
    Jun 2008
    Location
    Auckland, NZ
    Posts
    19,716
    Blog Entries
    1

    Default Re: Network manager and wicked working at same time: two IPS for eth0

    Quote Originally Posted by fperal View Post
    I have done
    Code:
    # systemctl disable NetworkManager
    #
    I does not report anything.
    It won't, but it will disable the service (effective next boot), and if it is running you can stop it immediately with
    Code:
    sudo systemctl stop NetworkManager
    You can confirm that it is disabled and currently inactive with

    Code:
    sudo systemctl status NetworkManager
    Similarly, check wicked status with
    Code:
    sudo systemctl status wicked
    openSUSE Leap 15.0; KDE Plasma 5

  6. #6

    Default Re: Network manager and wicked working at same time: two IPS for eth0

    Quote Originally Posted by deano_ferrari View Post
    It won't, but it will disable the service (effective next boot), and if it is running you can stop it immediately with
    Code:
    sudo systemctl stop NetworkManager
    You can confirm that it is disabled and currently inactive with

    Code:
    sudo systemctl status NetworkManager
    Similarly, check wicked status with
    Code:
    sudo systemctl status wicked

    No, it is not disabled. It didn't work.
    After reboot I have again a DHCP IP and

    Code:
    #systemctl status NetworkManager
    ● NetworkManager.service - Network Manager
       Loaded: loaded (/usr/lib/systemd/system/NetworkManager.service; disabled; vendor preset: disabled)
      Drop-In: /usr/lib/systemd/system/NetworkManager.service.d
               └─NetworkManager-ovs.conf
       Active: active (running) since Sat 2019-02-09 08:50:25 CET; 1min 32s ago
         Docs: man:NetworkManager(8)
     Main PID: 1374 (NetworkManager)
        Tasks: 4 (limit: 4915)
       CGroup: /system.slice/NetworkManager.service
               ├─1374 /usr/sbin/NetworkManager --no-daemon
               └─1748 /sbin/dhclient -d -q -sf /usr/lib/nm-dhcp-helper -pf /var/run/dhclient-eth0.pid -lf /var/lib/NetworkManager/dhclient-cae1a3ab-c168-3ed1-b63e-b1e25648b5ef-eth0.lease -cf /var/lib/NetworkManager/dhclient-eth0.conf eth0
    
    Feb 09 08:50:33 andromeda NetworkManager[1374]: <info>  [1549698633.2554] policy: set-hostname: set hostname to 'andromeda.samara.com.es' (from system configuration)
    Feb 09 08:50:33 andromeda.samara.com.es NetworkManager[1374]: <info>  [1549698633.5329] device (eth0): Activation: successful, device activated.
    Feb 09 08:50:33 andromeda.samara.com.es NetworkManager[1374]: <info>  [1549698633.5338] manager: startup complete
    Feb 09 08:50:34 andromeda.samara.com.es NetworkManager[1374]: <info>  [1549698634.6698] manager: NetworkManager state is now CONNECTED_GLOBAL
    Feb 09 08:50:36 andromeda.samara.com.es NetworkManager[1374]: <info>  [1549698636.1471] device (vmnet1): driver '(null)' does not support carrier detection.
    Feb 09 08:50:36 andromeda.samara.com.es NetworkManager[1374]: <info>  [1549698636.1473] device (vmnet1): driver 'unknown' does not support carrier detection.
    Feb 09 08:50:36 andromeda.samara.com.es NetworkManager[1374]: <info>  [1549698636.1481] manager: (vmnet1): new Ethernet device (/org/freedesktop/NetworkManager/Devices/3)
    Feb 09 08:50:36 andromeda.samara.com.es NetworkManager[1374]: <info>  [1549698636.3327] device (vmnet8): driver '(null)' does not support carrier detection.
    Feb 09 08:50:36 andromeda.samara.com.es NetworkManager[1374]: <info>  [1549698636.3331] device (vmnet8): driver 'unknown' does not support carrier detection.
    Feb 09 08:50:36 andromeda.samara.com.es NetworkManager[1374]: <info>  [1549698636.3359] manager: (vmnet8): new Ethernet device (/org/freedesktop/NetworkManager/Devices/4)

    so.... it is disabled but is working ?????


    Then
    Code:
    #systemctl stop NetworkManager
    #ifdown eth0
    #ifup eth0

    kills the DHCP IP and lets only the static IP.

    I dont' know where is the problem
    I know I could fix it with a quick fix (a systemctl stop NetworkManager ) in some init script, but I would like to know why is that happening.


    best regards

  7. #7

    Default Re: Network manager and wicked working at same time: two IPS for eth0

    Code:
    andromeda:/home/fernando # systemctl status wicked
    ● wicked.service - wicked managed network interfaces
       Loaded: loaded (/usr/lib/systemd/system/wicked.service; enabled; vendor preset: disabled)
       Active: active (exited) since Sat 2019-02-09 08:50:30 CET; 15h ago
     Main PID: 1376 (code=exited, status=0/SUCCESS)
        Tasks: 0 (limit: 4915)
       CGroup: /system.slice/wicked.service
    
    feb 09 08:50:24 andromeda systemd[1]: Starting wicked managed network interfaces...
    feb 09 08:50:30 andromeda wicked[1376]: lo              up
    feb 09 08:50:30 andromeda wicked[1376]: eth0            up
    feb 09 08:50:30 andromeda systemd[1]: Started wicked managed network interfaces.
    andromeda:/home/fernando #

  8. #8
    Join Date
    Jun 2008
    Location
    Auckland, NZ
    Posts
    19,716
    Blog Entries
    1

    Default Re: Network manager and wicked working at same time: two IPS for eth0

    Quote Originally Posted by fperal View Post
    No, it is not disabled. It didn't work.
    After reboot I have again a DHCP IP and

    Code:
    #systemctl status NetworkManager
    ● NetworkManager.service - Network Manager
       Loaded: loaded (/usr/lib/systemd/system/NetworkManager.service; disabled; vendor preset: disabled)
      Drop-In: /usr/lib/systemd/system/NetworkManager.service.d
               └─NetworkManager-ovs.conf
       Active: active (running) since Sat 2019-02-09 08:50:25 CET; 1min 32s ago
         Docs: man:NetworkManager(8)
     Main PID: 1374 (NetworkManager)
        Tasks: 4 (limit: 4915)
       CGroup: /system.slice/NetworkManager.service
               ├─1374 /usr/sbin/NetworkManager --no-daemon
               └─1748 /sbin/dhclient -d -q -sf /usr/lib/nm-dhcp-helper -pf /var/run/dhclient-eth0.pid -lf /var/lib/NetworkManager/dhclient-cae1a3ab-c168-3ed1-b63e-b1e25648b5ef-eth0.lease -cf /var/lib/NetworkManager/dhclient-eth0.conf eth0
    IIRC, NetworkManager can be started on demand via dbus. This might depend on the dekstop environment you're using. I don't get this behaviour with KDE. Try masking the unit like this
    Code:
    sudo systemctl mask NetworkManager
    then reboot.
    openSUSE Leap 15.0; KDE Plasma 5

  9. #9
    Join Date
    Sep 2012
    Posts
    4,848

    Default Re: Network manager and wicked working at same time: two IPS for eth0

    Quote Originally Posted by fperal View Post
    so.... it is disabled but is working ?????
    This is common misunderstanding. "Disabled" in case of systemd just means that links listed in unit [Install] section are not present. No more. It does not mean unit cannot be started by other means or as result of explicit dependencies from other units.

    Show output of "systemctl list-dependencies --reverse NetworkManager.service".

    Quote Originally Posted by deano_ferrari View Post
    IIRC, NetworkManager can be started on demand via dbus.
    While D-Bus can be configured to start anything in response to connect request to any end point, I have never seen NM being autostarted in any distribution.
    Try masking the unit like this
    Sure, sledge hammer is always an option. Why not simply remove NetworkManager then?

  10. #10

    Default Re: Network manager and wicked working at same time: two IPS for eth0

    Quote Originally Posted by deano_ferrari View Post
    IIRC, NetworkManager can be started on demand via dbus. This might depend on the dekstop environment you're using. I don't get this behaviour with KDE.
    It is happenin just booting, prior to login in kde.
    I switch to a text console as root and the system has got the DHCP IP



    Quote Originally Posted by arvidjaar View Post
    This is common misunderstanding. "Disabled" in case of systemd just means that links listed in unit [Install] section are not present. No more. It does not mean unit cannot be started by other means or as result of explicit dependencies from other units.

    Show output of "systemctl list-dependencies --reverse NetworkManager.service".
    Code:
    andromeda:/home/fernando # systemctl list-dependencies --reverse NetworkManager.service
    NetworkManager.service
    ● └─NetworkManager-wait-online.service
    andromeda:/home/fernando #





    While D-Bus can be configured to start anything in response to connect request to any end point, I have never seen NM being autostarted in any distribution.

    Sure, sledge hammer is always an option. Why not simply remove NetworkManager then?

    Code:
    
    andromeda:/home/fernando # zypper remove NetworkManager
    Loading repository data...
    Warning: No repositories defined. Operating only with the installed resolvables. Nothing can be installed.
    Reading installed packages...
    Resolving package dependencies...
    
    The following 19 packages are going to be REMOVED:
      NetworkManager NetworkManager-branding-openSUSE NetworkManager-lang NetworkManager-openconnect NetworkManager-openconnect-lang NetworkManager-openvpn NetworkManager-openvpn-lang
      NetworkManager-pptp NetworkManager-pptp-lang patterns-kde-kde patterns-kde-kde_imaging patterns-kde-kde_plasma plasma5-session plasma5-session-wayland plasma-nm5 plasma-nm5-lang
      plasma-nm5-openconnect plasma-nm5-openvpn plasma-nm5-pptp
    
    The following 3 patterns are going to be REMOVED:
      kde kde_imaging kde_plasma
    
    19 packages to remove.
    After the operation, 20,2 MiB will be freed.
    Continue? [y/n/...? shows all options] (y):
    I guess it is not an option. Am I wrong or it will involve removing kde?

Page 1 of 2 12 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •