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