[e33ddee] | 1 | <?xml version="1.0" encoding="ISO-8859-1"?>
|
---|
| 2 | <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
|
---|
| 3 | "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
|
---|
| 4 | <!ENTITY % general-entities SYSTEM "../../general.ent">
|
---|
| 5 | %general-entities;
|
---|
| 6 |
|
---|
[0d7900a] | 7 | <!ENTITY NetworkManager-download-http
|
---|
[eae0d6d1] | 8 | "&gnome-download-http;/NetworkManager/&NetworkManager-minor;/NetworkManager-&NetworkManager-version;.tar.xz">
|
---|
[0d7900a] | 9 | <!ENTITY NetworkManager-download-ftp
|
---|
[eae0d6d1] | 10 | "&gnome-download-ftp;/NetworkManager/&NetworkManager-minor;/NetworkManager-&NetworkManager-version;.tar.xz">
|
---|
[c975b7c] | 11 | <!ENTITY NetworkManager-md5sum "a6bd86438c5448cc8cec6771f9a92a40">
|
---|
| 12 | <!ENTITY NetworkManager-size "5.1 MB">
|
---|
[2b21b49f] | 13 | <!ENTITY NetworkManager-buildsize "917 MB (with tests)">
|
---|
[21d18f7e] | 14 | <!ENTITY NetworkManager-time "0.9 SBU (with tests, using parallelism=4)">
|
---|
[e33ddee] | 15 | ]>
|
---|
| 16 |
|
---|
| 17 | <sect1 id="NetworkManager" xreflabel="NetworkManager-&NetworkManager-version;">
|
---|
| 18 | <?dbhtml filename="networkmanager.html"?>
|
---|
| 19 |
|
---|
| 20 | <sect1info>
|
---|
| 21 | <date>$Date$</date>
|
---|
[28370fe] | 22 | </sect1info>
|
---|
[e33ddee] | 23 |
|
---|
| 24 | <title>NetworkManager-&NetworkManager-version;</title>
|
---|
| 25 |
|
---|
| 26 | <indexterm zone="NetworkManager">
|
---|
| 27 | <primary sortas="a-NetworkManager">NetworkManager</primary>
|
---|
| 28 | </indexterm>
|
---|
| 29 |
|
---|
| 30 | <sect2 role="package">
|
---|
| 31 | <title>Introduction to NetworkManager</title>
|
---|
| 32 |
|
---|
[7ded7e3] | 33 | <para>
|
---|
| 34 | <application>NetworkManager</application> is a set of co-operative
|
---|
[e130fead] | 35 | tools that make networking simple and straightforward. Whether you use WiFi,
|
---|
[8df33ae3] | 36 | wired, 3G, or Bluetooth, NetworkManager allows you to quickly move from
|
---|
| 37 | one network to another: Once a network has been configured and joined
|
---|
| 38 | once, it can be detected and re-joined automatically the next time it's
|
---|
| 39 | available.
|
---|
[7ded7e3] | 40 | </para>
|
---|
[e33ddee] | 41 |
|
---|
[2b21b49f] | 42 | &lfs101_checked;
|
---|
[e33ddee] | 43 |
|
---|
[cec6657e] | 44 | <note revision="systemd">
|
---|
| 45 | <para>
|
---|
| 46 | Make sure that you disable the <command>systemd-networkd</command>
|
---|
| 47 | service or configure it not to manage the interfaces you want to manage
|
---|
| 48 | with <application>NetworkManager</application>.
|
---|
| 49 | </para>
|
---|
| 50 | </note>
|
---|
| 51 |
|
---|
[e33ddee] | 52 | <bridgehead renderas="sect3">Package Information</bridgehead>
|
---|
| 53 | <itemizedlist spacing="compact">
|
---|
| 54 | <listitem>
|
---|
[7ded7e3] | 55 | <para>
|
---|
| 56 | Download (HTTP): <ulink url="&NetworkManager-download-http;"/>
|
---|
| 57 | </para>
|
---|
[e33ddee] | 58 | </listitem>
|
---|
| 59 | <listitem>
|
---|
[7ded7e3] | 60 | <para>
|
---|
| 61 | Download (FTP): <ulink url="&NetworkManager-download-ftp;"/>
|
---|
| 62 | </para>
|
---|
[e33ddee] | 63 | </listitem>
|
---|
| 64 | <listitem>
|
---|
[7ded7e3] | 65 | <para>
|
---|
| 66 | Download MD5 sum: &NetworkManager-md5sum;
|
---|
| 67 | </para>
|
---|
[e33ddee] | 68 | </listitem>
|
---|
| 69 | <listitem>
|
---|
[7ded7e3] | 70 | <para>
|
---|
| 71 | Download size: &NetworkManager-size;
|
---|
| 72 | </para>
|
---|
[e33ddee] | 73 | </listitem>
|
---|
| 74 | <listitem>
|
---|
[7ded7e3] | 75 | <para>
|
---|
| 76 | Estimated disk space required: &NetworkManager-buildsize;
|
---|
| 77 | </para>
|
---|
[e33ddee] | 78 | </listitem>
|
---|
| 79 | <listitem>
|
---|
[7ded7e3] | 80 | <para>
|
---|
| 81 | Estimated build time: &NetworkManager-time;
|
---|
| 82 | </para>
|
---|
[e33ddee] | 83 | </listitem>
|
---|
| 84 | </itemizedlist>
|
---|
| 85 |
|
---|
| 86 | <bridgehead renderas="sect3">NetworkManager Dependencies</bridgehead>
|
---|
| 87 |
|
---|
| 88 | <bridgehead renderas="sect4">Required</bridgehead>
|
---|
[d497e89] | 89 | <para role="required">
|
---|
[7be78b9a] | 90 | <xref linkend="jansson"/> and
|
---|
[d267a13] | 91 | <xref linkend="libndp"/>
|
---|
[d497e89] | 92 | </para>
|
---|
| 93 |
|
---|
| 94 | <bridgehead renderas="sect4">Recommended</bridgehead>
|
---|
| 95 | <para role="recommended">
|
---|
[c4ae27ab] | 96 | <xref linkend="curl"/>,
|
---|
[24627ba] | 97 | <!--<xref linkend="dhcpcd"/> or
|
---|
| 98 | DHCPCD support is known to be broken with dhcpcd-9 -->
|
---|
[cac7f93] | 99 | <xref role="nodep" linkend="dhcp"/> (client only),
|
---|
[4b3c4b2] | 100 | <xref linkend="gobject-introspection"/>,
|
---|
[b7d1d2b] | 101 | <xref linkend="iptables"/>,
|
---|
[696fed8] | 102 | <xref linkend="newt"/> (for <command>nmtui</command>),
|
---|
[d267a13] | 103 | <xref linkend="nss"/>,
|
---|
[6e1616e2] | 104 | <xref linkend="polkit"/>,
|
---|
[b528d0f4] | 105 | <xref linkend="pygobject3"/>,
|
---|
[51dfb3e] | 106 | <phrase revision="sysv"><xref linkend="elogind"/>,</phrase>
|
---|
[cec6657e] | 107 | <phrase revision="systemd"><xref linkend="systemd"/>,</phrase>
|
---|
[f3429309] | 108 | <xref linkend="upower"/>,
|
---|
[626bb04] | 109 | <xref linkend="vala"/>, and
|
---|
| 110 | <xref linkend="wpa_supplicant"/> (built with D-Bus support),
|
---|
[d497e89] | 111 | </para>
|
---|
[e33ddee] | 112 |
|
---|
[d0880dfa] | 113 | <bridgehead renderas="sect4">Optional</bridgehead>
|
---|
[d497e89] | 114 | <para role="optional">
|
---|
[d4f4107] | 115 | <xref linkend="bluez"/>,
|
---|
[e64cabd] | 116 | <xref linkend="dbus-python"/> (for the test suite),
|
---|
[4a9054a8] | 117 | <!-- <xref linkend="firewalld"/> (For whenever firewalld is reintroduced) -->
|
---|
[d267a13] | 118 | <xref linkend="gnutls"/> (used if <xref linkend="nss"/> is not found),
|
---|
[d497e89] | 119 | <xref linkend="gtk-doc"/>,
|
---|
[1ad3510e] | 120 | <xref linkend="libpsl"/>,
|
---|
[e4d2b8d] | 121 | <xref linkend="qt5"/> (for examples),
|
---|
[7d645679] | 122 | <xref linkend="ModemManager"/>,
|
---|
[acb3e9f] | 123 | <xref linkend="valgrind"/>,
|
---|
[f77c63d0] | 124 | <ulink url="http://www.thekelleys.org.uk/dnsmasq/doc.html">dnsmasq</ulink>,
|
---|
[365c6fb] | 125 | <ulink url="https://firewalld.org/">firewalld</ulink>,
|
---|
[262a108] | 126 | <ulink url="https://github.com/Distrotech/libaudit">libaudit</ulink>,
|
---|
[4f5369a] | 127 | <ulink url="https://github.com/jpirko/libteam">libteam</ulink>,
|
---|
[01701da9] | 128 | <ulink url="&gnome-download-http;/mobile-broadband-provider-info/">mobile-broadband-provider-info</ulink>,
|
---|
[cec6657e] | 129 | <ulink url="https://www.samba.org/ftp/ppp/">PPP</ulink>, and
|
---|
[e130fead] | 130 | <ulink url="https://dianne.skoll.ca/projects/rp-pppoe/">RP-PPPoE</ulink>
|
---|
[d497e89] | 131 | </para>
|
---|
[d0880dfa] | 132 |
|
---|
[e33ddee] | 133 | <para condition="html" role="usernotes">User Notes:
|
---|
[7ded7e3] | 134 | <ulink url="&blfs-wiki;/NetworkManager"/>
|
---|
| 135 | </para>
|
---|
[e33ddee] | 136 | </sect2>
|
---|
| 137 |
|
---|
[13b116c] | 138 | <sect2 role="kernel" id="NetworkManager-kernel">
|
---|
| 139 | <title>Kernel Configuration</title>
|
---|
| 140 |
|
---|
| 141 | <para>
|
---|
| 142 | If you wish to run the tests, enable the following options in the
|
---|
| 143 | kernel configuration and recompile the kernel if necessary:
|
---|
| 144 | </para>
|
---|
| 145 |
|
---|
| 146 | <!-- Ethernet Teaming support is potentially optional, but I didn't
|
---|
| 147 | run the tests again to test that. It was needed to convince one of
|
---|
| 148 | the Linux Platform tests to move farther along because otherwise
|
---|
| 149 | RTNETLINK would respond with an Error 95 - unknown device type.
|
---|
| 150 | This would cause the test to fail early on in the process. -->
|
---|
| 151 |
|
---|
| 152 | <screen><literal>Device Drivers --->
|
---|
| 153 | [*] Network device support [CONFIG_NETDEVICES] --->
|
---|
| 154 | [*] Bonding driver support [CONFIG_BONDING]
|
---|
| 155 | [*] Dummy net driver support [CONFIG_DUMMY]
|
---|
| 156 | [*] Ethernet team driver support [CONFIG_NET_TEAM]</literal></screen>
|
---|
| 157 |
|
---|
| 158 | <indexterm zone="NetworkManager NetworkManager-kernel">
|
---|
| 159 | <primary sortas="d-NetworkManager">NetworkManager</primary>
|
---|
| 160 | </indexterm>
|
---|
| 161 | </sect2>
|
---|
| 162 |
|
---|
[e33ddee] | 163 | <sect2 role="installation">
|
---|
| 164 | <title>Installation of NetworkManager</title>
|
---|
| 165 |
|
---|
[7c56ece] | 166 | <para>
|
---|
| 167 | If <xref linkend="qt5"/> is installed and the Qt based
|
---|
| 168 | examples are desired, fix two meson.build files:
|
---|
| 169 | </para>
|
---|
[e4d2b8d] | 170 |
|
---|
[e022b07] | 171 | <screen><userinput>sed -e 's/-qt4/-qt5/' \
|
---|
[e4d2b8d] | 172 | -e 's/moc_location/host_bins/' \
|
---|
[6573fc3] | 173 | -i examples/C/qt/meson.build &&
|
---|
[40d141f] | 174 |
|
---|
[6573fc3] | 175 | sed -e 's/Qt/&5/' \
|
---|
| 176 | -i meson.build</userinput></screen>
|
---|
[d267a13] | 177 |
|
---|
| 178 | <para>
|
---|
| 179 | Fix a missing meson.build file for initrd hooks (not used in BLFS):
|
---|
| 180 | </para>
|
---|
| 181 |
|
---|
[4da49b9] | 182 | <screen><userinput>sed '/initrd/d' -i src/core/meson.build</userinput></screen>
|
---|
[e4d2b8d] | 183 |
|
---|
[fdbfe39] | 184 | <para>
|
---|
| 185 | Fix the python scripts so that they use <application>Python
|
---|
| 186 | 3</application>:
|
---|
| 187 | </para>
|
---|
| 188 |
|
---|
| 189 | <screen><userinput>grep -rl '^#!.*python$' | xargs sed -i '1s/python/&3/'</userinput></screen>
|
---|
| 190 |
|
---|
[3b339ddc] | 191 | <para>
|
---|
| 192 | Fix a security vulnerability in the matching system:
|
---|
| 193 | </para>
|
---|
| 194 |
|
---|
| 195 | <screen><userinput remap="pre">sed -i 's/str, 0/str ?: "", 0/' src/core/nm-core-utils.c</userinput></screen>
|
---|
| 196 |
|
---|
[7ded7e3] | 197 | <para>
|
---|
[7c4f32b] | 198 | Install <application>NetworkManager</application> by running the
|
---|
| 199 | following commands:
|
---|
[7ded7e3] | 200 | </para>
|
---|
[e33ddee] | 201 |
|
---|
[d267a13] | 202 | <screen revision="sysv"><userinput>mkdir build &&
|
---|
[7d07abd] | 203 | cd build &&
|
---|
[d267a13] | 204 |
|
---|
| 205 | CXXFLAGS+="-O2 -fPIC" \
|
---|
| 206 | meson --prefix /usr \
|
---|
| 207 | -Dlibaudit=no \
|
---|
[39100371] | 208 | -Dlibpsl=false \
|
---|
| 209 | -Dnmtui=true \
|
---|
| 210 | -Dovs=false \
|
---|
| 211 | -Dppp=false \
|
---|
[d267a13] | 212 | -Dselinux=false \
|
---|
| 213 | -Dudev_dir=/lib/udev \
|
---|
[51dfb3e] | 214 | -Dsession_tracking=elogind \
|
---|
[39100371] | 215 | -Dmodem_manager=false \
|
---|
[d267a13] | 216 | -Dsystemdsystemunitdir=no \
|
---|
| 217 | -Dsystemd_journal=false \
|
---|
| 218 | -Dqt=false \
|
---|
| 219 | .. &&
|
---|
| 220 | ninja</userinput></screen>
|
---|
| 221 |
|
---|
| 222 | <screen revision="systemd"><userinput>mkdir build &&
|
---|
[7d07abd] | 223 | cd build &&
|
---|
[d267a13] | 224 |
|
---|
| 225 | CXXFLAGS+="-O2 -fPIC" \
|
---|
| 226 | meson --prefix /usr \
|
---|
| 227 | -Dlibaudit=no \
|
---|
[39100371] | 228 | -Dlibpsl=false \
|
---|
| 229 | -Dnmtui=true \
|
---|
| 230 | -Dovs=false \
|
---|
| 231 | -Dppp=false \
|
---|
[d267a13] | 232 | -Dselinux=false \
|
---|
| 233 | -Dqt=false \
|
---|
| 234 | -Dudev_dir=/lib/udev \
|
---|
| 235 | -Dsession_tracking=systemd \
|
---|
[39100371] | 236 | -Dmodem_manager=false \
|
---|
[d267a13] | 237 | -Dsystemdsystemunitdir=/lib/systemd/system \
|
---|
| 238 | .. &&
|
---|
| 239 | ninja</userinput></screen>
|
---|
[cec6657e] | 240 |
|
---|
[7ded7e3] | 241 | <para>
|
---|
[00581ba] | 242 | An already active graphical session
|
---|
| 243 | with a bus address is necessary to run the tests. To test the results,
|
---|
[13b116c] | 244 | as the root user, <!-- needs the "ip" command -->
|
---|
[2b21b49f] | 245 | issue: <command>ninja test</command>. Five tests,
|
---|
| 246 | <!--<filename>test-l3cfg</filename>,-->
|
---|
[05a433b] | 247 | <filename>devices/test-acd</filename>,
|
---|
[4a9054a8] | 248 | <filename>platform/test-tc-linux</filename>,
|
---|
[05a433b] | 249 | <filename>platform/test-route-linux</filename>,
|
---|
| 250 | <filename>platform/test-link-linux</filename>, and
|
---|
| 251 | <filename>platform/test-cleanup-linux</filename>, are known to fail.
|
---|
[7ded7e3] | 252 | </para>
|
---|
[e33ddee] | 253 |
|
---|
[7ded7e3] | 254 | <para>
|
---|
| 255 | Now, as the <systemitem class="username">root</systemitem> user:
|
---|
| 256 | </para>
|
---|
[e33ddee] | 257 |
|
---|
[d267a13] | 258 | <screen role="root"><userinput>ninja install &&
|
---|
| 259 | mv -v /usr/share/doc/NetworkManager{,-&NetworkManager-version;}</userinput></screen>
|
---|
[e33ddee] | 260 |
|
---|
| 261 | </sect2>
|
---|
| 262 |
|
---|
| 263 | <sect2 role="commands">
|
---|
| 264 | <title>Command Explanations</title>
|
---|
| 265 |
|
---|
[e4d2b8d] | 266 | <para>
|
---|
| 267 | <envar>CXXFLAGS="-O2 -fPIC"</envar>: These compiler options are
|
---|
| 268 | necessary to build the Qt5 based examples.
|
---|
| 269 | </para>
|
---|
| 270 |
|
---|
[e64cabd] | 271 | <para>
|
---|
[fdbfe39] | 272 | <option>-Ddocs=true</option>: Use this switch to enable building
|
---|
[39100371] | 273 | man pages and documentation if <xref linkend="gtk-doc"/> is installed.
|
---|
[e64cabd] | 274 | </para>
|
---|
| 275 |
|
---|
[7ded7e3] | 276 | <para>
|
---|
[d267a13] | 277 | <parameter>-Dnmtui=true</parameter>: This parameter enables building
|
---|
[acb3e9f] | 278 | <command>nmtui</command>.
|
---|
| 279 | </para>
|
---|
| 280 |
|
---|
[d267a13] | 281 | <para revision="sysv">
|
---|
[51dfb3e] | 282 | <parameter>-Dsystemdsystemunitdir=no</parameter> and
|
---|
[d267a13] | 283 | <parameter>-Dsystemd_journal=false</parameter>: systemd is not
|
---|
| 284 | used for sysv init systems.
|
---|
| 285 | </para>
|
---|
| 286 |
|
---|
[39100371] | 287 | <para>
|
---|
[21d18f7e] | 288 | <!--<parameter>-Djson_validation=false</parameter>, no longer recognized -->
|
---|
| 289 | <parameter>-Dlibpsl=false</parameter> and
|
---|
[e130fead] | 290 | <parameter>-Dovs=false</parameter>: These switches disable building with the
|
---|
[39100371] | 291 | respective libraries. Remove if you have the needed libraries installed.
|
---|
| 292 | </para>
|
---|
[52c95143] | 293 |
|
---|
| 294 | <!--
|
---|
[39100371] | 295 | <para>
|
---|
[f759a25] | 296 | <parameter>-Dlibpsl=false</parameter>: This switch is required if
|
---|
| 297 | <application>libpsl</application> is not installed. Omit this switch if
|
---|
| 298 | you have built <application>libpsl</application>.
|
---|
| 299 | </para>
|
---|
[52c95143] | 300 | -->
|
---|
[f759a25] | 301 |
|
---|
| 302 | <para>
|
---|
[39100371] | 303 | <parameter>-Dmodem_manager=false</parameter>: This switch is requried if
|
---|
| 304 | <application>ModemManager</application> is not installed. Omit if you
|
---|
[a406810] | 305 | have built <application>ModemManager</application> and
|
---|
| 306 | <application>mobile-broadband-provider-info</application>.
|
---|
[39100371] | 307 | </para>
|
---|
| 308 |
|
---|
[51dfb3e] | 309 | <para revision="sysv">
|
---|
| 310 | <parameter>-Dsession_tracking=elogind</parameter>: This switch
|
---|
| 311 | is used to set <command>elogind</command> as the default
|
---|
| 312 | program for session tracking.
|
---|
| 313 | </para>
|
---|
| 314 |
|
---|
[cec6657e] | 315 | <para revision="systemd">
|
---|
[d267a13] | 316 | <parameter>-Dsession_tracking=systemd</parameter>: This switch
|
---|
[cec6657e] | 317 | is used to set <command>systemd-logind</command> as the default
|
---|
| 318 | program for session tracking.
|
---|
| 319 | </para>
|
---|
| 320 |
|
---|
| 321 | <para revision="systemd">
|
---|
[d267a13] | 322 | <parameter>-Dsystemdsystemunitdir=/lib/systemd/system</parameter>:
|
---|
[cec6657e] | 323 | This switch is used to set the correct installation directory for
|
---|
| 324 | systemd units.
|
---|
| 325 | </para>
|
---|
| 326 |
|
---|
[acb3e9f] | 327 | <para>
|
---|
[d267a13] | 328 | <parameter>-Dppp=false</parameter>: This parameter disables
|
---|
[6e1616e2] | 329 | <application>PPP</application> support in
|
---|
| 330 | <application>NetworkManager</application>.
|
---|
[7ded7e3] | 331 | </para>
|
---|
[e33ddee] | 332 |
|
---|
[8c7390c] | 333 | <para>
|
---|
[d267a13] | 334 | <parameter>-Dlibaudit=no</parameter> and
|
---|
| 335 | <parameter>-Dselinux=false</parameter>: libaudit and SELinux are not used
|
---|
| 336 | in BLFS.
|
---|
[d6e164b] | 337 | </para>
|
---|
[e33ddee] | 338 |
|
---|
[b528d0f4] | 339 | <para>
|
---|
[d267a13] | 340 | <parameter>-Dqt=false</parameter>: disables the
|
---|
| 341 | <application>QT</application> examples. Omit if you have
|
---|
| 342 | <application>QT</application> available and wish to install the examples.
|
---|
[b528d0f4] | 343 | </para>
|
---|
| 344 |
|
---|
[e33ddee] | 345 | </sect2>
|
---|
| 346 |
|
---|
[d497e89] | 347 | <sect2 role="configuration">
|
---|
| 348 | <title>Configuring NetworkManager</title>
|
---|
| 349 |
|
---|
| 350 | <sect3 id="NetworkManager-config">
|
---|
| 351 | <title>Config Files</title>
|
---|
| 352 | <para>
|
---|
| 353 | <filename>/etc/NetworkManager/NetworkManager.conf</filename>
|
---|
| 354 | </para>
|
---|
| 355 |
|
---|
| 356 | <indexterm zone="NetworkManager NetworkManager-config">
|
---|
| 357 | <primary
|
---|
| 358 | sortas="e-etc-NetworkManager-NetworkManager.conf">
|
---|
| 359 | /etc/NetworkManager/NetworkManager.conf</primary>
|
---|
| 360 | </indexterm>
|
---|
| 361 |
|
---|
| 362 | </sect3>
|
---|
| 363 |
|
---|
| 364 | <sect3><title>Configuration Information</title>
|
---|
| 365 |
|
---|
| 366 | <para>
|
---|
| 367 | For <application>NetworkManager</application> to work, at least
|
---|
[21d18f7e] | 368 | a minimal configuration file must be present. Such a file is not
|
---|
[8df33ae3] | 369 | installed with <command>make install</command>. Issue the following
|
---|
| 370 | command as the <systemitem class="username">root</systemitem> user to
|
---|
[21d18f7e] | 371 | create a minimal <filename>NetworkManager.conf</filename> file:
|
---|
[d497e89] | 372 | </para>
|
---|
| 373 |
|
---|
| 374 | <screen role="root"><userinput>cat >> /etc/NetworkManager/NetworkManager.conf << "EOF"
|
---|
| 375 | <literal>[main]
|
---|
| 376 | plugins=keyfile</literal>
|
---|
| 377 | EOF</userinput></screen>
|
---|
| 378 |
|
---|
| 379 | <para>
|
---|
[7fd06b0] | 380 | This file should not be modified directly by users of the system.
|
---|
| 381 | Instead, system specific changes should be made using configuration
|
---|
| 382 | files in the
|
---|
| 383 | <filename class="directory">/etc/NetworkManager/conf.d</filename>
|
---|
[21d18f7e] | 384 | directory.
|
---|
[7fd06b0] | 385 | </para>
|
---|
| 386 |
|
---|
| 387 | <para>
|
---|
| 388 | To allow polkit to manage authorizations, add the following
|
---|
| 389 | configuration file:
|
---|
| 390 | </para>
|
---|
| 391 |
|
---|
| 392 | <screen role="root"><userinput>cat > /etc/NetworkManager/conf.d/polkit.conf << "EOF"
|
---|
| 393 | <literal>[main]
|
---|
| 394 | auth-polkit=true</literal>
|
---|
| 395 | EOF</userinput></screen>
|
---|
| 396 |
|
---|
| 397 | <para>
|
---|
| 398 | To use something other than the built-in dhcp client (recommended if
|
---|
| 399 | using only <command>nmcli</command>), use the following configuration
|
---|
[24627ba] | 400 | (valid values include either dhclient <!--dhcpcd --> or internal):
|
---|
[7fd06b0] | 401 | </para>
|
---|
| 402 |
|
---|
| 403 | <screen role="nodump"><userinput>cat > /etc/NetworkManager/conf.d/dhcp.conf << "EOF"
|
---|
| 404 | <literal>[main]
|
---|
| 405 | dhcp=</literal><replaceable>dhclient</replaceable>
|
---|
| 406 | EOF</userinput></screen>
|
---|
| 407 |
|
---|
| 408 | <para>
|
---|
| 409 | To prevent <application>NetworkManager</application> from updating the
|
---|
| 410 | <filename>/etc/resolv.conf</filename> file, add the following
|
---|
| 411 | configuration file:
|
---|
| 412 | </para>
|
---|
| 413 |
|
---|
| 414 | <screen role="nodump"><userinput>cat > /etc/NetworkManager/conf.d/no-dns-update.conf << "EOF"
|
---|
| 415 | <literal>[main]
|
---|
| 416 | dns=none</literal>
|
---|
| 417 | EOF</userinput></screen>
|
---|
| 418 |
|
---|
| 419 | <para>
|
---|
| 420 | For additional configuation options, see
|
---|
| 421 | <command>man 5 NetworkManager.conf</command>.
|
---|
[0d7900a] | 422 | </para>
|
---|
[d497e89] | 423 |
|
---|
[8df33ae3] | 424 | <para>
|
---|
[21d18f7e] | 425 | To allow regular users to configure network connections,
|
---|
[8df33ae3] | 426 | you should add them to the
|
---|
| 427 | <systemitem class="groupname">netdev</systemitem>
|
---|
| 428 | group, and create a <application>polkit</application> rule that grants
|
---|
| 429 | access. Run the following commands as the
|
---|
| 430 | <systemitem class="username">root</systemitem> user:
|
---|
| 431 | </para>
|
---|
| 432 |
|
---|
[a581662] | 433 | <screen role="root"><userinput>groupadd -fg 86 netdev &&
|
---|
[b88584a] | 434 | /usr/sbin/usermod -a -G netdev <replaceable><username></replaceable>
|
---|
[8df33ae3] | 435 |
|
---|
| 436 | cat > /usr/share/polkit-1/rules.d/org.freedesktop.NetworkManager.rules << "EOF"
|
---|
| 437 | <literal>polkit.addRule(function(action, subject) {
|
---|
| 438 | if (action.id.indexOf("org.freedesktop.NetworkManager.") == 0 && subject.isInGroup("netdev")) {
|
---|
| 439 | return polkit.Result.YES;
|
---|
| 440 | }
|
---|
| 441 | });</literal>
|
---|
| 442 | EOF</userinput></screen>
|
---|
| 443 |
|
---|
[d497e89] | 444 | </sect3>
|
---|
| 445 |
|
---|
| 446 | <sect3 id="NetworkManager-init">
|
---|
[cec6657e] | 447 | <title><phrase revision="sysv">Boot Script</phrase>
|
---|
| 448 | <phrase revision="systemd">Systemd Unit</phrase></title>
|
---|
| 449 |
|
---|
| 450 | <para revision="sysv">
|
---|
| 451 | To automatically start the <command>NetworkManager</command> daemon
|
---|
| 452 | when the system is rebooted, install the
|
---|
| 453 | <filename>/etc/rc.d/init.d/networkmanager</filename>bootscript from the
|
---|
| 454 | <xref linkend="bootscripts"/> package.
|
---|
| 455 | </para>
|
---|
[d497e89] | 456 |
|
---|
[cec6657e] | 457 | <para revision="systemd">
|
---|
| 458 | To start the <command>NetworkManager</command> daemon at boot, enable
|
---|
| 459 | the previously installed systemd unit by running the following command
|
---|
| 460 | as the <systemitem class="username">root</systemitem> user:
|
---|
[d497e89] | 461 | </para>
|
---|
| 462 |
|
---|
[8df33ae3] | 463 | <note>
|
---|
| 464 | <para>
|
---|
| 465 | If using <application>Network Manager</application> to manage
|
---|
| 466 | an interface, any previous configuration for that interface should be
|
---|
| 467 | removed, and the interface brought down prior to starting
|
---|
| 468 | <application>Network Manager</application>.
|
---|
| 469 | </para>
|
---|
| 470 | </note>
|
---|
| 471 |
|
---|
[d497e89] | 472 | <indexterm zone="NetworkManager NetworkManager-init">
|
---|
| 473 | <primary sortas="f-NetworkManager">NetworkManager</primary>
|
---|
| 474 | </indexterm>
|
---|
| 475 |
|
---|
[cec6657e] | 476 | <screen role="root" revision="sysv"><userinput>make install-networkmanager</userinput></screen>
|
---|
| 477 |
|
---|
| 478 | <screen role="root" revision="systemd"><userinput>systemctl enable NetworkManager</userinput></screen>
|
---|
[e2a1442] | 479 | <!-- The below instruction is obsolete. NetworkManager-wait-online is now
|
---|
| 480 | enabled by default when enabling NetworkManager. -->
|
---|
| 481 | <!--
|
---|
[cec6657e] | 482 | <para revision="systemd">
|
---|
| 483 | <application>NetworkManager</application> also ships a systemd unit
|
---|
| 484 | called <filename>NetworkManager-wait-online.service</filename> which
|
---|
| 485 | can be used to prevent services that require network connectivity
|
---|
| 486 | from starting until <application>NetworkManager</application> has
|
---|
| 487 | established the connection. To enable it, run the following command
|
---|
| 488 | as the <systemitem class="username">root</systemitem> user:
|
---|
| 489 | </para>
|
---|
| 490 |
|
---|
| 491 | <screen role="root" revision="systemd"><userinput>systemctl enable NetworkManager-wait-online</userinput></screen>
|
---|
[e2a1442] | 492 | -->
|
---|
| 493 | <!-- As such, let's now provide instructions on how to disable that
|
---|
| 494 | behavior, for those who wish to do so. -->
|
---|
| 495 | <para revision="systemd">
|
---|
| 496 | Starting in version 1.11.2 of <application>NetworkManager</application>,
|
---|
| 497 | a systemd unit named <filename>NetworkManager-wait-online.service</filename>
|
---|
| 498 | is enabled, which is used to prevent services that require network
|
---|
| 499 | connectivity from starting until <application>NetworkManager</application>
|
---|
| 500 | establishes a connection. To disable this behavior, run the following
|
---|
| 501 | command as the <systemitem class="username">root</systemitem> user:
|
---|
| 502 | </para>
|
---|
| 503 |
|
---|
| 504 | <screen role="root" revision="systemd"><userinput>systemctl disable NetworkManager-wait-online</userinput></screen>
|
---|
[2cd1071] | 505 |
|
---|
[d497e89] | 506 | </sect3>
|
---|
| 507 |
|
---|
| 508 | </sect2>
|
---|
| 509 |
|
---|
[e33ddee] | 510 | <sect2 role="content">
|
---|
| 511 | <title>Contents</title>
|
---|
| 512 |
|
---|
| 513 | <segmentedlist>
|
---|
| 514 | <segtitle>Installed Programs</segtitle>
|
---|
| 515 | <segtitle>Installed Libraries</segtitle>
|
---|
| 516 | <segtitle>Installed Directories</segtitle>
|
---|
| 517 |
|
---|
| 518 | <seglistitem>
|
---|
[d497e89] | 519 | <seg>
|
---|
[8c7390c] | 520 | NetworkManager, nmcli, nm-online, nmtui, and, symlinked to nmtui:
|
---|
| 521 | nmtui-connect, nmtui-edit, and nmtui-hostname
|
---|
[d497e89] | 522 | </seg>
|
---|
| 523 | <seg>
|
---|
[b9f17a8] | 524 | libnm.so
|
---|
[52c95143] | 525 | and several modules under /usr/lib/NetworkManager
|
---|
[d497e89] | 526 | </seg>
|
---|
| 527 | <seg>
|
---|
[5aa7dce] | 528 | /etc/NetworkManager,
|
---|
[05a433b] | 529 | /usr/include/libnm,
|
---|
[5aa7dce] | 530 | /usr/lib/NetworkManager,
|
---|
| 531 | /usr/share/doc/NetworkManager-&NetworkManager-version;,
|
---|
[b9f17a8] | 532 | /usr/share/gtk-doc/html/{libnm,NetworkManager}
|
---|
| 533 | (if the documentation is built),
|
---|
[5aa7dce] | 534 | and
|
---|
[262a108] | 535 | /var/lib/NetworkManager
|
---|
[d497e89] | 536 | </seg>
|
---|
[52c95143] | 537 | <!-- A lot of libraries were removed here. We should verify compatibilty.
|
---|
| 538 | RESTORED AT 1.18.2 -renodr -->
|
---|
[e33ddee] | 539 | </seglistitem>
|
---|
| 540 | </segmentedlist>
|
---|
| 541 |
|
---|
| 542 | <variablelist>
|
---|
| 543 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 544 | <?dbfo list-presentation="list"?>
|
---|
| 545 | <?dbhtml list-presentation="table"?>
|
---|
| 546 |
|
---|
[d497e89] | 547 | <varlistentry id="nmcli">
|
---|
| 548 | <term><command>nmcli</command></term>
|
---|
[e33ddee] | 549 | <listitem>
|
---|
[7ded7e3] | 550 | <para>
|
---|
| 551 | is a command-line tool for controlling
|
---|
[0d7900a] | 552 | <application>NetworkManager</application>
|
---|
[4c24eb0a] | 553 | and getting its status
|
---|
[7ded7e3] | 554 | </para>
|
---|
[d497e89] | 555 | <indexterm zone="NetworkManager nmcli">
|
---|
| 556 | <primary sortas="b-nmcli">nmcli</primary>
|
---|
[e33ddee] | 557 | </indexterm>
|
---|
| 558 | </listitem>
|
---|
| 559 | </varlistentry>
|
---|
| 560 |
|
---|
| 561 | <varlistentry id="nm-online">
|
---|
| 562 | <term><command>nm-online</command></term>
|
---|
| 563 | <listitem>
|
---|
[7ded7e3] | 564 | <para>
|
---|
[4c24eb0a] | 565 | is an utility to determine whether you are online
|
---|
[7ded7e3] | 566 | </para>
|
---|
[e33ddee] | 567 | <indexterm zone="NetworkManager nm-online">
|
---|
| 568 | <primary sortas="b-nm-online">nm-online</primary>
|
---|
| 569 | </indexterm>
|
---|
| 570 | </listitem>
|
---|
| 571 | </varlistentry>
|
---|
| 572 |
|
---|
[acb3e9f] | 573 | <varlistentry id="nmtui">
|
---|
| 574 | <term><command>nmtui</command></term>
|
---|
| 575 | <listitem>
|
---|
| 576 | <para>
|
---|
[21d18f7e] | 577 | is an interactive ncurses-based user interface for
|
---|
[4c24eb0a] | 578 | <application>nmcli</application>
|
---|
[acb3e9f] | 579 | </para>
|
---|
| 580 | <indexterm zone="NetworkManager nmtui">
|
---|
| 581 | <primary sortas="b-nmtui">nmtui</primary>
|
---|
| 582 | </indexterm>
|
---|
| 583 | </listitem>
|
---|
| 584 | </varlistentry>
|
---|
| 585 |
|
---|
| 586 | <varlistentry id="nmtui-connect">
|
---|
| 587 | <term><command>nmtui-connect</command></term>
|
---|
| 588 | <listitem>
|
---|
| 589 | <para>
|
---|
[21d18f7e] | 590 | is an interactive ncurses-based user interface to
|
---|
[4c24eb0a] | 591 | activate/deactivate connections
|
---|
[acb3e9f] | 592 | </para>
|
---|
| 593 | <indexterm zone="NetworkManager nmtui-connect">
|
---|
| 594 | <primary sortas="b-nmtui-connect">nmtui-connect</primary>
|
---|
| 595 | </indexterm>
|
---|
| 596 | </listitem>
|
---|
| 597 | </varlistentry>
|
---|
| 598 |
|
---|
| 599 | <varlistentry id="nmtui-edit">
|
---|
| 600 | <term><command>nmtui-edit</command></term>
|
---|
| 601 | <listitem>
|
---|
| 602 | <para>
|
---|
[4c24eb0a] | 603 | is an interactive ncurses-based user interface to edit connections
|
---|
[acb3e9f] | 604 | </para>
|
---|
| 605 | <indexterm zone="NetworkManager nmtui-edit">
|
---|
| 606 | <primary sortas="b-nmtui-edit">nmtui-edit</primary>
|
---|
| 607 | </indexterm>
|
---|
| 608 | </listitem>
|
---|
| 609 | </varlistentry>
|
---|
| 610 |
|
---|
| 611 | <varlistentry id="nmtui-hostname">
|
---|
| 612 | <term><command>nmtui-hostname</command></term>
|
---|
[e33ddee] | 613 | <listitem>
|
---|
[7ded7e3] | 614 | <para>
|
---|
[4c24eb0a] | 615 | is an interactive ncurses-based user interface to edit the hostname
|
---|
[7ded7e3] | 616 | </para>
|
---|
[acb3e9f] | 617 | <indexterm zone="NetworkManager nmtui-hostname">
|
---|
| 618 | <primary sortas="b-nmtui-hostname">nmtui-hostname</primary>
|
---|
[e33ddee] | 619 | </indexterm>
|
---|
| 620 | </listitem>
|
---|
| 621 | </varlistentry>
|
---|
| 622 |
|
---|
[d497e89] | 623 | <varlistentry id="NetworkManager-prog">
|
---|
| 624 | <term><command>NetworkManager</command></term>
|
---|
[e33ddee] | 625 | <listitem>
|
---|
[7ded7e3] | 626 | <para>
|
---|
[4c24eb0a] | 627 | is the network management daemon
|
---|
[7ded7e3] | 628 | </para>
|
---|
[d497e89] | 629 | <indexterm zone="NetworkManager NetworkManager-prog">
|
---|
[7ded7e3] | 630 | <primary sortas="b-NetworkManager">NetworkManager</primary>
|
---|
[e33ddee] | 631 | </indexterm>
|
---|
| 632 | </listitem>
|
---|
| 633 | </varlistentry>
|
---|
| 634 |
|
---|
[262a108] | 635 | <varlistentry id="libnm">
|
---|
| 636 | <term><filename class="libraryfile">libnm.so</filename></term>
|
---|
[e33ddee] | 637 | <listitem>
|
---|
[7ded7e3] | 638 | <para>
|
---|
[4c24eb0a] | 639 | contains functions used by <application>NetworkManager</application>
|
---|
[7ded7e3] | 640 | </para>
|
---|
[262a108] | 641 | <indexterm zone="NetworkManager libnm">
|
---|
| 642 | <primary sortas="c-libnm">libnm.so</primary>
|
---|
[e33ddee] | 643 | </indexterm>
|
---|
| 644 | </listitem>
|
---|
| 645 | </varlistentry>
|
---|
| 646 | </variablelist>
|
---|
| 647 |
|
---|
| 648 | </sect2>
|
---|
| 649 |
|
---|
| 650 | </sect1>
|
---|