[ab4fdfc] | 1 | <?xml version="1.0" encoding="UTF-8"?>
|
---|
[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 |
|
---|
[f0ef84e] | 7 | <!ENTITY dhcpcd-download-http "https://github.com/NetworkConfiguration/dhcpcd/releases/download/v&dhcpcd-version;/dhcpcd-&dhcpcd-version;.tar.xz">
|
---|
[4183f95] | 8 | <!ENTITY dhcpcd-download-ftp " ">
|
---|
[af091eb] | 9 | <!ENTITY dhcpcd-md5sum "0a1a9a9f84892af923ec7b273f9af227">
|
---|
| 10 | <!ENTITY dhcpcd-size "268 KB">
|
---|
[4862708] | 11 | <!ENTITY dhcpcd-buildsize "3.0 MB (with tests)">
|
---|
[e0a7d67c] | 12 | <!ENTITY dhcpcd-time "less than 0.1 SBU (with tests)">
|
---|
[246c904] | 13 | ]>
|
---|
| 14 |
|
---|
[fd680fb] | 15 | <sect1 id="dhcpcd" xreflabel="dhcpcd-&dhcpcd-version;">
|
---|
[820d164a] | 16 | <?dbhtml filename="dhcpcd.html"?>
|
---|
[4839c17] | 17 |
|
---|
| 18 |
|
---|
[add19ff9] | 19 | <title>dhcpcd-&dhcpcd-version;</title>
|
---|
[4839c17] | 20 |
|
---|
[820d164a] | 21 | <indexterm zone="dhcpcd">
|
---|
[add19ff9] | 22 | <primary sortas="a-dhcpcd">dhcpcd</primary>
|
---|
[820d164a] | 23 | </indexterm>
|
---|
| 24 |
|
---|
| 25 | <sect2 role="package">
|
---|
[add19ff9] | 26 | <title>Introduction to dhcpcd</title>
|
---|
[820d164a] | 27 |
|
---|
[7c56ece] | 28 | <para>
|
---|
| 29 | <application>dhcpcd</application> is an implementation of the
|
---|
| 30 | DHCP client specified in RFC2131. A DHCP client is useful for connecting
|
---|
| 31 | your computer to a network which uses DHCP to assign network
|
---|
| 32 | addresses. dhcpcd strives to be a fully featured, yet very lightweight
|
---|
| 33 | DHCP client.
|
---|
| 34 | </para>
|
---|
[4839c17] | 35 |
|
---|
[09ddf35a] | 36 | &lfs122_checked;
|
---|
[77ac0f23] | 37 |
|
---|
[820d164a] | 38 | <bridgehead renderas="sect3">Package Information</bridgehead>
|
---|
| 39 | <itemizedlist spacing="compact">
|
---|
| 40 | <listitem>
|
---|
[7c56ece] | 41 | <para>
|
---|
| 42 | Download (HTTP): <ulink url="&dhcpcd-download-http;"/>
|
---|
| 43 | </para>
|
---|
[820d164a] | 44 | </listitem>
|
---|
| 45 | <listitem>
|
---|
[7c56ece] | 46 | <para>
|
---|
| 47 | Download (FTP): <ulink url="&dhcpcd-download-ftp;"/>
|
---|
| 48 | </para>
|
---|
[820d164a] | 49 | </listitem>
|
---|
| 50 | <listitem>
|
---|
[7c56ece] | 51 | <para>
|
---|
| 52 | Download MD5 sum: &dhcpcd-md5sum;
|
---|
| 53 | </para>
|
---|
[820d164a] | 54 | </listitem>
|
---|
| 55 | <listitem>
|
---|
[7c56ece] | 56 | <para>
|
---|
| 57 | Download size: &dhcpcd-size;
|
---|
| 58 | </para>
|
---|
[820d164a] | 59 | </listitem>
|
---|
| 60 | <listitem>
|
---|
[7c56ece] | 61 | <para>
|
---|
| 62 | Estimated disk space required: &dhcpcd-buildsize;
|
---|
| 63 | </para>
|
---|
[820d164a] | 64 | </listitem>
|
---|
| 65 | <listitem>
|
---|
[7c56ece] | 66 | <para>
|
---|
| 67 | Estimated build time: &dhcpcd-time;
|
---|
| 68 | </para>
|
---|
[820d164a] | 69 | </listitem>
|
---|
| 70 | </itemizedlist>
|
---|
[7fbd6ee] | 71 | <!--
|
---|
| 72 |
|
---|
[4839c17] | 73 |
|
---|
[b5639c6] | 74 | <bridgehead renderas="sect3">Additional Downloads</bridgehead>
|
---|
| 75 | <itemizedlist spacing="compact">
|
---|
| 76 | <listitem>
|
---|
| 77 | <para>
|
---|
| 78 | Required patch:
|
---|
| 79 | <ulink url="&patch-root;/dhcpcd-&dhcpcd-version;-upstream_fixes-1.patch"/>
|
---|
| 80 | </para>
|
---|
| 81 | </listitem>
|
---|
| 82 | </itemizedlist>
|
---|
[7fbd6ee] | 83 | -->
|
---|
[b5639c6] | 84 |
|
---|
[4edf8452] | 85 | <bridgehead renderas="sect3">dhcpcd Dependencies</bridgehead>
|
---|
| 86 |
|
---|
| 87 | <bridgehead renderas="sect4">Optional</bridgehead>
|
---|
| 88 | <para role="optional">
|
---|
[7c56ece] | 89 | <xref linkend="llvm"/> (with Clang),
|
---|
| 90 | <xref linkend="ntp"/>,
|
---|
[497d485] | 91 | <ulink url="https://chrony-project.org/">chronyd</ulink>, and
|
---|
[7c56ece] | 92 | <ulink url="https://github.com/thkukuk/ypbind-mt/">ypbind</ulink>
|
---|
[4edf8452] | 93 | </para>
|
---|
| 94 |
|
---|
[820d164a] | 95 | </sect2>
|
---|
[4839c17] | 96 |
|
---|
[2115e38] | 97 | <sect2 id='dhcpcd-privsep'>
|
---|
| 98 | <title>Privilege separation</title>
|
---|
[820d164a] | 99 |
|
---|
[05c8448] | 100 | <para>
|
---|
[2115e38] | 101 | Recent releases of <application>dhcpcd</application> optionally support
|
---|
| 102 | privilege separation. As the practical security benefits of this are
|
---|
| 103 | unclear for a program like <application>dhcpcd</application> and the
|
---|
| 104 | setup is more complicated, the book currently defaults to disable it.
|
---|
| 105 | </para>
|
---|
| 106 | <para>
|
---|
| 107 | If you however would like to use privilege separation, additional
|
---|
| 108 | installation steps are necessary to set up the proper environment. Issue
|
---|
| 109 | the following commands as the
|
---|
| 110 | <systemitem class="username">root</systemitem> user:
|
---|
[05c8448] | 111 | </para>
|
---|
| 112 |
|
---|
| 113 | <screen role="root"><userinput>install -v -m700 -d /var/lib/dhcpcd &&
|
---|
| 114 |
|
---|
| 115 | groupadd -g 52 dhcpcd &&
|
---|
| 116 | useradd -c 'dhcpcd PrivSep' \
|
---|
| 117 | -d /var/lib/dhcpcd \
|
---|
| 118 | -g dhcpcd \
|
---|
[cb37cb79] | 119 | -s /bin/false \
|
---|
[05c8448] | 120 | -u 52 dhcpcd &&
|
---|
| 121 | chown -v dhcpcd:dhcpcd /var/lib/dhcpcd </userinput></screen>
|
---|
| 122 |
|
---|
[2115e38] | 123 | </sect2>
|
---|
| 124 |
|
---|
| 125 | <sect2 role="installation">
|
---|
| 126 | <title>Installation of dhcpcd</title>
|
---|
[d16c71a] | 127 |
|
---|
[7fbd6ee] | 128 | <!--
|
---|
[b5639c6] | 129 | <para>
|
---|
| 130 | First, fix an issue that occurs when running dhcpcd with the '-b' switch:
|
---|
| 131 | </para>
|
---|
| 132 |
|
---|
| 133 | <screen><userinput remap="pre">patch -Np1 -i ../dhcpcd-&dhcpcd-version;-upstream_fixes-1.patch</userinput></screen>
|
---|
| 134 |
|
---|
[7fbd6ee] | 135 | -->
|
---|
[7c56ece] | 136 | <para>
|
---|
[2115e38] | 137 | Build <application>dhcpcd</application> without privilege separation
|
---|
| 138 | by running the following command:
|
---|
| 139 | </para>
|
---|
| 140 |
|
---|
| 141 | <screen><userinput>./configure --prefix=/usr \
|
---|
| 142 | --sysconfdir=/etc \
|
---|
| 143 | --libexecdir=/usr/lib/dhcpcd \
|
---|
| 144 | --dbdir=/var/lib/dhcpcd \
|
---|
| 145 | --runstatedir=/run \
|
---|
| 146 | --disable-privsep &&
|
---|
| 147 | make</userinput></screen>
|
---|
| 148 |
|
---|
| 149 | <para>
|
---|
[a62dc41] | 150 | Alternatively, build <application>dhcpcd</application> with privilege
|
---|
| 151 | separation by running the following commands:
|
---|
[7c56ece] | 152 | </para>
|
---|
[820d164a] | 153 |
|
---|
[40c00c5] | 154 | <screen role="nodump"><userinput>./configure --prefix=/usr \
|
---|
[e1d2da5] | 155 | --sysconfdir=/etc \
|
---|
| 156 | --libexecdir=/usr/lib/dhcpcd \
|
---|
| 157 | --dbdir=/var/lib/dhcpcd \
|
---|
[f713df3] | 158 | --runstatedir=/run \
|
---|
[e1d2da5] | 159 | --privsepuser=dhcpcd &&
|
---|
[f0740ab] | 160 | make</userinput></screen>
|
---|
[f9a784a] | 161 |
|
---|
[7c56ece] | 162 | <para>
|
---|
| 163 | To test the results, issue: <command>make test</command>.
|
---|
| 164 | </para>
|
---|
[f9a784a] | 165 |
|
---|
[7c56ece] | 166 | <para>
|
---|
| 167 | Now, as the <systemitem class="username">root</systemitem> user:
|
---|
| 168 | </para>
|
---|
[f9a784a] | 169 |
|
---|
[bfa01156] | 170 | <screen role='root'><userinput>make install</userinput></screen>
|
---|
[4839c17] | 171 |
|
---|
[690658a5] | 172 | <!--
|
---|
[7c56ece] | 173 | <para>
|
---|
| 174 | By default, a plain text lease info file isn't created but the
|
---|
| 175 | <application>dhcpcd</application> provides a hook which can be used for
|
---|
| 176 | creating such a file. Install the hook by running the following commands
|
---|
| 177 | as the <systemitem class="username">root</systemitem> user:
|
---|
| 178 | </para>
|
---|
[232e46a] | 179 |
|
---|
[bfa01156] | 180 | <screen role='root'><userinput>sed -i "s;/var/lib;/run;g" dhcpcd-hooks/50-dhcpcd-compat &&
|
---|
[f9a784a] | 181 | install -v -m 644 dhcpcd-hooks/50-dhcpcd-compat /lib/dhcpcd/dhcpcd-hooks/</userinput></screen>
|
---|
[690658a5] | 182 | -->
|
---|
[4839c17] | 183 |
|
---|
[820d164a] | 184 | </sect2>
|
---|
[4839c17] | 185 |
|
---|
[690658a5] | 186 | <sect2 role="commands">
|
---|
| 187 | <title>Command Explanations</title>
|
---|
| 188 |
|
---|
| 189 | <para>
|
---|
[a62dc41] | 190 | <parameter>--libexecdir=/usr/lib/dhcpcd</parameter>: This switch sets a
|
---|
| 191 | better location for the dhcpcd internal libraries.
|
---|
[690658a5] | 192 | </para>
|
---|
| 193 |
|
---|
| 194 | <para>
|
---|
[a62dc41] | 195 | <parameter>--dbdir=/var/lib/dhcpcd</parameter>: This switch adjusts the
|
---|
| 196 | database directory because the default directory,
|
---|
| 197 | <filename class="directory">/var/db</filename>, is not FHS-compliant.
|
---|
[690658a5] | 198 | </para>
|
---|
| 199 |
|
---|
[f713df3] | 200 | <para>
|
---|
[a62dc41] | 201 | <parameter>--runstatedir=/run</parameter>: This switch sets the runtime
|
---|
| 202 | state directory because the default
|
---|
[f713df3] | 203 | <filename class="directory">/var/run</filename> is a symbolic
|
---|
[a62dc41] | 204 | link to <filename class="directory">/run</filename>, and using
|
---|
| 205 | <filename class="directory">/var/run</filename> is deprecated.
|
---|
[f713df3] | 206 | </para>
|
---|
| 207 |
|
---|
[690658a5] | 208 | <para>
|
---|
[a62dc41] | 209 | <parameter>--disable-privsep</parameter>: This switch disables privilege
|
---|
| 210 | separation, which is the default in dhcpcd. This switch is not used in
|
---|
| 211 | the build configuration where privilege separation is used.
|
---|
[2115e38] | 212 | </para>
|
---|
| 213 |
|
---|
| 214 | <para>
|
---|
[a62dc41] | 215 | <parameter>--privsepuser=dhcpcd</parameter>: This switch sets the
|
---|
| 216 | privilege separation user in the build configuration where privilege
|
---|
| 217 | escalation is used.
|
---|
[2115e38] | 218 | </para>
|
---|
| 219 |
|
---|
| 220 | <para>
|
---|
| 221 | <option>--with-hook=...</option>: You can optionally install more hooks,
|
---|
| 222 | for example to install some configuration files such as
|
---|
[a62dc41] | 223 | <filename>ntp.conf</filename>. A set of hooks can be found in the
|
---|
[2115e38] | 224 | <filename class="directory">dhcpcd-hooks</filename> directory in the
|
---|
| 225 | build tree.
|
---|
| 226 | </para>
|
---|
[690658a5] | 227 | </sect2>
|
---|
| 228 |
|
---|
[820d164a] | 229 | <sect2 role="configuration">
|
---|
[add19ff9] | 230 | <title>Configuring dhcpcd</title>
|
---|
[820d164a] | 231 |
|
---|
| 232 | <sect3 id="dhcpcd-config">
|
---|
| 233 | <title>Config Files</title>
|
---|
[4839c17] | 234 |
|
---|
[7c56ece] | 235 | <para>
|
---|
| 236 | <filename>/etc/dhcpcd.conf</filename>
|
---|
| 237 | </para>
|
---|
[4839c17] | 238 |
|
---|
[820d164a] | 239 | <indexterm zone="dhcpcd dhcpcd-config">
|
---|
[fefa337] | 240 | <primary sortas="e-etc-dhcpcd-dhcpcd-conf">/etc/dhcpcd/dhcpcd.conf</primary>
|
---|
[820d164a] | 241 | </indexterm>
|
---|
[4839c17] | 242 |
|
---|
[820d164a] | 243 | </sect3>
|
---|
| 244 |
|
---|
[3c7bd00] | 245 | <sect3 id="dhcpcd-init" revision="sysv">
|
---|
[e5f38d6b] | 246 | <title>General Configuration Information</title>
|
---|
[820d164a] | 247 |
|
---|
[7c56ece] | 248 | <para>
|
---|
| 249 | To configure <command>dhcpcd</command>, you need to first install
|
---|
| 250 | the network service script,
|
---|
[e1d2da5] | 251 | <filename>/usr/lib/services/dhcpcd</filename>
|
---|
[7c56ece] | 252 | included in the <xref linkend="bootscripts"/> package
|
---|
| 253 | (as user <systemitem class="username">root</systemitem>):
|
---|
| 254 | </para>
|
---|
[4839c17] | 255 |
|
---|
[820d164a] | 256 | <indexterm zone="dhcpcd dhcpcd-init">
|
---|
| 257 | <primary sortas="f-dhcpcd">dhcpcd (service script)</primary>
|
---|
| 258 | </indexterm>
|
---|
| 259 |
|
---|
| 260 | <screen role='root'><userinput>make install-service-dhcpcd</userinput></screen>
|
---|
| 261 |
|
---|
[7c56ece] | 262 | <note>
|
---|
| 263 | <para id="dhcpcd-config3">
|
---|
| 264 | The default for <command>dhcpcd</command> is to set the hostname
|
---|
| 265 | and mtu. It also overwrites <filename>/etc/resolv.conf </filename>
|
---|
| 266 | and <filename>/etc/ntp.conf</filename>. These
|
---|
| 267 | modifications to system files are done by hooks which are stored in
|
---|
[e1d2da5] | 268 | <filename class="directory">/usr/lib/dhcpcd/dhcpcd-hooks</filename>.
|
---|
[a62dc41] | 269 | You can change this behavior by removing or adding hooks from/to
|
---|
| 270 | that directory. The execution of hooks can be disabled by using
|
---|
[7c56ece] | 271 | the <option>--nohook</option> (<option>-C</option>) command line
|
---|
| 272 | option or by the <option>nohook</option> option in the
|
---|
| 273 | <filename>/etc/dhcpcd.conf</filename> file.
|
---|
| 274 | </para>
|
---|
| 275 | </note>
|
---|
[232e46a] | 276 |
|
---|
[7c56ece] | 277 | <para id="dhcpcd-config2">
|
---|
| 278 | Finally, as the <systemitem class="username">root</systemitem> user
|
---|
| 279 | create the <filename>/etc/sysconfig/ifconfig.eth0</filename>
|
---|
| 280 | configuration file using the following commands. Adjust appropriately
|
---|
| 281 | for additional interfaces:
|
---|
| 282 | </para>
|
---|
[4839c17] | 283 |
|
---|
[820d164a] | 284 | <indexterm zone="dhcpcd dhcpcd-config2">
|
---|
[f0740ab] | 285 | <primary sortas="e-etc-sysconfig-dhcpcd">/etc/sysconfig/ifconfig.eth0 (dhcpcd)</primary>
|
---|
[820d164a] | 286 | </indexterm>
|
---|
| 287 |
|
---|
[f0740ab] | 288 | <screen role='root'><userinput>cat > /etc/sysconfig/ifconfig.eth0 << "EOF"
|
---|
[820d164a] | 289 | <literal>ONBOOT="yes"
|
---|
[f0740ab] | 290 | IFACE="eth0"
|
---|
[afa198d] | 291 | SERVICE="dhcpcd"
|
---|
[1d77de18] | 292 | DHCP_START="-b -q -h $HOSTNAME <replaceable><insert appropriate start options here></replaceable>"
|
---|
[f0740ab] | 293 | DHCP_STOP="-k <replaceable><insert additional stop options here></replaceable>"</literal>
|
---|
[820d164a] | 294 | EOF</userinput></screen>
|
---|
| 295 |
|
---|
[7c56ece] | 296 | <para>
|
---|
| 297 | For more information on the appropriate <envar>DHCP_START</envar> and
|
---|
| 298 | <envar>DHCP_STOP</envar> values, examine the man page for
|
---|
| 299 | <command>dhcpcd</command>.
|
---|
| 300 | </para>
|
---|
[4839c17] | 301 |
|
---|
[820d164a] | 302 | <indexterm zone="dhcpcd dhcpcd-config3">
|
---|
| 303 | <primary sortas="e-etc-resolv.conf">/etc/resolv.conf</primary>
|
---|
| 304 | </indexterm>
|
---|
| 305 | </sect3>
|
---|
[4839c17] | 306 |
|
---|
[3c7bd00] | 307 | <sect3 id="dhcpcd-init2" revision="sysv">
|
---|
[e5f38d6b] | 308 | <title>Configuration Information: fixed ip</title>
|
---|
| 309 |
|
---|
[7c56ece] | 310 | <para id="dhcpcd-config4">
|
---|
| 311 | Although not usual, it is possible that you need
|
---|
[e5f38d6b] | 312 | to configure <application>dhcpcd</application> to use a fixed ip. Here,
|
---|
| 313 | we give an example. As the
|
---|
| 314 | <systemitem class="username">root</systemitem> user create the
|
---|
| 315 | <filename>/etc/sysconfig/ifconfig.eth0</filename> configuration file
|
---|
| 316 | using the following commands. Adjust appropriately for additional
|
---|
[7c56ece] | 317 | interfaces and for the actual ip and router you need:
|
---|
| 318 | </para>
|
---|
[e5f38d6b] | 319 |
|
---|
| 320 | <indexterm zone="dhcpcd dhcpcd-config4">
|
---|
| 321 | <primary sortas="e-etc-sysconfig-dhcpcd">/etc/sysconfig/ifconfig.eth0 (dhcpcd)</primary>
|
---|
| 322 | </indexterm>
|
---|
| 323 |
|
---|
[7c56ece] | 324 | <screen role='nodump'><userinput>cat > /etc/sysconfig/ifconfig.eth0 << "EOF"
|
---|
[e5f38d6b] | 325 | <literal>ONBOOT="yes"
|
---|
| 326 | IFACE="eth0"
|
---|
| 327 | SERVICE="dhcpcd"
|
---|
| 328 | DHCP_START="-b -q -S ip_address=192.168.0.10/24 -S routers=192.168.0.1"
|
---|
| 329 | DHCP_STOP="-k"</literal>
|
---|
| 330 | EOF</userinput></screen>
|
---|
| 331 |
|
---|
[7c56ece] | 332 | <para>
|
---|
| 333 | You can either use DNS servers in
|
---|
[0840866] | 334 | <filename>/etc/resolv.conf</filename> from another system, your
|
---|
| 335 | preferred servers, or just the example
|
---|
[7c56ece] | 336 | <filename>/etc/resolv.conf.head</filename> file below as is:
|
---|
| 337 | </para>
|
---|
[e5f38d6b] | 338 |
|
---|
[7c56ece] | 339 | <screen role='nodump'><userinput>cat > /etc/resolv.conf.head << "EOF"
|
---|
[e5f38d6b] | 340 | <literal># OpenDNS servers
|
---|
| 341 | nameserver 208.67.222.222
|
---|
| 342 | nameserver 208.67.220.220</literal>
|
---|
| 343 | EOF</userinput></screen>
|
---|
| 344 |
|
---|
| 345 | </sect3>
|
---|
| 346 |
|
---|
[138bdf6] | 347 | <sect3 id="dhcpcd-init3" revision="systemd">
|
---|
| 348 | <title>General Configuration Information</title>
|
---|
| 349 |
|
---|
| 350 | <para>
|
---|
| 351 | If you want to configure network interfaces at boot using
|
---|
| 352 | <command>dhcpcd</command>, you need to install the
|
---|
| 353 | systemd unit included in <xref linkend="systemd-units"/>
|
---|
| 354 | package by running the following command as the
|
---|
| 355 | <systemitem class="username">root</systemitem> user:
|
---|
| 356 | </para>
|
---|
| 357 |
|
---|
| 358 | <screen role="root"><userinput>make install-dhcpcd</userinput></screen>
|
---|
| 359 |
|
---|
| 360 | <indexterm zone="dhcpcd dhcpcd-init3">
|
---|
| 361 | <primary sortas="f-dhcpcd">dhcpcd</primary>
|
---|
| 362 | </indexterm>
|
---|
| 363 |
|
---|
| 364 | <note>
|
---|
[7c56ece] | 365 | <para id="dhcpcd-config5">
|
---|
| 366 | The default behavior of <command>dhcpcd</command> is to set the
|
---|
| 367 | hostname and the mtu. It also overwrites <filename>/etc/resolv.conf
|
---|
| 368 | </filename> and <filename>/etc/ntp.conf</filename>. These
|
---|
| 369 | modifications to system configuration files are done by hooks which
|
---|
| 370 | are stored in <filename class="directory">
|
---|
[a62dc41] | 371 | /usr/lib/dhcpcd/dhcpcd-hooks</filename>. You can change this behavior
|
---|
[7c56ece] | 372 | by removing or adding hooks from/to that directory. The execution
|
---|
| 373 | of hooks can be disabled by using the <option>--nohook</option>
|
---|
| 374 | (<option>-C</option>) command line option or by the
|
---|
| 375 | <option>nohook</option> option in the <filename>/etc/dhcpcd.conf
|
---|
| 376 | </filename> file.
|
---|
| 377 | </para>
|
---|
[138bdf6] | 378 | </note>
|
---|
| 379 |
|
---|
| 380 | <indexterm zone="dhcpcd dhcpcd-config5">
|
---|
| 381 | <primary sortas="e-etc-resolv.conf">/etc/resolv.conf</primary>
|
---|
| 382 | </indexterm>
|
---|
| 383 |
|
---|
[7c56ece] | 384 | <note>
|
---|
| 385 | <para>
|
---|
| 386 | Make sure that you disable the <command>systemd-networkd</command>
|
---|
| 387 | service or configure it not to manage the interfaces you want to
|
---|
| 388 | manage with <application>dhcpcd</application>.
|
---|
| 389 | </para>
|
---|
| 390 | </note>
|
---|
[138bdf6] | 391 |
|
---|
| 392 | <para>
|
---|
| 393 | At this point you can test if <command>dhcpcd</command> is
|
---|
| 394 | behaving as expected by running the following command as the
|
---|
| 395 | <systemitem class="username">root</systemitem> user:
|
---|
| 396 | </para>
|
---|
| 397 |
|
---|
| 398 | <screen role="root"><userinput>systemctl start dhcpcd@<replaceable>eth0</replaceable></userinput></screen>
|
---|
| 399 |
|
---|
| 400 | <para>
|
---|
| 401 | To start <command>dhcpcd</command> on a specific interface
|
---|
| 402 | at boot, enable the previously installed systemd unit by
|
---|
| 403 | running the following command as the
|
---|
| 404 | <systemitem class="username">root</systemitem> user:
|
---|
| 405 | </para>
|
---|
| 406 |
|
---|
| 407 | <screen role="root"><userinput>systemctl enable dhcpcd@<replaceable>eth0</replaceable></userinput></screen>
|
---|
| 408 |
|
---|
| 409 | <para>
|
---|
| 410 | Replace <replaceable>eth0</replaceable> with the actual interface name.
|
---|
| 411 | </para>
|
---|
| 412 |
|
---|
| 413 | </sect3>
|
---|
| 414 |
|
---|
[820d164a] | 415 | </sect2>
|
---|
[4839c17] | 416 |
|
---|
[820d164a] | 417 | <sect2 role="content">
|
---|
| 418 | <title>Contents</title>
|
---|
| 419 |
|
---|
| 420 | <segmentedlist>
|
---|
| 421 | <segtitle>Installed Program</segtitle>
|
---|
[d81eda8] | 422 | <segtitle>Installed Library</segtitle>
|
---|
[b1d305ed] | 423 | <segtitle>Installed Directory</segtitle>
|
---|
[4839c17] | 424 |
|
---|
[820d164a] | 425 | <seglistitem>
|
---|
| 426 | <seg>dhcpcd</seg>
|
---|
[e1d2da5] | 427 | <seg>/usr/lib/dhcpcd/dev/udev.so</seg>
|
---|
| 428 | <seg>/{usr,var}/lib/dhcpcd and /usr/share/dhcpcd</seg>
|
---|
[820d164a] | 429 | </seglistitem>
|
---|
| 430 | </segmentedlist>
|
---|
[4839c17] | 431 |
|
---|
[820d164a] | 432 | <variablelist>
|
---|
| 433 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 434 | <?dbfo list-presentation="list"?>
|
---|
| 435 | <?dbhtml list-presentation="table"?>
|
---|
[4839c17] | 436 |
|
---|
[820d164a] | 437 | <varlistentry id="dhcpcd-prog">
|
---|
| 438 | <term><command>dhcpcd</command></term>
|
---|
| 439 | <listitem>
|
---|
[7c56ece] | 440 | <para>
|
---|
[4c24eb0a] | 441 | is an implementation of the DHCP client specified in RFC2131
|
---|
[7c56ece] | 442 | </para>
|
---|
[820d164a] | 443 | <indexterm zone="dhcpcd dhcpcd-prog">
|
---|
| 444 | <primary sortas="b-dhcpcd">dhcpcd</primary>
|
---|
| 445 | </indexterm>
|
---|
| 446 | </listitem>
|
---|
| 447 | </varlistentry>
|
---|
[4839c17] | 448 |
|
---|
[81f1de4] | 449 | <varlistentry id="dhcpcd-udev">
|
---|
| 450 | <term><filename class="libraryfile">udev.so</filename></term>
|
---|
| 451 | <listitem>
|
---|
| 452 | <para>
|
---|
[c93c9bf4] | 453 | adds udev support for interface arrival and departure; this is
|
---|
[81f1de4] | 454 | because udev likes to rename the interface, which it can't do if
|
---|
[4c24eb0a] | 455 | dhcpcd grabs it first
|
---|
[81f1de4] | 456 | </para>
|
---|
| 457 | <indexterm zone="dhcpcd dhcpcd-udev">
|
---|
| 458 | <primary sortas="c-dhcpcd-udev">udev.so</primary>
|
---|
| 459 | </indexterm>
|
---|
| 460 | </listitem>
|
---|
| 461 | </varlistentry>
|
---|
| 462 |
|
---|
[820d164a] | 463 | </variablelist>
|
---|
| 464 |
|
---|
| 465 | </sect2>
|
---|
[f45b1953] | 466 |
|
---|
| 467 | </sect1>
|
---|