%general-entities; ]> $Date$ NetworkManager-&NetworkManager-version; NetworkManager Introduction to NetworkManager NetworkManager is a set of co-operative tools that make networking simple and straightforward. Whether you use WiFi, wired, 3G, or Bluetooth, NetworkManager allows you to quickly move from one network to another: Once a network has been configured and joined once, it can be detected and re-joined automatically the next time it's available. &lfs112_checked; Make sure that you disable the systemd-networkd service or configure it not to manage the interfaces you want to manage with NetworkManager. Package Information Download (HTTP): Download (FTP): Download MD5 sum: &NetworkManager-md5sum; Download size: &NetworkManager-size; Estimated disk space required: &NetworkManager-buildsize; Estimated build time: &NetworkManager-time; NetworkManager Dependencies Required and Recommended , (client only), , , (for nmtui), , , , , , , , and (built with D-Bus support) Optional , (for the test suite), (used if is not found), , , (for examples), , , dnsmasq, firewalld, libaudit, libteam, mobile-broadband-provider-info, PPP, and RP-PPPoE User Notes: Kernel Configuration If you wish to run the tests, check that at least the following options are enabled in the kernel configuration. Those options have been determined to be necessary, but may not be sufficient. Recompile the kernel if necessary: [*] Networking support---> [CONFIG_NET] Networking options---> [*] TCP/IP networking [CONFIG_INET] <*/M> IP: tunelling [CONFIG_NET_IPIP] <*/M> IP: GRE demultiplexer [CONFIG_NET_IPGRE_DEMUX] <*/M> IP: GRE tunnels over IP [CONFIG_NET_IPGRE] <*> The IPv6 protocol ---> [CONFIG_IPV6] <*/M> IPv6: IPv6-in-IPv4 tunnel (SIT driver) [CONFIG_IPV6_SIT] <*/M> IPv6: GRE tunnel [CONFIG_IPV6_GRE] [*] IPv6: Multiple Routing Tables [CONFIG_IPV6_MULTIPLE_TABLES] [*] MPTCP: Multipath TCP [CONFIG_MPTCP] [*] MPTCP: IPv6 support for Multipath TCP [CONFIG_MPTCP_IPV6] <*/M> 802.1Q/802.1ad VLAN Support [CONFIG_VLAN_8021Q] [*] QoS and/or fair queueing ---> [CONFIG_NET_SCHED] <*/M> Stochastic Fairness Queueing (SFQ) [CONFIG_NET_SCH_SFQ] <*/M> Token Bucket Filter (TBF) [CONFIG_NET_SCH_TBF] <*/M> Fair Queue Controlled Delay AQM (FQ_CODEL) [CONFIG_NET_SCH_FQ_CODEL] <*/M> Ingress/classifier-action Qdisc [CONFIG_NET_SCH_INGRESS] Device Drivers ---> [*] Network device support ---> [CONFIG_NETDEVICES] [*] Network core driver support [CONFIG_NET_CORE] <*> Bonding driver support [CONFIG_BONDING] <*> Dummy net driver support [CONFIG_DUMMY] <*> Ethernet team driver support ---> [CONFIG_NET_TEAM] <*> MAC-VLAN support [CONFIG_MACVLAN] <*> MAC-VLAN based tap driver [CONFIG_MACVTAP] <*> IP-VLAN support [CONFIG_IPVLAN] <*> Virtual eXtensible Local Area Network (VXLAN) [CONFIG_VXLAN] <*> Virtual ethernet pair device [CONFIG_VETH] <*> Virtual Routing and Forwarding (Lite) [CONFIG_VRF] NetworkManager Installation of NetworkManager If is installed and the Qt based examples are desired, fix two meson.build files: sed -e 's/-qt4/-qt5/' \ -e 's/moc_location/host_bins/' \ -i examples/C/qt/meson.build && sed -e 's/Qt/&5/' \ -i meson.build Fix the python scripts so that they use Python 3: grep -rl '^#!.*python$' | xargs sed -i '1s/python/&3/' Install NetworkManager by running the following commands: mkdir build && cd build && CXXFLAGS+="-O2 -fPIC" \ meson --prefix=/usr \ --buildtype=release \ -Dlibaudit=no \ -Dlibpsl=false \ -Dnmtui=true \ -Dovs=false \ -Dppp=false \ -Dselinux=false \ -Dsession_tracking=elogind \ -Dmodem_manager=false \ -Dsystemdsystemunitdir=no \ -Dsystemd_journal=false \ -Dqt=false \ .. && ninja mkdir build && cd build && CXXFLAGS+="-O2 -fPIC" \ meson --prefix=/usr \ --buildtype=release \ -Dlibaudit=no \ -Dlibpsl=false \ -Dnmtui=true \ -Dovs=false \ -Dppp=false \ -Dselinux=false \ -Dqt=false \ -Dsession_tracking=systemd \ -Dmodem_manager=false \ .. && ninja An already active graphical session with a bus address is necessary to run the tests. To test the results, issue ninja test. A few tests may fail, depending on enabled kernel options. Now, as the root user: ninja install && mv -v /usr/share/doc/NetworkManager{,-&NetworkManager-version;} If you have not passed the option to meson, you can install the pregenerated manual pages with (as the &root; user): for file in $(echo ../man/*.[1578]); do section=${file##*.} && install -vdm 755 /usr/share/man/man$section install -vm 644 $file /usr/share/man/man$section/ done Still in case you have not used , the pregenerated HTML documentation can also be installed with (as the &root; user): cp -Rv ../docs/{api,libnm} /usr/share/doc/NetworkManager-&NetworkManager-version; Command Explanations CXXFLAGS="-O2 -fPIC": These compiler options are necessary to build the Qt5 based examples. : Use this switch to enable building man pages and documentation if is installed. -Dnmtui=true: This parameter enables building nmtui. -Dsystemdsystemunitdir=no and -Dsystemd_journal=false: systemd is not used for sysv init systems. -Dlibpsl=false and -Dovs=false: These switches disable building with the respective libraries. Remove if you have the needed libraries installed. -Dmodem_manager=false: This switch is required if ModemManager is not installed. Omit if you have built ModemManager and mobile-broadband-provider-info. -Dsession_tracking=elogind: This switch is used to set elogind as the default program for session tracking. -Dsession_tracking=systemd: This switch is used to set systemd-logind as the default program for session tracking. -Dsystemdsystemunitdir=/lib/systemd/system: This switch is used to set the correct installation directory for systemd units. -Dppp=false: This parameter disables PPP support in NetworkManager. -Dlibaudit=no and -Dselinux=false: libaudit and SELinux are not used in BLFS. -Dqt=false: disables the QT examples. Omit if you have QT available and wish to install the examples. Configuring NetworkManager Config Files /etc/NetworkManager/NetworkManager.conf /etc/NetworkManager/NetworkManager.conf Configuration Information For NetworkManager to work, at least a minimal configuration file must be present. Such a file is not installed with make install. Issue the following command as the root user to create a minimal NetworkManager.conf file: cat >> /etc/NetworkManager/NetworkManager.conf << "EOF" [main] plugins=keyfile EOF This file should not be modified directly by users of the system. Instead, system specific changes should be made using configuration files in the /etc/NetworkManager/conf.d directory. To allow polkit to manage authorizations, add the following configuration file: cat > /etc/NetworkManager/conf.d/polkit.conf << "EOF" [main] auth-polkit=true EOF To use something other than the built-in dhcp client (recommended if using only nmcli), use the following configuration (valid values include either dhclient or internal): cat > /etc/NetworkManager/conf.d/dhcp.conf << "EOF" [main] dhcp=dhclient EOF To prevent NetworkManager from updating the /etc/resolv.conf file, add the following configuration file: cat > /etc/NetworkManager/conf.d/no-dns-update.conf << "EOF" [main] dns=none EOF For additional configuration options, see man 5 NetworkManager.conf. To allow regular users to configure network connections, you should add them to the netdev group, and create a polkit rule that grants access. Run the following commands as the root user: groupadd -fg 86 netdev && /usr/sbin/usermod -a -G netdev <username> cat > /usr/share/polkit-1/rules.d/org.freedesktop.NetworkManager.rules << "EOF" polkit.addRule(function(action, subject) { if (action.id.indexOf("org.freedesktop.NetworkManager.") == 0 && subject.isInGroup("netdev")) { return polkit.Result.YES; } }); EOF <phrase revision="sysv">Boot Script</phrase> <phrase revision="systemd">Systemd Unit</phrase> To automatically start the NetworkManager daemon when the system is rebooted, install the /etc/rc.d/init.d/networkmanagerbootscript from the package. To start the NetworkManager daemon at boot, enable the previously installed systemd unit by running the following command as the root user: If using Network Manager to manage an interface, any previous configuration for that interface should be removed, and the interface brought down prior to starting Network Manager. NetworkManager make install-networkmanager systemctl enable NetworkManager Starting in version 1.11.2 of NetworkManager, a systemd unit named NetworkManager-wait-online.service is enabled, which is used to prevent services that require network connectivity from starting until NetworkManager establishes a connection. To disable this behavior, run the following command as the root user: systemctl disable NetworkManager-wait-online Contents Installed Programs Installed Libraries Installed Directories NetworkManager, nmcli, nm-online, nmtui, and, symlinked to nmtui: nmtui-connect, nmtui-edit, and nmtui-hostname libnm.so and several modules under /usr/lib/NetworkManager /etc/NetworkManager, /usr/include/libnm, /usr/lib/NetworkManager, /usr/share/doc/NetworkManager-&NetworkManager-version;, /usr/share/gtk-doc/html/{libnm,NetworkManager} (if the documentation is built), and /var/lib/NetworkManager Short Descriptions nmcli is a command-line tool for controlling NetworkManager and getting its status nmcli nm-online is an utility to determine whether you are online nm-online nmtui is an interactive ncurses-based user interface for nmcli nmtui nmtui-connect is an interactive ncurses-based user interface to activate/deactivate connections nmtui-connect nmtui-edit is an interactive ncurses-based user interface to edit connections nmtui-edit nmtui-hostname is an interactive ncurses-based user interface to edit the hostname nmtui-hostname NetworkManager is the network management daemon NetworkManager libnm.so contains functions used by NetworkManager libnm.so