source: networking/connect/dhcpcd-systemd.xml@ 032be17

krejzi/svn
Last change on this file since 032be17 was 032be17, checked in by Krejzi <krejzi@…>, 10 years ago

Convert networking/connect, bridge-utils and qemu to systemd.

git-svn-id: svn://svn.linuxfromscratch.org/BLFS/branches/systemd-ng@14737 af4574ff-66df-0310-9fd7-8a98e5e911e0

  • Property mode set to 100644
File size: 8.7 KB
RevLine 
[246c904]1<?xml version="1.0" encoding="ISO-8859-1"?>
[6732c094]2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
[246c904]4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
[14d6b3e0]6
[fefa337]7 <!ENTITY dhcpcd-download-http "http://roy.marples.name/downloads/dhcpcd/dhcpcd-&dhcpcd-version;.tar.bz2">
[a27a478]8 <!ENTITY dhcpcd-download-ftp " ">
9 <!--<!ENTITY dhcpcd-download-ftp "ftp://ftp.osuosl.org/pub/gentoo/distfiles/dhcpcd-&dhcpcd-version;.tar.bz2">-->
[b5a7044]10 <!ENTITY dhcpcd-md5sum "6a421a8b0f19dbcbfca25e64a8ba76f3">
11 <!ENTITY dhcpcd-size "156 KB">
[e1617c94]12 <!ENTITY dhcpcd-buildsize "2.3 MB">
[ed4e5b4]13 <!ENTITY dhcpcd-time "less than 0.1 SBU">
[246c904]14]>
15
[fd680fb]16<sect1 id="dhcpcd" xreflabel="dhcpcd-&dhcpcd-version;">
[820d164a]17 <?dbhtml filename="dhcpcd.html"?>
[4839c17]18
[820d164a]19 <sect1info>
20 <othername>$LastChangedBy$</othername>
21 <date>$Date$</date>
22 </sect1info>
[4839c17]23
[add19ff9]24 <title>dhcpcd-&dhcpcd-version;</title>
[4839c17]25
[820d164a]26 <indexterm zone="dhcpcd">
[add19ff9]27 <primary sortas="a-dhcpcd">dhcpcd</primary>
[820d164a]28 </indexterm>
29
30 <sect2 role="package">
[add19ff9]31 <title>Introduction to dhcpcd</title>
[820d164a]32
[add19ff9]33 <para><application>dhcpcd</application> is an implementation of the
[5aac2b97]34 DHCP client specified in RFC2131. A DHCP client is useful for connecting
[232e46a]35 your computer to a network which uses DHCP to assign network
[0d7900a]36 addresses. dhcpcd strives to be a fully featured, yet very lightweight
[5aac2b97]37 DHCP client.</para>
[4839c17]38
[7031a69]39 &lfs76_checked;
[77ac0f23]40
[032be17]41 <note>
42 <para>
43 Make sure that you disable the <command>systemd-networkd</command> service
44 or configure it not to manage the interfaces you want to manage with
45 <application>dhcpcd</application>.
46 </para>
47 </note>
48
[820d164a]49 <bridgehead renderas="sect3">Package Information</bridgehead>
50 <itemizedlist spacing="compact">
51 <listitem>
52 <para>Download (HTTP): <ulink url="&dhcpcd-download-http;"/></para>
53 </listitem>
54 <listitem>
55 <para>Download (FTP): <ulink url="&dhcpcd-download-ftp;"/></para>
56 </listitem>
57 <listitem>
58 <para>Download MD5 sum: &dhcpcd-md5sum;</para>
59 </listitem>
60 <listitem>
61 <para>Download size: &dhcpcd-size;</para>
62 </listitem>
63 <listitem>
64 <para>Estimated disk space required: &dhcpcd-buildsize;</para>
65 </listitem>
66 <listitem>
67 <para>Estimated build time: &dhcpcd-time;</para>
68 </listitem>
69 </itemizedlist>
[4839c17]70
[4edf8452]71 <bridgehead renderas="sect3">dhcpcd Dependencies</bridgehead>
72
73 <bridgehead renderas="sect4">Optional</bridgehead>
74 <para role="optional">
75 <xref linkend="llvm"/> (with Clang)
76 </para>
77
[7e1f3aa]78 <para condition="html" role="usernotes">User Notes:
79 <ulink url="&blfs-wiki;/dhcpcd"/></para>
80
[820d164a]81 </sect2>
[4839c17]82
[820d164a]83 <sect2 role="installation">
[add19ff9]84 <title>Installation of dhcpcd</title>
[820d164a]85
[032be17]86 <para>
87 First, silence a lot of warnings caused by using the latest toolchain
88 by running the following command:
89 </para>
90
91<screen><userinput>sed -i "s:BSD_SOURCE:DEFAULT_SOURCE:g" configure</userinput></screen>
92
[893d9711]93 <para>Install <application>dhcpcd</application> by running the following
[f9a784a]94 commands:</para>
[820d164a]95
[f0740ab]96<screen><userinput>./configure --libexecdir=/lib/dhcpcd \
[690658a5]97 --dbdir=/var/tmp &amp;&amp;
[f0740ab]98make</userinput></screen>
[f9a784a]99
100 <para>This package does not come with a test suite.</para>
101
102 <para>Now, as the <systemitem class="username">root</systemitem> user:</para>
103
[bfa01156]104<screen role='root'><userinput>make install</userinput></screen>
[4839c17]105
[690658a5]106<!--
[a41f643]107 <para>By default, a plain text lease info file isn't created but the
[a1d3648]108 <application>dhcpcd</application> provides a hook which can be used for creating
109 such a file. Install the hook by running the following
110 commands as the <systemitem class="username">root</systemitem> user:</para>
[232e46a]111
[bfa01156]112<screen role='root'><userinput>sed -i "s;/var/lib;/run;g" dhcpcd-hooks/50-dhcpcd-compat &amp;&amp;
[f9a784a]113install -v -m 644 dhcpcd-hooks/50-dhcpcd-compat /lib/dhcpcd/dhcpcd-hooks/</userinput></screen>
[690658a5]114-->
[4839c17]115
[820d164a]116 </sect2>
[4839c17]117
[690658a5]118 <sect2 role="commands">
119 <title>Command Explanations</title>
120
121 <para>
122 <parameter>--libexecdir=/lib/dhcpcd</parameter>: The default
123 <filename class="directory">/libexec</filename> is not FHS-compliant.
124 Since this directory may need to be available early in the boot,
125 <filename class="directory">/usr/libexec</filename> cannot be used either.
126 </para>
127
128 <para>
129 <parameter>--dbdir=/var/tmp</parameter>: The default
130 <filename class="directory">/var/lib</filename> is not FHS-compliant
131 </para>
132
133 <para>
134 <option>--with-hook=...</option>: You can optionally install more hooks,
135 for example to install some configuration files such as
136 <filename>ntp.conf</filename>. The set of hooks is in the
137 <filename class="directory">dhcpcd-hooks</filename> directory in the
138 build tree.
139 </para>
140 </sect2>
141
[820d164a]142 <sect2 role="configuration">
[add19ff9]143 <title>Configuring dhcpcd</title>
[820d164a]144
145 <sect3 id="dhcpcd-config">
146 <title>Config Files</title>
[4839c17]147
[5aac2b97]148 <para><filename>/etc/dhcpcd.conf</filename></para>
[4839c17]149
[820d164a]150 <indexterm zone="dhcpcd dhcpcd-config">
[fefa337]151 <primary sortas="e-etc-dhcpcd-dhcpcd-conf">/etc/dhcpcd/dhcpcd.conf</primary>
[820d164a]152 </indexterm>
[4839c17]153
[820d164a]154 </sect3>
155
156 <sect3 id="dhcpcd-init">
[e5f38d6b]157 <title>General Configuration Information</title>
[820d164a]158
[032be17]159 <para>
160 If you want to configure network interfaces at boot using
161 <command>dhcpcd</command>, you need to install the
162 systemd unit included in <xref linkend="bootscripts"/>
163 package by running the following command as the
164 <systemitem class="username">root</systemitem> user:
165 </para>
[4839c17]166
[032be17]167<screen role="root"><userinput>make install-dhcpcd</userinput></screen>
[820d164a]168
[032be17]169 <indexterm zone="dhcpcd dhcpcd-init">
170 <primary sortas="f-dhcpcd">dhcpcd</primary>
[820d164a]171 </indexterm>
172
[032be17]173 <para>
174 Whenever <command>dhcpcd</command> configures or shuts down
175 a network interface, it executes hook scripts. For more details
176 about those scripts, see the <command>dhcpcd-run-hooks</command> and
177 <command>dhcpcd</command> man pages.
178 </para>
[4839c17]179
[820d164a]180 <note>
[032be17]181 <para id="dhcpcd-config3">
182 The default behavior of <command>dhcpcd</command> sets the
183 hostname and mtu settings. It also overwrites
184 <filename>/etc/resolv.conf</filename> and
185 <filename>/etc/ntp.conf</filename>.
186
187 These modifications to system files and settings on system
188 configuration files are done by hooks which are stored in
189 <filename class="directory">/lib/dhcpcd/dhcpcd-hooks</filename>.
190
191 Setup <command>dhcpcd</command> by removing or adding hooks from/to
192 that directory. The execution of hooks can be disabled by using the
193 <option>--nohook</option> (<option>-C</option>) command line option or
194 by the <option>nohook</option> option in the
195 <filename>/etc/dhcpcd.conf</filename> file.
196 </para>
[820d164a]197 </note>
[4839c17]198
[820d164a]199 <indexterm zone="dhcpcd dhcpcd-config3">
200 <primary sortas="e-etc-resolv.conf">/etc/resolv.conf</primary>
201 </indexterm>
[4839c17]202
[032be17]203 <para>
204 At this point you can test if <command>dhcpcd</command> is
205 behaving as expected by running the following command as the
206 <systemitem class="username">root</systemitem> user:
207 </para>
[e5f38d6b]208
[032be17]209<screen role="root"><userinput>systemctl start dhcpcd@<replaceable>eth0</replaceable></userinput></screen>
[e5f38d6b]210
[032be17]211 <para>
212 To start <command>dhcpcd</command> on a specific interface
213 at boot, enable the previously installed systemd unit by
214 running the following command as the
215 <systemitem class="username">root</systemitem> user:
216 </para>
[e5f38d6b]217
[032be17]218<screen role="root"><userinput>systemctl enable dhcpcd@<replaceable>eth0</replaceable></userinput></screen>
219
220 <para>
221 Replace <replaceable>eth0</replaceable> with the actual interface name.
222 </para>
[e5f38d6b]223
224 </sect3>
225
[820d164a]226 </sect2>
[4839c17]227
[820d164a]228 <sect2 role="content">
229 <title>Contents</title>
230
231 <segmentedlist>
[032be17]232 <segtitle>Installed Programs</segtitle>
233 <segtitle>Installed Libraries</segtitle>
234 <segtitle>Installed Directories</segtitle>
[4839c17]235
[820d164a]236 <seglistitem>
237 <seg>dhcpcd</seg>
[032be17]238 <seg>None</seg>
[f0740ab]239 <seg>/lib/dhcpcd</seg>
[820d164a]240 </seglistitem>
241 </segmentedlist>
[4839c17]242
[820d164a]243 <variablelist>
244 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
245 <?dbfo list-presentation="list"?>
246 <?dbhtml list-presentation="table"?>
[4839c17]247
[820d164a]248 <varlistentry id="dhcpcd-prog">
249 <term><command>dhcpcd</command></term>
250 <listitem>
[232e46a]251 <para>is an implementation of the DHCP client specified
[f9a784a]252 in RFC2131.</para>
[820d164a]253 <indexterm zone="dhcpcd dhcpcd-prog">
254 <primary sortas="b-dhcpcd">dhcpcd</primary>
255 </indexterm>
256 </listitem>
257 </varlistentry>
[4839c17]258
[820d164a]259 </variablelist>
260
261 </sect2>
[f45b1953]262
263</sect1>
Note: See TracBrowser for help on using the repository browser.