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 |
|
---|
7 | <!ENTITY NetworkManager-download-http
|
---|
8 | "&gnome-download-http;/NetworkManager/&NetworkManager-minor;/NetworkManager-&NetworkManager-version;.tar.xz">
|
---|
9 | <!ENTITY NetworkManager-download-ftp
|
---|
10 | "&gnome-download-ftp;/NetworkManager/&NetworkManager-minor;/NetworkManager-&NetworkManager-version;.tar.xz">
|
---|
11 | <!ENTITY NetworkManager-md5sum "82088af23cac1be7394bde000f4612f8">
|
---|
12 | <!ENTITY NetworkManager-size "6.3 MB">
|
---|
13 | <!ENTITY NetworkManager-buildsize "265 MB (with tests)">
|
---|
14 | <!ENTITY NetworkManager-time "0.9 SBU (with tests, using parallelism=4)">
|
---|
15 | ]>
|
---|
16 |
|
---|
17 | <sect1 id="NetworkManager" xreflabel="NetworkManager-&NetworkManager-version;">
|
---|
18 | <?dbhtml filename="networkmanager.html"?>
|
---|
19 |
|
---|
20 | <sect1info>
|
---|
21 | <date>$Date$</date>
|
---|
22 | </sect1info>
|
---|
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 |
|
---|
33 | <para>
|
---|
34 | <application>NetworkManager</application> is a set of co-operative
|
---|
35 | tools that make networking simple and straightforward. Whether you use WiFi,
|
---|
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.
|
---|
40 | </para>
|
---|
41 |
|
---|
42 | &lfs112_checked;
|
---|
43 |
|
---|
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 |
|
---|
52 | <bridgehead renderas="sect3">Package Information</bridgehead>
|
---|
53 | <itemizedlist spacing="compact">
|
---|
54 | <listitem>
|
---|
55 | <para>
|
---|
56 | Download (HTTP): <ulink url="&NetworkManager-download-http;"/>
|
---|
57 | </para>
|
---|
58 | </listitem>
|
---|
59 | <listitem>
|
---|
60 | <para>
|
---|
61 | Download (FTP): <ulink url="&NetworkManager-download-ftp;"/>
|
---|
62 | </para>
|
---|
63 | </listitem>
|
---|
64 | <listitem>
|
---|
65 | <para>
|
---|
66 | Download MD5 sum: &NetworkManager-md5sum;
|
---|
67 | </para>
|
---|
68 | </listitem>
|
---|
69 | <listitem>
|
---|
70 | <para>
|
---|
71 | Download size: &NetworkManager-size;
|
---|
72 | </para>
|
---|
73 | </listitem>
|
---|
74 | <listitem>
|
---|
75 | <para>
|
---|
76 | Estimated disk space required: &NetworkManager-buildsize;
|
---|
77 | </para>
|
---|
78 | </listitem>
|
---|
79 | <listitem>
|
---|
80 | <para>
|
---|
81 | Estimated build time: &NetworkManager-time;
|
---|
82 | </para>
|
---|
83 | </listitem>
|
---|
84 | </itemizedlist>
|
---|
85 |
|
---|
86 | <bridgehead renderas="sect3">NetworkManager Dependencies</bridgehead>
|
---|
87 |
|
---|
88 | <bridgehead renderas="sect4">Required</bridgehead>
|
---|
89 | <para role="required">
|
---|
90 | <xref linkend="jansson"/> and
|
---|
91 | <xref linkend="libndp"/>
|
---|
92 | </para>
|
---|
93 |
|
---|
94 | <bridgehead renderas="sect4">Recommended</bridgehead>
|
---|
95 | <para role="recommended">
|
---|
96 | <xref linkend="curl"/>,
|
---|
97 | <!--<xref linkend="dhcpcd"/> or
|
---|
98 | DHCPCD support is known to be broken with dhcpcd-9 -->
|
---|
99 | <xref role="nodep" linkend="dhcp"/> (client only),
|
---|
100 | <xref linkend="gobject-introspection"/>,
|
---|
101 | <xref linkend="iptables"/>,
|
---|
102 | <xref linkend="newt"/> (for <command>nmtui</command>),
|
---|
103 | <xref linkend="nss"/>,
|
---|
104 | <xref linkend="polkit"/>,
|
---|
105 | <xref linkend="pygobject3"/>,
|
---|
106 | <phrase revision="sysv"><xref linkend="elogind"/>,</phrase>
|
---|
107 | <phrase revision="systemd"><xref linkend="systemd"/>,</phrase>
|
---|
108 | <xref linkend="upower"/>,
|
---|
109 | <xref linkend="vala"/>, and
|
---|
110 | <xref linkend="wpa_supplicant"/> (built with D-Bus support)
|
---|
111 | </para>
|
---|
112 |
|
---|
113 | <bridgehead renderas="sect4">Optional</bridgehead>
|
---|
114 | <para role="optional">
|
---|
115 | <xref linkend="bluez"/>,
|
---|
116 | <xref linkend="dbus-python"/> (for the test suite),
|
---|
117 | <!-- <xref linkend="firewalld"/> (For whenever firewalld is reintroduced) -->
|
---|
118 | <xref linkend="gnutls"/> (used if <xref linkend="nss"/> is not found),
|
---|
119 | <xref linkend="gtk-doc"/>,
|
---|
120 | <xref linkend="libpsl"/>,
|
---|
121 | <xref linkend="qt5"/> (for examples),
|
---|
122 | <xref linkend="ModemManager"/>,
|
---|
123 | <xref linkend="valgrind"/>,
|
---|
124 | <ulink url="https://thekelleys.org.uk/dnsmasq/doc.html">dnsmasq</ulink>,
|
---|
125 | <ulink url="https://firewalld.org/">firewalld</ulink>,
|
---|
126 | <ulink url="https://github.com/Distrotech/libaudit">libaudit</ulink>,
|
---|
127 | <ulink url="https://github.com/jpirko/libteam">libteam</ulink>,
|
---|
128 | <ulink url="&gnome-download-http;/mobile-broadband-provider-info/">mobile-broadband-provider-info</ulink>,
|
---|
129 | <ulink url="https://www.samba.org/ftp/ppp/">PPP</ulink>, and
|
---|
130 | <ulink url="https://dianne.skoll.ca/projects/rp-pppoe/">RP-PPPoE</ulink>
|
---|
131 | </para>
|
---|
132 |
|
---|
133 | <para condition="html" role="usernotes">User Notes:
|
---|
134 | <ulink url="&blfs-wiki;/NetworkManager"/>
|
---|
135 | </para>
|
---|
136 | </sect2>
|
---|
137 |
|
---|
138 | <sect2 role="kernel" id="NetworkManager-kernel">
|
---|
139 | <title>Kernel Configuration</title>
|
---|
140 |
|
---|
141 | <para>
|
---|
142 | If you wish to run the tests, check that at least the following options
|
---|
143 | are enabled in the kernel configuration. Those options have been
|
---|
144 | determined to be necessary, but may not be sufficient. Recompile the
|
---|
145 | kernel if necessary:
|
---|
146 | </para>
|
---|
147 |
|
---|
148 | <!-- Ethernet Teaming support is potentially optional, but I didn't
|
---|
149 | run the tests again to test that. It was needed to convince one of
|
---|
150 | the Linux Platform tests to move farther along because otherwise
|
---|
151 | RTNETLINK would respond with an Error 95 - unknown device type.
|
---|
152 | This would cause the test to fail early on in the process.
|
---|
153 |
|
---|
154 | [pierre, Nov 2022]: I cannot tell whether these options are
|
---|
155 | the only ones that are needed. They are the options I had to add
|
---|
156 | in order to have some tests pass. But I already had some other
|
---|
157 | options set for packet filtering (iptables), that may not be
|
---|
158 | available by default and may be necessary. Even with the options
|
---|
159 | below still one test (test-route) fails.-->
|
---|
160 |
|
---|
161 | <screen><literal>
|
---|
162 | [*] Networking support---> [CONFIG_NET]
|
---|
163 | Networking options--->
|
---|
164 | [*] TCP/IP networking [CONFIG_INET]
|
---|
165 | <*/M> IP: tunelling [CONFIG_NET_IPIP]
|
---|
166 | <*/M> IP: GRE demultiplexer [CONFIG_NET_IPGRE_DEMUX]
|
---|
167 | <*/M> IP: GRE tunnels over IP [CONFIG_NET_IPGRE]
|
---|
168 | <*> The IPv6 protocol ---> [CONFIG_IPV6]
|
---|
169 | <*/M> IPv6: IPv6-in-IPv4 tunnel (SIT driver) [CONFIG_IPV6_SIT]
|
---|
170 | <*/M> IPv6: GRE tunnel [CONFIG_IPV6_GRE]
|
---|
171 | [*] IPv6: Multiple Routing Tables [CONFIG_IPV6_MULTIPLE_TABLES]
|
---|
172 | [*] MPTCP: Multipath TCP [CONFIG_MPTCP]
|
---|
173 | [*] MPTCP: IPv6 support for Multipath TCP [CONFIG_MPTCP_IPV6]
|
---|
174 | <*/M> 802.1Q/802.1ad VLAN Support [CONFIG_VLAN_8021Q]
|
---|
175 | [*] QoS and/or fair queueing ---> [CONFIG_NET_SCHED]
|
---|
176 | <*/M> Stochastic Fairness Queueing (SFQ) [CONFIG_NET_SCH_SFQ]
|
---|
177 | <*/M> Token Bucket Filter (TBF) [CONFIG_NET_SCH_TBF]
|
---|
178 | <*/M> Fair Queue Controlled Delay AQM (FQ_CODEL) [CONFIG_NET_SCH_FQ_CODEL]
|
---|
179 | <*/M> Ingress/classifier-action Qdisc [CONFIG_NET_SCH_INGRESS]
|
---|
180 | Device Drivers --->
|
---|
181 | [*] Network device support ---> [CONFIG_NETDEVICES]
|
---|
182 | [*] Network core driver support [CONFIG_NET_CORE]
|
---|
183 | <*> Bonding driver support [CONFIG_BONDING]
|
---|
184 | <*> Dummy net driver support [CONFIG_DUMMY]
|
---|
185 | <*> Ethernet team driver support ---> [CONFIG_NET_TEAM]
|
---|
186 | <*> MAC-VLAN support [CONFIG_MACVLAN]
|
---|
187 | <*> MAC-VLAN based tap driver [CONFIG_MACVTAP]
|
---|
188 | <*> IP-VLAN support [CONFIG_IPVLAN]
|
---|
189 | <*> Virtual eXtensible Local Area Network (VXLAN) [CONFIG_VXLAN]
|
---|
190 | <*> Virtual ethernet pair device [CONFIG_VETH]
|
---|
191 | <*> Virtual Routing and Forwarding (Lite) [CONFIG_VRF]
|
---|
192 | </literal></screen>
|
---|
193 |
|
---|
194 | <indexterm zone="NetworkManager NetworkManager-kernel">
|
---|
195 | <primary sortas="d-NetworkManager">NetworkManager</primary>
|
---|
196 | </indexterm>
|
---|
197 | </sect2>
|
---|
198 |
|
---|
199 | <sect2 role="installation">
|
---|
200 | <title>Installation of NetworkManager</title>
|
---|
201 |
|
---|
202 | <para>
|
---|
203 | If <xref linkend="qt5"/> is installed and the Qt based
|
---|
204 | examples are desired, fix two meson.build files:
|
---|
205 | </para>
|
---|
206 |
|
---|
207 | <screen><userinput>sed -e 's/-qt4/-qt5/' \
|
---|
208 | -e 's/moc_location/host_bins/' \
|
---|
209 | -i examples/C/qt/meson.build &&
|
---|
210 |
|
---|
211 | sed -e 's/Qt/&5/' \
|
---|
212 | -i meson.build</userinput></screen>
|
---|
213 |
|
---|
214 | <!--
|
---|
215 | <para>
|
---|
216 | Fix a missing meson.build file for initrd hooks (not used in BLFS):
|
---|
217 | </para>
|
---|
218 |
|
---|
219 | <screen><userinput>sed '/initrd/d' -i src/core/meson.build</userinput></screen>
|
---|
220 | -->
|
---|
221 |
|
---|
222 | <para>
|
---|
223 | Fix the python scripts so that they use <application>Python
|
---|
224 | 3</application>:
|
---|
225 | </para>
|
---|
226 |
|
---|
227 | <screen><userinput>grep -rl '^#!.*python$' | xargs sed -i '1s/python/&3/'</userinput></screen>
|
---|
228 |
|
---|
229 | <para>
|
---|
230 | Install <application>NetworkManager</application> by running the
|
---|
231 | following commands:
|
---|
232 | </para>
|
---|
233 |
|
---|
234 | <screen revision="sysv"><userinput>mkdir build &&
|
---|
235 | cd build &&
|
---|
236 |
|
---|
237 | CXXFLAGS+="-O2 -fPIC" \
|
---|
238 | meson --prefix=/usr \
|
---|
239 | --buildtype=release \
|
---|
240 | -Dlibaudit=no \
|
---|
241 | -Dlibpsl=false \
|
---|
242 | -Dnmtui=true \
|
---|
243 | -Dovs=false \
|
---|
244 | -Dppp=false \
|
---|
245 | -Dselinux=false \
|
---|
246 | -Dsession_tracking=elogind \
|
---|
247 | -Dmodem_manager=false \
|
---|
248 | -Dsystemdsystemunitdir=no \
|
---|
249 | -Dsystemd_journal=false \
|
---|
250 | -Dqt=false \
|
---|
251 | .. &&
|
---|
252 | ninja</userinput></screen>
|
---|
253 |
|
---|
254 | <screen revision="systemd"><userinput>mkdir build &&
|
---|
255 | cd build &&
|
---|
256 |
|
---|
257 | CXXFLAGS+="-O2 -fPIC" \
|
---|
258 | meson --prefix=/usr \
|
---|
259 | --buildtype=release \
|
---|
260 | -Dlibaudit=no \
|
---|
261 | -Dlibpsl=false \
|
---|
262 | -Dnmtui=true \
|
---|
263 | -Dovs=false \
|
---|
264 | -Dppp=false \
|
---|
265 | -Dselinux=false \
|
---|
266 | -Dqt=false \
|
---|
267 | -Dsession_tracking=systemd \
|
---|
268 | -Dmodem_manager=false \
|
---|
269 | .. &&
|
---|
270 | ninja</userinput></screen>
|
---|
271 |
|
---|
272 | <para>
|
---|
273 | An already active graphical session with a bus address is necessary
|
---|
274 | to run the tests. To test the results, issue
|
---|
275 | <command>ninja test</command>.
|
---|
276 | </para>
|
---|
277 |
|
---|
278 | <para>
|
---|
279 | A few tests may fail, depending on enabled kernel options.
|
---|
280 | </para>
|
---|
281 |
|
---|
282 | <para>
|
---|
283 | Now, as the <systemitem class="username">root</systemitem> user:
|
---|
284 | </para>
|
---|
285 |
|
---|
286 | <screen role="root"><userinput>ninja install &&
|
---|
287 | mv -v /usr/share/doc/NetworkManager{,-&NetworkManager-version;}</userinput></screen>
|
---|
288 |
|
---|
289 | <para>
|
---|
290 | If you have not passed the <option>-Ddocs=true</option> option to
|
---|
291 | <command>meson</command>, you can install the pregenerated manual pages
|
---|
292 | with (as the &root; user):
|
---|
293 | </para>
|
---|
294 |
|
---|
295 | <screen role="root"><userinput>for file in $(echo ../man/*.[1578]); do
|
---|
296 | section=${file##*.} &&
|
---|
297 | install -vdm 755 /usr/share/man/man$section
|
---|
298 | install -vm 644 $file /usr/share/man/man$section/
|
---|
299 | done</userinput></screen>
|
---|
300 |
|
---|
301 | <para>
|
---|
302 | Still in case you have not used <option>-Ddocs=true</option>, the
|
---|
303 | pregenerated HTML documentation can also be installed with (as
|
---|
304 | the &root; user):
|
---|
305 | </para>
|
---|
306 |
|
---|
307 | <screen role="root"
|
---|
308 | remap="doc"><userinput>cp -Rv ../docs/{api,libnm} /usr/share/doc/NetworkManager-&NetworkManager-version;</userinput></screen>
|
---|
309 |
|
---|
310 | </sect2>
|
---|
311 |
|
---|
312 | <sect2 role="commands">
|
---|
313 | <title>Command Explanations</title>
|
---|
314 |
|
---|
315 | <para>
|
---|
316 | <envar>CXXFLAGS="-O2 -fPIC"</envar>: These compiler options are
|
---|
317 | necessary to build the Qt5 based examples.
|
---|
318 | </para>
|
---|
319 |
|
---|
320 | <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
|
---|
321 | href="../../xincludes/meson-buildtype-release.xml"/>
|
---|
322 |
|
---|
323 | <para>
|
---|
324 | <option>-Ddocs=true</option>: Use this switch to enable building
|
---|
325 | man pages and documentation if <xref linkend="gtk-doc"/> is installed.
|
---|
326 | </para>
|
---|
327 |
|
---|
328 | <para>
|
---|
329 | <parameter>-Dnmtui=true</parameter>: This parameter enables building
|
---|
330 | <command>nmtui</command>.
|
---|
331 | </para>
|
---|
332 |
|
---|
333 | <para revision="sysv">
|
---|
334 | <parameter>-Dsystemdsystemunitdir=no</parameter> and
|
---|
335 | <parameter>-Dsystemd_journal=false</parameter>: systemd is not
|
---|
336 | used for sysv init systems.
|
---|
337 | </para>
|
---|
338 |
|
---|
339 | <para>
|
---|
340 | <!--<parameter>-Djson_validation=false</parameter>, no longer recognized -->
|
---|
341 | <parameter>-Dlibpsl=false</parameter> and
|
---|
342 | <parameter>-Dovs=false</parameter>: These switches disable building with the
|
---|
343 | respective libraries. Remove if you have the needed libraries installed.
|
---|
344 | </para>
|
---|
345 |
|
---|
346 | <!--
|
---|
347 | <para>
|
---|
348 | <parameter>-Dlibpsl=false</parameter>: This switch is required if
|
---|
349 | <application>libpsl</application> is not installed. Omit this switch if
|
---|
350 | you have built <application>libpsl</application>.
|
---|
351 | </para>
|
---|
352 | -->
|
---|
353 |
|
---|
354 | <para>
|
---|
355 | <parameter>-Dmodem_manager=false</parameter>: This switch is required if
|
---|
356 | <application>ModemManager</application> is not installed. Omit if you
|
---|
357 | have built <application>ModemManager</application> and
|
---|
358 | <application>mobile-broadband-provider-info</application>.
|
---|
359 | </para>
|
---|
360 |
|
---|
361 | <para revision="sysv">
|
---|
362 | <parameter>-Dsession_tracking=elogind</parameter>: This switch
|
---|
363 | is used to set <command>elogind</command> as the default
|
---|
364 | program for session tracking.
|
---|
365 | </para>
|
---|
366 |
|
---|
367 | <para revision="systemd">
|
---|
368 | <parameter>-Dsession_tracking=systemd</parameter>: This switch
|
---|
369 | is used to set <command>systemd-logind</command> as the default
|
---|
370 | program for session tracking.
|
---|
371 | </para>
|
---|
372 |
|
---|
373 | <para revision="systemd">
|
---|
374 | <parameter>-Dsystemdsystemunitdir=/lib/systemd/system</parameter>:
|
---|
375 | This switch is used to set the correct installation directory for
|
---|
376 | systemd units.
|
---|
377 | </para>
|
---|
378 |
|
---|
379 | <para>
|
---|
380 | <parameter>-Dppp=false</parameter>: This parameter disables
|
---|
381 | <application>PPP</application> support in
|
---|
382 | <application>NetworkManager</application>.
|
---|
383 | </para>
|
---|
384 |
|
---|
385 | <para>
|
---|
386 | <parameter>-Dlibaudit=no</parameter> and
|
---|
387 | <parameter>-Dselinux=false</parameter>: libaudit and SELinux are not used
|
---|
388 | in BLFS.
|
---|
389 | </para>
|
---|
390 |
|
---|
391 | <para>
|
---|
392 | <parameter>-Dqt=false</parameter>: disables the
|
---|
393 | <application>QT</application> examples. Omit if you have
|
---|
394 | <application>QT</application> available and wish to install the examples.
|
---|
395 | </para>
|
---|
396 |
|
---|
397 | </sect2>
|
---|
398 |
|
---|
399 | <sect2 role="configuration">
|
---|
400 | <title>Configuring NetworkManager</title>
|
---|
401 |
|
---|
402 | <sect3 id="NetworkManager-config">
|
---|
403 | <title>Config Files</title>
|
---|
404 | <para>
|
---|
405 | <filename>/etc/NetworkManager/NetworkManager.conf</filename>
|
---|
406 | </para>
|
---|
407 |
|
---|
408 | <indexterm zone="NetworkManager NetworkManager-config">
|
---|
409 | <primary
|
---|
410 | sortas="e-etc-NetworkManager-NetworkManager.conf">
|
---|
411 | /etc/NetworkManager/NetworkManager.conf</primary>
|
---|
412 | </indexterm>
|
---|
413 |
|
---|
414 | </sect3>
|
---|
415 |
|
---|
416 | <sect3><title>Configuration Information</title>
|
---|
417 |
|
---|
418 | <para>
|
---|
419 | For <application>NetworkManager</application> to work, at least
|
---|
420 | a minimal configuration file must be present. Such a file is not
|
---|
421 | installed with <command>make install</command>. Issue the following
|
---|
422 | command as the <systemitem class="username">root</systemitem> user to
|
---|
423 | create a minimal <filename>NetworkManager.conf</filename> file:
|
---|
424 | </para>
|
---|
425 |
|
---|
426 | <screen role="root"><userinput>cat >> /etc/NetworkManager/NetworkManager.conf << "EOF"
|
---|
427 | <literal>[main]
|
---|
428 | plugins=keyfile</literal>
|
---|
429 | EOF</userinput></screen>
|
---|
430 |
|
---|
431 | <para>
|
---|
432 | This file should not be modified directly by users of the system.
|
---|
433 | Instead, system specific changes should be made using configuration
|
---|
434 | files in the
|
---|
435 | <filename class="directory">/etc/NetworkManager/conf.d</filename>
|
---|
436 | directory.
|
---|
437 | </para>
|
---|
438 |
|
---|
439 | <para>
|
---|
440 | To allow polkit to manage authorizations, add the following
|
---|
441 | configuration file:
|
---|
442 | </para>
|
---|
443 |
|
---|
444 | <screen role="root"><userinput>cat > /etc/NetworkManager/conf.d/polkit.conf << "EOF"
|
---|
445 | <literal>[main]
|
---|
446 | auth-polkit=true</literal>
|
---|
447 | EOF</userinput></screen>
|
---|
448 |
|
---|
449 | <para>
|
---|
450 | To use something other than the built-in dhcp client (recommended if
|
---|
451 | using only <command>nmcli</command>), use the following configuration
|
---|
452 | (valid values include either dhclient <!--dhcpcd --> or internal):
|
---|
453 | </para>
|
---|
454 |
|
---|
455 | <screen role="nodump"><userinput>cat > /etc/NetworkManager/conf.d/dhcp.conf << "EOF"
|
---|
456 | <literal>[main]
|
---|
457 | dhcp=</literal><replaceable>dhclient</replaceable>
|
---|
458 | EOF</userinput></screen>
|
---|
459 |
|
---|
460 | <para>
|
---|
461 | To prevent <application>NetworkManager</application> from updating the
|
---|
462 | <filename>/etc/resolv.conf</filename> file, add the following
|
---|
463 | configuration file:
|
---|
464 | </para>
|
---|
465 |
|
---|
466 | <screen role="nodump"><userinput>cat > /etc/NetworkManager/conf.d/no-dns-update.conf << "EOF"
|
---|
467 | <literal>[main]
|
---|
468 | dns=none</literal>
|
---|
469 | EOF</userinput></screen>
|
---|
470 |
|
---|
471 | <para>
|
---|
472 | For additional configuration options, see
|
---|
473 | <command>man 5 NetworkManager.conf</command>.
|
---|
474 | </para>
|
---|
475 |
|
---|
476 | <para>
|
---|
477 | To allow regular users to configure network connections,
|
---|
478 | you should add them to the
|
---|
479 | <systemitem class="groupname">netdev</systemitem>
|
---|
480 | group, and create a <application>polkit</application> rule that grants
|
---|
481 | access. Run the following commands as the
|
---|
482 | <systemitem class="username">root</systemitem> user:
|
---|
483 | </para>
|
---|
484 |
|
---|
485 | <screen role="root"><userinput>groupadd -fg 86 netdev &&
|
---|
486 | /usr/sbin/usermod -a -G netdev <replaceable><username></replaceable>
|
---|
487 |
|
---|
488 | cat > /usr/share/polkit-1/rules.d/org.freedesktop.NetworkManager.rules << "EOF"
|
---|
489 | <literal>polkit.addRule(function(action, subject) {
|
---|
490 | if (action.id.indexOf("org.freedesktop.NetworkManager.") == 0 && subject.isInGroup("netdev")) {
|
---|
491 | return polkit.Result.YES;
|
---|
492 | }
|
---|
493 | });</literal>
|
---|
494 | EOF</userinput></screen>
|
---|
495 |
|
---|
496 | </sect3>
|
---|
497 |
|
---|
498 | <sect3 id="NetworkManager-init">
|
---|
499 | <title><phrase revision="sysv">Boot Script</phrase>
|
---|
500 | <phrase revision="systemd">Systemd Unit</phrase></title>
|
---|
501 |
|
---|
502 | <para revision="sysv">
|
---|
503 | To automatically start the <command>NetworkManager</command> daemon
|
---|
504 | when the system is rebooted, install the
|
---|
505 | <filename>/etc/rc.d/init.d/networkmanager</filename>bootscript from the
|
---|
506 | <xref linkend="bootscripts"/> package.
|
---|
507 | </para>
|
---|
508 |
|
---|
509 | <para revision="systemd">
|
---|
510 | To start the <command>NetworkManager</command> daemon at boot, enable
|
---|
511 | the previously installed systemd unit by running the following command
|
---|
512 | as the <systemitem class="username">root</systemitem> user:
|
---|
513 | </para>
|
---|
514 |
|
---|
515 | <note>
|
---|
516 | <para>
|
---|
517 | If using <application>Network Manager</application> to manage
|
---|
518 | an interface, any previous configuration for that interface should be
|
---|
519 | removed, and the interface brought down prior to starting
|
---|
520 | <application>Network Manager</application>.
|
---|
521 | </para>
|
---|
522 | </note>
|
---|
523 |
|
---|
524 | <indexterm zone="NetworkManager NetworkManager-init">
|
---|
525 | <primary sortas="f-NetworkManager">NetworkManager</primary>
|
---|
526 | </indexterm>
|
---|
527 |
|
---|
528 | <screen role="root" revision="sysv"><userinput>make install-networkmanager</userinput></screen>
|
---|
529 |
|
---|
530 | <screen role="root" revision="systemd"><userinput>systemctl enable NetworkManager</userinput></screen>
|
---|
531 | <!-- The below instruction is obsolete. NetworkManager-wait-online is now
|
---|
532 | enabled by default when enabling NetworkManager. -->
|
---|
533 | <!--
|
---|
534 | <para revision="systemd">
|
---|
535 | <application>NetworkManager</application> also ships a systemd unit
|
---|
536 | called <filename>NetworkManager-wait-online.service</filename> which
|
---|
537 | can be used to prevent services that require network connectivity
|
---|
538 | from starting until <application>NetworkManager</application> has
|
---|
539 | established the connection. To enable it, run the following command
|
---|
540 | as the <systemitem class="username">root</systemitem> user:
|
---|
541 | </para>
|
---|
542 |
|
---|
543 | <screen role="root" revision="systemd"><userinput>systemctl enable NetworkManager-wait-online</userinput></screen>
|
---|
544 | -->
|
---|
545 | <!-- As such, let's now provide instructions on how to disable that
|
---|
546 | behavior, for those who wish to do so. -->
|
---|
547 | <para revision="systemd">
|
---|
548 | Starting in version 1.11.2 of <application>NetworkManager</application>,
|
---|
549 | a systemd unit named <filename>NetworkManager-wait-online.service</filename>
|
---|
550 | is enabled, which is used to prevent services that require network
|
---|
551 | connectivity from starting until <application>NetworkManager</application>
|
---|
552 | establishes a connection. To disable this behavior, run the following
|
---|
553 | command as the <systemitem class="username">root</systemitem> user:
|
---|
554 | </para>
|
---|
555 |
|
---|
556 | <screen role="root" revision="systemd"><userinput>systemctl disable NetworkManager-wait-online</userinput></screen>
|
---|
557 |
|
---|
558 | </sect3>
|
---|
559 |
|
---|
560 | </sect2>
|
---|
561 |
|
---|
562 | <sect2 role="content">
|
---|
563 | <title>Contents</title>
|
---|
564 |
|
---|
565 | <segmentedlist>
|
---|
566 | <segtitle>Installed Programs</segtitle>
|
---|
567 | <segtitle>Installed Libraries</segtitle>
|
---|
568 | <segtitle>Installed Directories</segtitle>
|
---|
569 |
|
---|
570 | <seglistitem>
|
---|
571 | <seg>
|
---|
572 | NetworkManager, nmcli, nm-online, nmtui, and, symlinked to nmtui:
|
---|
573 | nmtui-connect, nmtui-edit, and nmtui-hostname
|
---|
574 | </seg>
|
---|
575 | <seg>
|
---|
576 | libnm.so
|
---|
577 | and several modules under /usr/lib/NetworkManager
|
---|
578 | </seg>
|
---|
579 | <seg>
|
---|
580 | /etc/NetworkManager,
|
---|
581 | /usr/include/libnm,
|
---|
582 | /usr/lib/NetworkManager,
|
---|
583 | /usr/share/doc/NetworkManager-&NetworkManager-version;,
|
---|
584 | /usr/share/gtk-doc/html/{libnm,NetworkManager}
|
---|
585 | (if the documentation is built),
|
---|
586 | and
|
---|
587 | /var/lib/NetworkManager
|
---|
588 | </seg>
|
---|
589 | <!-- A lot of libraries were removed here. We should verify compatibility.
|
---|
590 | RESTORED AT 1.18.2 -renodr -->
|
---|
591 | </seglistitem>
|
---|
592 | </segmentedlist>
|
---|
593 |
|
---|
594 | <variablelist>
|
---|
595 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
596 | <?dbfo list-presentation="list"?>
|
---|
597 | <?dbhtml list-presentation="table"?>
|
---|
598 |
|
---|
599 | <varlistentry id="nmcli">
|
---|
600 | <term><command>nmcli</command></term>
|
---|
601 | <listitem>
|
---|
602 | <para>
|
---|
603 | is a command-line tool for controlling
|
---|
604 | <application>NetworkManager</application>
|
---|
605 | and getting its status
|
---|
606 | </para>
|
---|
607 | <indexterm zone="NetworkManager nmcli">
|
---|
608 | <primary sortas="b-nmcli">nmcli</primary>
|
---|
609 | </indexterm>
|
---|
610 | </listitem>
|
---|
611 | </varlistentry>
|
---|
612 |
|
---|
613 | <varlistentry id="nm-online">
|
---|
614 | <term><command>nm-online</command></term>
|
---|
615 | <listitem>
|
---|
616 | <para>
|
---|
617 | is an utility to determine whether you are online
|
---|
618 | </para>
|
---|
619 | <indexterm zone="NetworkManager nm-online">
|
---|
620 | <primary sortas="b-nm-online">nm-online</primary>
|
---|
621 | </indexterm>
|
---|
622 | </listitem>
|
---|
623 | </varlistentry>
|
---|
624 |
|
---|
625 | <varlistentry id="nmtui">
|
---|
626 | <term><command>nmtui</command></term>
|
---|
627 | <listitem>
|
---|
628 | <para>
|
---|
629 | is an interactive ncurses-based user interface for
|
---|
630 | <application>nmcli</application>
|
---|
631 | </para>
|
---|
632 | <indexterm zone="NetworkManager nmtui">
|
---|
633 | <primary sortas="b-nmtui">nmtui</primary>
|
---|
634 | </indexterm>
|
---|
635 | </listitem>
|
---|
636 | </varlistentry>
|
---|
637 |
|
---|
638 | <varlistentry id="nmtui-connect">
|
---|
639 | <term><command>nmtui-connect</command></term>
|
---|
640 | <listitem>
|
---|
641 | <para>
|
---|
642 | is an interactive ncurses-based user interface to
|
---|
643 | activate/deactivate connections
|
---|
644 | </para>
|
---|
645 | <indexterm zone="NetworkManager nmtui-connect">
|
---|
646 | <primary sortas="b-nmtui-connect">nmtui-connect</primary>
|
---|
647 | </indexterm>
|
---|
648 | </listitem>
|
---|
649 | </varlistentry>
|
---|
650 |
|
---|
651 | <varlistentry id="nmtui-edit">
|
---|
652 | <term><command>nmtui-edit</command></term>
|
---|
653 | <listitem>
|
---|
654 | <para>
|
---|
655 | is an interactive ncurses-based user interface to edit connections
|
---|
656 | </para>
|
---|
657 | <indexterm zone="NetworkManager nmtui-edit">
|
---|
658 | <primary sortas="b-nmtui-edit">nmtui-edit</primary>
|
---|
659 | </indexterm>
|
---|
660 | </listitem>
|
---|
661 | </varlistentry>
|
---|
662 |
|
---|
663 | <varlistentry id="nmtui-hostname">
|
---|
664 | <term><command>nmtui-hostname</command></term>
|
---|
665 | <listitem>
|
---|
666 | <para>
|
---|
667 | is an interactive ncurses-based user interface to edit the hostname
|
---|
668 | </para>
|
---|
669 | <indexterm zone="NetworkManager nmtui-hostname">
|
---|
670 | <primary sortas="b-nmtui-hostname">nmtui-hostname</primary>
|
---|
671 | </indexterm>
|
---|
672 | </listitem>
|
---|
673 | </varlistentry>
|
---|
674 |
|
---|
675 | <varlistentry id="NetworkManager-prog">
|
---|
676 | <term><command>NetworkManager</command></term>
|
---|
677 | <listitem>
|
---|
678 | <para>
|
---|
679 | is the network management daemon
|
---|
680 | </para>
|
---|
681 | <indexterm zone="NetworkManager NetworkManager-prog">
|
---|
682 | <primary sortas="b-NetworkManager">NetworkManager</primary>
|
---|
683 | </indexterm>
|
---|
684 | </listitem>
|
---|
685 | </varlistentry>
|
---|
686 |
|
---|
687 | <varlistentry id="libnm">
|
---|
688 | <term><filename class="libraryfile">libnm.so</filename></term>
|
---|
689 | <listitem>
|
---|
690 | <para>
|
---|
691 | contains functions used by <application>NetworkManager</application>
|
---|
692 | </para>
|
---|
693 | <indexterm zone="NetworkManager libnm">
|
---|
694 | <primary sortas="c-libnm">libnm.so</primary>
|
---|
695 | </indexterm>
|
---|
696 | </listitem>
|
---|
697 | </varlistentry>
|
---|
698 | </variablelist>
|
---|
699 |
|
---|
700 | </sect2>
|
---|
701 |
|
---|
702 | </sect1>
|
---|