source: networking/netutils/networkmanager.xml@ b528d0f4

10.0 10.1 11.0 11.1 8.1 8.2 8.3 8.4 9.0 9.1 basic bdubbs/svn elogind lazarus perl-modules qt5new trunk upgradedb xry111/intltool xry111/test-20220226
Last change on this file since b528d0f4 was b528d0f4, checked in by Pierre Labastie <pieere@…>, 5 years ago

Fix NetworkManager dependency on PyGobject

git-svn-id: svn://svn.linuxfromscratch.org/BLFS/trunk/BOOK@18463 af4574ff-66df-0310-9fd7-8a98e5e911e0

  • Property mode set to 100644
File size: 18.0 KB
Line 
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/1.6/NetworkManager-&NetworkManager-version;.tar.xz">
9 <!ENTITY NetworkManager-download-ftp
10 "&gnome-download-ftp;/NetworkManager/1.6/NetworkManager-&NetworkManager-version;.tar.xz">
11 <!ENTITY NetworkManager-md5sum "89c975afe19fbac854191edb6e9bcd3b">
12 <!ENTITY NetworkManager-size "3.6 MB">
13 <!ENTITY NetworkManager-buildsize "581 MB (with tests)">
14 <!ENTITY NetworkManager-time "3.8 SBU (with tests)">
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>
23 </sect1info>
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
34 <para>
35 <application>NetworkManager</application> is a set of co-operative
36 tools that make networking simple and straightforward. Whether WiFi,
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.
41 </para>
42
43 &lfs80_checked;
44
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
53 <bridgehead renderas="sect3">Package Information</bridgehead>
54 <itemizedlist spacing="compact">
55 <listitem>
56 <para>
57 Download (HTTP): <ulink url="&NetworkManager-download-http;"/>
58 </para>
59 </listitem>
60 <listitem>
61 <para>
62 Download (FTP): <ulink url="&NetworkManager-download-ftp;"/>
63 </para>
64 </listitem>
65 <listitem>
66 <para>
67 Download MD5 sum: &NetworkManager-md5sum;
68 </para>
69 </listitem>
70 <listitem>
71 <para>
72 Download size: &NetworkManager-size;
73 </para>
74 </listitem>
75 <listitem>
76 <para>
77 Estimated disk space required: &NetworkManager-buildsize;
78 </para>
79 </listitem>
80 <listitem>
81 <para>
82 Estimated build time: &NetworkManager-time;
83 </para>
84 </listitem>
85 </itemizedlist>
86
87 <bridgehead renderas="sect3">NetworkManager Dependencies</bridgehead>
88
89 <bridgehead renderas="sect4">Required</bridgehead>
90 <para role="required">
91 <xref linkend="dbus-glib"/>,
92 <xref linkend="libgudev"/>,
93 <xref linkend="libndp"/>,
94 <xref linkend="libnl"/>, and
95 <xref linkend="nss"/>
96 </para>
97
98 <bridgehead renderas="sect4">Recommended</bridgehead>
99 <para role="recommended">
100 <phrase revision="sysv"><xref linkend="consolekit"/>,</phrase>
101 <xref linkend="dhcpcd"/> or
102 <xref linkend="dhcp"/> (client only),
103 <xref linkend="gobject-introspection"/>,
104 <xref linkend="iptables"/>,
105 <xref linkend="libsoup"/>,
106 <xref linkend="newt"/> (for <command>nmtui</command>),
107 <xref linkend="polkit"/>,
108 <xref linkend="pygobject3"/>,
109 <phrase revision="systemd"><xref linkend="systemd"/>,</phrase>
110 <xref linkend="upower"/>,
111 <xref linkend="vala"/>, and
112 <xref linkend="wpa_supplicant"/> (built with D-Bus support),
113 </para>
114
115 <bridgehead renderas="sect4">Optional</bridgehead>
116 <para role="optional">
117 <xref linkend="bluez"/>,
118 <xref linkend="gtk-doc"/>,
119 <xref linkend="qt5"/> (for examples),
120 <xref linkend="ModemManager"/>,
121 <xref linkend="valgrind"/>,
122 <ulink url="http://www.thekelleys.org.uk/dnsmasq/doc.html">dnsmasq</ulink>,
123 <ulink url="http://www.digip.org/jansson/">Jansson</ulink>,
124 <ulink url="http://libteam.org/">libteam</ulink>,
125 <ulink url="https://www.samba.org/ftp/ppp/">PPP</ulink>, and
126 <ulink url="https://www.roaringpenguin.com/products/pppoe">RP-PPPoE</ulink>
127 </para>
128
129 <para condition="html" role="usernotes">User Notes:
130 <ulink url="&blfs-wiki;/NetworkManager"/>
131 </para>
132 </sect2>
133
134 <sect2 role="installation">
135 <title>Installation of NetworkManager</title>
136
137 <para>If <xref linkend="qt5"/> is installed and the Qt based
138 examples are desired, fix the configure script:</para>
139
140<screen><userinput>sed -e '/Qt[CDN]/s/Qt/Qt5/g' \
141 -e 's/moc_location/host_bins/' \
142 -i configure</userinput></screen>
143
144 <para>
145 Install <application>NetworkManager</application> by running the
146 following commands:
147 </para>
148
149<screen revision="sysv"><userinput>CXXFLAGS="-O2 -fPIC" \
150./configure --prefix=/usr \
151 --sysconfdir=/etc \
152 --localstatedir=/var \
153 --with-nmtui \
154 --disable-ppp \
155 --disable-json-validation \
156 --with-systemdsystemunitdir=no \
157 --docdir=/usr/share/doc/network-manager-&NetworkManager-version; &amp;&amp;
158make</userinput></screen>
159
160<screen revision="systemd"><userinput>CXXFLAGS="-O2 -fPIC" \
161./configure --prefix=/usr \
162 --sysconfdir=/etc \
163 --localstatedir=/var \
164 --with-nmtui \
165 --disable-ppp \
166 --disable-json-validation \
167 --with-session-tracking=systemd \
168 --with-systemdsystemunitdir=/lib/systemd/system \
169 --docdir=/usr/share/doc/network-manager-&NetworkManager-version; &amp;&amp;
170make</userinput></screen>
171
172 <para>
173 An already active graphical session with bus address is necessary to run
174 the tests. To test the results, issue: <command>make check</command>.
175 </para>
176
177 <para>
178 Now, as the <systemitem class="username">root</systemitem> user:
179 </para>
180
181<screen role="root"><userinput>make install</userinput></screen>
182
183 </sect2>
184
185 <sect2 role="commands">
186 <title>Command Explanations</title>
187
188 <para>
189 <envar>CXXFLAGS="-O2 -fPIC"</envar>: These compiler options are
190 necessary to build the Qt5 based examples.
191 </para>
192
193 <para>
194 <parameter>--with-nmtui</parameter>: This parameter enables build of
195 <command>nmtui</command>.
196 </para>
197
198 <para revision="systemd">
199 <parameter>--with-session-tracking=systemd</parameter>: This switch
200 is used to set <command>systemd-logind</command> as the default
201 program for session tracking.
202 </para>
203
204 <para revision="sysv">
205 <parameter>--with-systemdsystemunitdir=no</parameter>: systemd is not
206 used for sysv init systems.
207 </para>
208
209 <para revision="systemd">
210 <parameter>--with-systemdsystemunitdir=/lib/systemd/system</parameter>:
211 This switch is used to set the correct installation directory for
212 systemd units.
213 </para>
214
215 <para>
216 <parameter>--disable-ppp</parameter>: This parameter disables
217 <application>PPP</application> support in
218 <application>NetworkManager</application>.
219 </para>
220
221 <para>
222 <parameter>--disable-json-validation</parameter>: This parameter allows
223 building without <application>Jansson</application>, which is needed
224 for <quote>team</quote> configuration validation (team is one way
225 of bonding network interfaces for increased throughput).
226 </para>
227
228 <para>
229 <option>--enable-gtk-doc</option>: Use this switch if you have installed
230 <xref linkend="gtk-doc"/> and wish to build the API manuals.
231 </para>
232
233 <para>
234 <option>--without-iptables</option>: Use this switch if you don't have
235 <application>Iptables</application> installed.
236 </para>
237
238 <para>
239 <option>--disable-introspection</option>: Use this switch if <xref
240 linkend="gobject-introspection"/> is installed and you want to build
241 without introspection support. This also removes the need for <xref
242 linkend="pygobject3"/>.
243 </para>
244
245 </sect2>
246
247 <sect2 role="configuration">
248 <title>Configuring NetworkManager</title>
249
250 <sect3 id="NetworkManager-config">
251 <title>Config Files</title>
252 <para>
253 <filename>/etc/NetworkManager/NetworkManager.conf</filename>
254 </para>
255
256 <indexterm zone="NetworkManager NetworkManager-config">
257 <primary
258 sortas="e-etc-NetworkManager-NetworkManager.conf">
259 /etc/NetworkManager/NetworkManager.conf</primary>
260 </indexterm>
261
262 </sect3>
263
264 <sect3><title>Configuration Information</title>
265
266 <para>
267 For <application>NetworkManager</application> to work, at least
268 a minimal configuration file must be present. Such file is not
269 installed with <command>make install</command>. Issue the following
270 command as the <systemitem class="username">root</systemitem> user to
271 create minimal <filename>NetworkManager.conf</filename> file:
272 </para>
273
274<screen role="root"><userinput>cat &gt;&gt; /etc/NetworkManager/NetworkManager.conf &lt;&lt; "EOF"
275<literal>[main]
276plugins=keyfile</literal>
277EOF</userinput></screen>
278
279 <para>
280 You can add <option>dns=none</option> to suppress changes to
281 <filename>/etc/resolv.conf</filename>. See
282 <command>man 5 NetworkManager.conf</command>
283 for any additional options.
284 </para>
285
286 <para>
287 To allow regular users permission to configure network connections,
288 you should add them to the
289 <systemitem class="groupname">netdev</systemitem>
290 group, and create a <application>polkit</application> rule that grants
291 access. Run the following commands as the
292 <systemitem class="username">root</systemitem> user:
293 </para>
294
295<screen role="root"><userinput>groupadd -fg 86 netdev &amp;&amp;
296/usr/sbin/usermod -a -G netdev <replaceable>&lt;username&gt;</replaceable>
297
298cat &gt; /usr/share/polkit-1/rules.d/org.freedesktop.NetworkManager.rules &lt;&lt; "EOF"
299<literal>polkit.addRule(function(action, subject) {
300 if (action.id.indexOf("org.freedesktop.NetworkManager.") == 0 &amp;&amp; subject.isInGroup("netdev")) {
301 return polkit.Result.YES;
302 }
303});</literal>
304EOF</userinput></screen>
305
306 </sect3>
307
308 <sect3 id="NetworkManager-init">
309 <title><phrase revision="sysv">Boot Script</phrase>
310 <phrase revision="systemd">Systemd Unit</phrase></title>
311
312 <para revision="sysv">
313 To automatically start the <command>NetworkManager</command> daemon
314 when the system is rebooted, install the
315 <filename>/etc/rc.d/init.d/networkmanager</filename>bootscript from the
316 <xref linkend="bootscripts"/> package.
317 </para>
318
319 <para revision="systemd">
320 To start the <command>NetworkManager</command> daemon at boot, enable
321 the previously installed systemd unit by running the following command
322 as the <systemitem class="username">root</systemitem> user:
323 </para>
324
325 <note>
326 <para>
327 If using <application>Network Manager</application> to manage
328 an interface, any previous configuration for that interface should be
329 removed, and the interface brought down prior to starting
330 <application>Network Manager</application>.
331 </para>
332 </note>
333
334 <indexterm zone="NetworkManager NetworkManager-init">
335 <primary sortas="f-NetworkManager">NetworkManager</primary>
336 </indexterm>
337
338<screen role="root" revision="sysv"><userinput>make install-networkmanager</userinput></screen>
339
340<screen role="root" revision="systemd"><userinput>systemctl enable NetworkManager</userinput></screen>
341
342 <para revision="systemd">
343 <application>NetworkManager</application> also ships a systemd unit
344 called <filename>NetworkManager-wait-online.service</filename> which
345 can be used to prevent services that require network connectivity
346 from starting until <application>NetworkManager</application> has
347 established the connection. To enable it, run the following command
348 as the <systemitem class="username">root</systemitem> user:
349 </para>
350
351<screen role="root" revision="systemd"><userinput>systemctl enable NetworkManager-wait-online</userinput></screen>
352
353 </sect3>
354
355 </sect2>
356
357 <sect2 role="content">
358 <title>Contents</title>
359
360 <segmentedlist>
361 <segtitle>Installed Programs</segtitle>
362 <segtitle>Installed Libraries</segtitle>
363 <segtitle>Installed Directories</segtitle>
364
365 <seglistitem>
366 <seg>
367 NetworkManager, nmcli, nm-online, nmtui, and, symlinked to nmtui:
368 nmtui-connect, nmtui-edit, and nmtui-hostname
369 </seg>
370 <seg>
371 libnm-glib.so, libnm-glib-vpn.so, libnm.so, libnm-util.so, and
372 modules under /usr/lib/NetworkManager
373 </seg>
374 <seg>
375 /etc/NetworkManager,
376 /usr/include/{libnm,libnm-glib,NetworkManager},
377 /usr/lib/NetworkManager,
378 /usr/share/doc/NetworkManager-&NetworkManager-version;,
379 /usr/share/gtk-doc/html/{libnm,libnm-glib,libnm-util,NetworkManager}
380 (if the documentation is built),
381 and
382 /var/{lib,run}/NetworkManager
383 </seg>
384 </seglistitem>
385 </segmentedlist>
386
387 <variablelist>
388 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
389 <?dbfo list-presentation="list"?>
390 <?dbhtml list-presentation="table"?>
391
392 <varlistentry id="nmcli">
393 <term><command>nmcli</command></term>
394 <listitem>
395 <para>
396 is a command-line tool for controlling
397 <application>NetworkManager</application>
398 and getting its status.
399 </para>
400 <indexterm zone="NetworkManager nmcli">
401 <primary sortas="b-nmcli">nmcli</primary>
402 </indexterm>
403 </listitem>
404 </varlistentry>
405
406 <varlistentry id="nm-online">
407 <term><command>nm-online</command></term>
408 <listitem>
409 <para>
410 is a utility to find out whether you are online.
411 </para>
412 <indexterm zone="NetworkManager nm-online">
413 <primary sortas="b-nm-online">nm-online</primary>
414 </indexterm>
415 </listitem>
416 </varlistentry>
417
418 <varlistentry id="nmtui">
419 <term><command>nmtui</command></term>
420 <listitem>
421 <para>
422 is an interactive ncurses based interface for
423 <application>nmcli</application>.
424 </para>
425 <indexterm zone="NetworkManager nmtui">
426 <primary sortas="b-nmtui">nmtui</primary>
427 </indexterm>
428 </listitem>
429 </varlistentry>
430
431 <varlistentry id="nmtui-connect">
432 <term><command>nmtui-connect</command></term>
433 <listitem>
434 <para>
435 is an interactive ncurses based interface connection to
436 activate/deactivate connections.
437 </para>
438 <indexterm zone="NetworkManager nmtui-connect">
439 <primary sortas="b-nmtui-connect">nmtui-connect</primary>
440 </indexterm>
441 </listitem>
442 </varlistentry>
443
444 <varlistentry id="nmtui-edit">
445 <term><command>nmtui-edit</command></term>
446 <listitem>
447 <para>
448 is an interactive ncurses based interface connection editor.
449 </para>
450 <indexterm zone="NetworkManager nmtui-edit">
451 <primary sortas="b-nmtui-edit">nmtui-edit</primary>
452 </indexterm>
453 </listitem>
454 </varlistentry>
455
456 <varlistentry id="nmtui-hostname">
457 <term><command>nmtui-hostname</command></term>
458 <listitem>
459 <para>
460 is an interactive ncurses based interface hostname editor.
461 </para>
462 <indexterm zone="NetworkManager nmtui-hostname">
463 <primary sortas="b-nmtui-hostname">nmtui-hostname</primary>
464 </indexterm>
465 </listitem>
466 </varlistentry>
467
468 <varlistentry id="NetworkManager-prog">
469 <term><command>NetworkManager</command></term>
470 <listitem>
471 <para>
472 is the network management daemon.
473 </para>
474 <indexterm zone="NetworkManager NetworkManager-prog">
475 <primary sortas="b-NetworkManager">NetworkManager</primary>
476 </indexterm>
477 </listitem>
478 </varlistentry>
479
480 <varlistentry id="libnm-glib">
481 <term><filename class="libraryfile">libnm-glib.so</filename></term>
482 <listitem>
483 <para>
484 contains functions used by <application>NetworkManager</application>.
485 </para>
486 <indexterm zone="NetworkManager libnm-glib">
487 <primary sortas="c-libnm-glib">libnm-glib.so</primary>
488 </indexterm>
489 </listitem>
490 </varlistentry>
491
492 <varlistentry id="libnm-glib-vpn">
493 <term><filename class="libraryfile">libnm-glib-vpn.so</filename></term>
494 <listitem>
495 <para>
496 contains functions used by <application>NetworkManager</application>
497 VPN plugins.
498 </para>
499 <indexterm zone="NetworkManager libnm-glib-vpn">
500 <primary sortas="c-libnm-glib-vpn">libnm-glib-vpn.so</primary>
501 </indexterm>
502 </listitem>
503 </varlistentry>
504
505 <varlistentry id="libnm-util">
506 <term><filename class="libraryfile">libnm-util.so</filename></term>
507 <listitem>
508 <para>
509 contains functions used by <application>NetworkManager</application>
510 utils.
511 </para>
512 <indexterm zone="NetworkManager libnm-util">
513 <primary sortas="c-libnm-util">libnm-util.so</primary>
514 </indexterm>
515 </listitem>
516 </varlistentry>
517
518 </variablelist>
519
520 </sect2>
521
522</sect1>
Note: See TracBrowser for help on using the repository browser.