]> git.ipfire.org Git - thirdparty/systemd.git/commit
network: show online state in networkctl status output
authorAlvin Šipraga <alsi@bang-olufsen.dk>
Tue, 6 Apr 2021 13:40:46 +0000 (15:40 +0200)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Wed, 19 May 2021 01:34:06 +0000 (10:34 +0900)
commit4a481ec4ae2137db1b294c8ff2ce7d2d1ebdc37e
tree7277b359614bee2623167f4917b84623173381ec
parent553022c4af6d50cc9439867b3dae3b2f751b004a
network: show online state in networkctl status output

In case the link online state is invalid, networkctl will print
"unknown", which is sufficiently neutral. The same goes for the overall
manager online state if there are no managed links, or if
RequiredForOnline=no for all managed links.

Example output:

  $ networkctl status
  ●        State: routable
    Online state: partial
         Address: 172.22.0.130 on wlan0
  ...

  $ networkctl status wlan0
  ● 3: wlan0
               Link File: /lib/systemd/network/99-default.link
            Network File: /etc/systemd/network/50-wlan0.network
                    Type: wlan
                   State: routable (configured)
            Online state: online
  ...
src/network/networkctl.c