[Bug 1874494] Re: netplan apply does not remove systemd service for wlan0 after config removed

Brian Murray brian at ubuntu.com
Thu May 7 17:45:47 UTC 2020


** Also affects: netplan.io (Ubuntu Focal)
   Importance: Undecided
       Status: New

** Changed in: netplan.io (Ubuntu Focal)
    Milestone: None => ubuntu-20.04.1

** Changed in: netplan.io (Ubuntu)
    Milestone: ubuntu-20.04.1 => ubuntu-20.06

** Changed in: netplan.io (Ubuntu Focal)
       Status: New => Triaged

** Changed in: netplan.io (Ubuntu Focal)
   Importance: Undecided => High

** Changed in: netplan.io (Ubuntu)
   Importance: Undecided => High

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to netplan.io in Ubuntu.
Matching subscriptions: foundations-bugs
https://bugs.launchpad.net/bugs/1874494

Title:
  netplan apply does not remove systemd service for wlan0 after config
  removed

Status in netplan:
  New
Status in netplan.io package in Ubuntu:
  Confirmed
Status in netplan.io source package in Focal:
  Triaged

Bug description:
  Summary
  =======

  Problem found when focal-preinstalled-server-armhf 20200423.1 image on RPI4
  netplan.io version 0.99-0ubuntu2

  When testing wifi, I confirmed it worked and was able to connect to the device with ethernet unplugged. After doing this, I removed the netplan config for wifi and ran netplan apply.
  
ubuntu at ubuntu:~$ sudo rm /etc/netplan/wifi.yaml
  ubuntu at ubuntu:~$ sudo netplan apply
  Warning: The unit file, source configuration file or drop-ins of netplan-wpa-wlan0.service ch
  anged on disk. Run 'systemctl daemon-reload' to reload units.
  Warning: The unit file, source configuration file or drop-ins of netplan-wpa-wlan0.service ch
  anged on disk. Run 'systemctl daemon-reload' to reload units.

  So I did the daemon-reload and tried again:
  ubuntu at ubuntu:~$ sudo systemctl daemon-reload
  ubuntu at ubuntu:~$ sudo netplan apply
  Failed to start netplan-wpa-wlan0.service: Unit netplan-wpa-wlan0.service not found.
  Traceback (most recent call last):
    File "/usr/sbin/netplan", line 23, in <module>
      netplan.main()
    File "/usr/share/netplan/netplan/cli/core.py", line 50, in main
      self.run_command()
    File "/usr/share/netplan/netplan/cli/utils.py", line 179, in run_command
      self.func() 
    File "/usr/share/netplan/netplan/cli/commands/apply.py", line 46, in run
      self.run_command()
    File "/usr/share/netplan/netplan/cli/utils.py", line 179, in run_command
      self.func() 
    File "/usr/share/netplan/netplan/cli/commands/apply.py", line 173, in command_apply
      utils.systemctl_networkd('start', sync=sync, extra_services=netplan_wpa)
    File "/usr/share/netplan/netplan/cli/utils.py", line 86, in systemctl_networkd
      subprocess.check_call(command)
    File "/usr/lib/python3.8/subprocess.py", line 364, in check_call
      raise CalledProcessError(retcode, cmd)
  subprocess.CalledProcessError: Command '['systemctl', 'start', '--no-block', 'systemd-networkd.service', 'netplan-wpa-wlan0.service']' returned non-zero exit status 5.

  At no point did ethernet start working, until I rebooted. systemctl
  showed that netplan-wpa-wlan0.service still existed, but was dead.
  After a reboot, that service was gone though, and ethernet worked
  fine.

  Steps to reproduce
  ==================
  1. configure wifi on rpi via netplan
  2. remove the wifi config after confirming it works
  3. run netplan apply
  (optional)
  4. run sudo systemctl daemon-reload
  5. run netplan apply again

To manage notifications about this bug go to:
https://bugs.launchpad.net/netplan/+bug/1874494/+subscriptions



More information about the foundations-bugs mailing list