WICKED(7)
β¨ WICKED(7) β¨ β the network management service, but make it a vibe
Hiiii bestie!! Okay so this is wicked(7) from the Miscellaneous Information Manual, and no cap, it's the manual page for the network management service. Grab a snack, we're doing this π
πΈ SYNOPSIS πΈ
#include <wicked/wicked.h>
π¦ DESCRIPTION π¦
So like, Wicked gives you a whole new experimental framework for network configuration. Experimental. As in, it's giving science-fair energy, not "this is stable" energy. Noted π
The whole idea? Replace a big chunk of the shell scripting that lives in /sbin/ifup and all its little init-script friends with a combo of:
- C code that handles most of the basic interface configuration tasks, and
- a powerful, extensible XML representation of the network configuration β¨
And why XML, you ask? Because XML can represent and manipulate complex nested configurations. That's the major motivation. It's giving "nested config realness" and honestly? Fair.
π NOTE π
At this time, Wicked does not provide a stable development API.
Like. Not stable. At all. Do with that what you will π
π DBus Services π
This implementation is built on a DBus based server plus a command line utility. Now if you already speak DBus, you know the whole concept revolves around "objects" that can have one or more "interfaces" attached to them β very object-oriented-model core of it.
And here's the thing: since we're talking about network interfaces literally everywhere in this page and in other docs, the author would very much like to avoid the term "DBus interface" as much as possible, and say "DBus APIs" instead. Thank you for coming to their TED talk π€
The wicked server is called wickedd, and it offers a whole variety of APIs to manage network interfaces, to create and delete virtual interfaces, etc. These APIs are structured in a layered fashion that matches the different layers in the network stack. For instance:
- there's an Ethernet API for accessing the link-layer properties of an Ethernet API;
- there's an API class that represents the properties of a generic kernel network device;
- and there are APIs for address configuration.
For every network interface in the system, the server creates an object and attaches the appropriate DBus APIs to it. The DBus object path is formed by concatenating /org/opensuse/Network/Interface with the interface index. And why? Because that way the object handle stays unaffected when the interface gets renamed. Iconic behaviour, honestly π
On top of wickedd itself, there are several auxiliary services that handle various dynamic address configuration and propel interface bring-up. For instance, there are daemons to handle:
- DHCP4
- DHCP6
- IPv4 link-layer autoconfiguration (aka
ipv4ll, or IP zeroconf)
...as well as a wickedd-nanny daemon that communicates interface configuration policies to wikcedd, thus driving interface bring-up. The main goal for introducing wickedd-nanny is to handle the use cases for interface hotplugging and wireless roaming. And the reason to create these anew? So they can be integrated more closely with wickedd. Synergy, babe π«Ά
π File format π
Wicked strictly separates configuration files stored somewhere in the system from the current configuration state maintained by the kernel and closely related system daemons like pppd(8) or openvpn(8).
Here's the split, and it's a clean split:
- The server only knows about the latter (the current state) β it does not parse any configuration files, and it does not maintain any state besides what is actually in effect.
- The client never probes the kernel directly to obtain the current system state. The client's job is to parse the configuration file(s) handed to it by the user, process and convert them to policies, and hand them off to
wickedd-nanny.
Then wickedd-nanny performs device configuration when policy conditions have been met. Chef's kiss π
Currently, the wicked client supports the original sysconfig ifcfg- file format and converts the data found to it's native xml format.
π Simple Ethernet Example (ifcfg-eth0)
STARTMODE="onboot" BOOTPROTO="dhcp4"
π Resulting Ethernet Configuration in Native XML
In its simplest format, an interface description consists of little more than an <interface> element specifying the interface name and the requested address configuration:
<interface>
<name>eth0</name>
<control>
<mode>boot</mode>
</control>
<ipv4:dhcp>
<enabled>true</enabled>
</ipv4:dhcp>
</interface>
Just like DHCPv4, there are elements for other address configuration modes as well, such as <ipv6:dhcp>, or <ipv4:static> β you get the idea π
For further information on the file syntax, refer to wicked-config(5).
π₯ Mode of Operation π₯
The wicked client utility supports a number of different activities, but its most important job is probably to generate policies from configuration files and initiate bring up of network interfaces. This is performed by calling wicked ifup, which takes a number of parameters to select which interfaces to bring up, and how. Want the details? Please refer to wicked(8).
For the sake of this discussion, let's assume we're asking wicked to bring up a VLAN interface. After parsing the configuration file and generating a suitable policy, wicked will do several things in preparation of bringing up the device:
- Build a hierarchy of devices depending on each other. In this example, let's assume that the VLAN device depends on the underlying interface
eth0. In order to bring up the VLAN, the Ethernet interface must be brought up as well (at least in terms of the link-layer). - Pass the policies for the specified interfaces to
wickedd-nanny.
With these steps performed, wickedd-nanny will work its way through all layers of network configuration to activate the devices. Let's go layer by layer, bestie π§
π οΈ Device creation
Since the VLAN interface is a virtual interface which does not exist yet, it has to be created first. wickedd-nanny does this by calling a device factory service for VLAN devices. Boom, it exists π
π οΈ Link-layer configuration
Next, it will apply any link-layer configurations specified. For Ethernet interfaces, this could include any ethtool settings, or a change of the MAC address.
π οΈ Network protocol selection
This step is used to change the per-device settings of IPv4 and IPv6, such as packet forwarding. This steps also takes care of disabling IPv6 on the device, if requested.
π οΈ Firewall
This step will bring up the firewall. π₯ (literally)
π οΈ Link layer configuration and authentication
These steps will take care of bringing up the link layer. In the case of an Ethernet device, this will wait for the link layer negotiation to complete. In the case of an authenticated link layer, such as 802.11 WiFi or 802.1x Ethernet authentication, care would be taken to perform the required authentication steps.
In our example, wickedd-nanny directs wickedd to first bring up eth0 and wait for its link layer negotiation to complete. The configuration of the VLAN device is not allowed to proceed until the subordinate device is up. Once that is the case, wickedd would also bring up the VLAN device.
And as we've reached the desired state for the eth0 device with this step, no further action is taken. Slay, we're done here β¨
π οΈ Address Configuration
Finally, wickedd would configure addresses for all requested modes. In the given example, it would just assign the given static addresses. If we had also requested say DHCPv6, it would start the DHCPv6 protocol on this device and wait for it to come back with an address lease.
Note that in the wicked universe, address assignment should happen through wickedd so that it can track which addresses are active, and have been assigned through which protocol. This prevents different address configuration mechanisms to step on each other's toes.
No toe-stepping in this house π ββοΈ
π SEE ALSO π
wickedd(8), wicked(8), wicked(7), wicked-config(5).
β COPYRIGHT β
Copyright (C) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany.
π BUGS π
Please report bugs as described at <https://bugs.opensuse.org>
π AUTHORS π
Olaf Kirch
And that's the whole page, bestie β this one's from the WICKED(7) manual page and it's dated 16 July 2012. Go configure something iconic πβ¨π¦
π¦ where this page comes from
- fedora 43: wicked-devel 0.6.77-2.fc43 Β· GPL-2.0-or-later
- fedora 43: wicked-devel 0.6.77-2.fc43 Β· GPL-2.0-or-later
- fedora 44: wicked-devel 0.6.77-3.fc44 Β· GPL-2.0-or-later
- fedora 44: wicked-devel 0.6.77-3.fc44 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms