[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">
|
---|
[232e46a] | 8 | <!ENTITY dhcpcd-download-ftp "ftp://ftp.osuosl.org/pub/gentoo/distfiles/dhcpcd-&dhcpcd-version;.tar.bz2">
|
---|
[a90cb6a] | 9 | <!ENTITY dhcpcd-md5sum "b9f1ccdaaf23ffea7dd6fd89e932f4ed">
|
---|
[837ee667] | 10 | <!ENTITY dhcpcd-size "51 KB">
|
---|
[a5404840] | 11 | <!ENTITY dhcpcd-buildsize "0.3 MB">
|
---|
[ed4e5b4] | 12 | <!ENTITY dhcpcd-time "less than 0.1 SBU">
|
---|
[246c904] | 13 | ]>
|
---|
| 14 |
|
---|
[fd680fb] | 15 | <sect1 id="dhcpcd" xreflabel="dhcpcd-&dhcpcd-version;">
|
---|
[820d164a] | 16 | <?dbhtml filename="dhcpcd.html"?>
|
---|
[4839c17] | 17 |
|
---|
[820d164a] | 18 | <sect1info>
|
---|
| 19 | <othername>$LastChangedBy$</othername>
|
---|
| 20 | <date>$Date$</date>
|
---|
| 21 | </sect1info>
|
---|
[4839c17] | 22 |
|
---|
[add19ff9] | 23 | <title>dhcpcd-&dhcpcd-version;</title>
|
---|
[4839c17] | 24 |
|
---|
[820d164a] | 25 | <indexterm zone="dhcpcd">
|
---|
[add19ff9] | 26 | <primary sortas="a-dhcpcd">dhcpcd</primary>
|
---|
[820d164a] | 27 | </indexterm>
|
---|
| 28 |
|
---|
| 29 | <sect2 role="package">
|
---|
[add19ff9] | 30 | <title>Introduction to dhcpcd</title>
|
---|
[820d164a] | 31 |
|
---|
[add19ff9] | 32 | <para><application>dhcpcd</application> is an implementation of the
|
---|
[232e46a] | 33 | DHCP client specified in RFC2131. This is useful for connecting
|
---|
| 34 | your computer to a network which uses DHCP to assign network
|
---|
| 35 | addresses.</para>
|
---|
[4839c17] | 36 |
|
---|
[820d164a] | 37 | <bridgehead renderas="sect3">Package Information</bridgehead>
|
---|
| 38 | <itemizedlist spacing="compact">
|
---|
| 39 | <listitem>
|
---|
| 40 | <para>Download (HTTP): <ulink url="&dhcpcd-download-http;"/></para>
|
---|
| 41 | </listitem>
|
---|
| 42 | <listitem>
|
---|
| 43 | <para>Download (FTP): <ulink url="&dhcpcd-download-ftp;"/></para>
|
---|
| 44 | </listitem>
|
---|
| 45 | <listitem>
|
---|
| 46 | <para>Download MD5 sum: &dhcpcd-md5sum;</para>
|
---|
| 47 | </listitem>
|
---|
| 48 | <listitem>
|
---|
| 49 | <para>Download size: &dhcpcd-size;</para>
|
---|
| 50 | </listitem>
|
---|
| 51 | <listitem>
|
---|
| 52 | <para>Estimated disk space required: &dhcpcd-buildsize;</para>
|
---|
| 53 | </listitem>
|
---|
| 54 | <listitem>
|
---|
| 55 | <para>Estimated build time: &dhcpcd-time;</para>
|
---|
| 56 | </listitem>
|
---|
| 57 | </itemizedlist>
|
---|
[4839c17] | 58 |
|
---|
[7e1f3aa] | 59 | <para condition="html" role="usernotes">User Notes:
|
---|
| 60 | <ulink url="&blfs-wiki;/dhcpcd"/></para>
|
---|
| 61 |
|
---|
[820d164a] | 62 | </sect2>
|
---|
[4839c17] | 63 |
|
---|
[820d164a] | 64 | <sect2 role="installation">
|
---|
[add19ff9] | 65 | <title>Installation of dhcpcd</title>
|
---|
[820d164a] | 66 |
|
---|
[893d9711] | 67 | <para>Install <application>dhcpcd</application> by running the following
|
---|
[f9a784a] | 68 | commands:</para>
|
---|
[820d164a] | 69 |
|
---|
[fefa337] | 70 | <screen><userinput>make PREFIX= \
|
---|
[f9a784a] | 71 | LIBEXECDIR=/lib/dhcpcd \
|
---|
| 72 | DBDIR=/var/lib/dhcpcd \
|
---|
| 73 | SYSCONFDIR=/etc/dhcpcd</userinput></screen>
|
---|
| 74 |
|
---|
| 75 | <para>This package does not come with a test suite.</para>
|
---|
| 76 |
|
---|
| 77 | <para>Now, as the <systemitem class="username">root</systemitem> user:</para>
|
---|
| 78 |
|
---|
| 79 | <screen><userinput>make PREFIX= \
|
---|
| 80 | LIBEXECDIR=/lib/dhcpcd \
|
---|
| 81 | DBDIR=/var/lib/dhcpcd \
|
---|
| 82 | SYSCONFDIR=/etc/dhcpcd install</userinput></screen>
|
---|
[4839c17] | 83 |
|
---|
[fefa337] | 84 | <para>By default, a plain text lease info file isn't created but the
|
---|
| 85 | <application>dhcpcd</application> provides a hook which can be used for creating
|
---|
| 86 | such a file. Install the hook by running the following
|
---|
| 87 | commands as the <systemitem class="username">root</systemitem> user:</para>
|
---|
[232e46a] | 88 |
|
---|
[fefa337] | 89 | <screen><userinput>sed -i "s;/var/lib/dhcpcd-;/var/lib/dhcpcd/dhcpcd-;g" \
|
---|
[f9a784a] | 90 | dhcpcd-hooks/50-dhcpcd-compat &&
|
---|
| 91 | install -v -m 644 dhcpcd-hooks/50-dhcpcd-compat /lib/dhcpcd/dhcpcd-hooks/</userinput></screen>
|
---|
[4839c17] | 92 |
|
---|
[820d164a] | 93 | </sect2>
|
---|
[4839c17] | 94 |
|
---|
[820d164a] | 95 | <sect2 role="configuration">
|
---|
[add19ff9] | 96 | <title>Configuring dhcpcd</title>
|
---|
[820d164a] | 97 |
|
---|
| 98 | <sect3 id="dhcpcd-config">
|
---|
| 99 | <title>Config Files</title>
|
---|
[4839c17] | 100 |
|
---|
[fefa337] | 101 | <para><filename>/etc/dhcpcd/dhcpcd.conf</filename></para>
|
---|
[4839c17] | 102 |
|
---|
[820d164a] | 103 | <indexterm zone="dhcpcd dhcpcd-config">
|
---|
[fefa337] | 104 | <primary sortas="e-etc-dhcpcd-dhcpcd-conf">/etc/dhcpcd/dhcpcd.conf</primary>
|
---|
[820d164a] | 105 | </indexterm>
|
---|
[4839c17] | 106 |
|
---|
[820d164a] | 107 | </sect3>
|
---|
| 108 |
|
---|
| 109 | <sect3 id="dhcpcd-init">
|
---|
| 110 | <title>Configuration Information</title>
|
---|
| 111 |
|
---|
| 112 | <para>To configure <command>dhcpcd</command>, you need to first install
|
---|
| 113 | the network service script,
|
---|
| 114 | <filename>/etc/sysconfig/network-devices/services/dhcpcd</filename>
|
---|
[5254d12] | 115 | included in the <xref linkend="bootscripts"/> package
|
---|
[820d164a] | 116 | (as user <systemitem class="username">root</systemitem>):</para>
|
---|
[4839c17] | 117 |
|
---|
[820d164a] | 118 | <indexterm zone="dhcpcd dhcpcd-init">
|
---|
| 119 | <primary sortas="f-dhcpcd">dhcpcd (service script)</primary>
|
---|
| 120 | </indexterm>
|
---|
| 121 |
|
---|
| 122 | <screen role='root'><userinput>make install-service-dhcpcd</userinput></screen>
|
---|
| 123 |
|
---|
[232e46a] | 124 | <para>Whenever <command>dhcpcd</command> configures or shuts down
|
---|
[fefa337] | 125 | a network interface, it executes hook scripts. For more details
|
---|
| 126 | about those scripts, see the <command>dhcpcd-run-hooks</command> as
|
---|
| 127 | well as the <command>dhcpcd</command> man page.</para>
|
---|
[232e46a] | 128 |
|
---|
[893d9711] | 129 | <para id="dhcpcd-config2">Finally, as the <systemitem
|
---|
[820d164a] | 130 | class="username">root</systemitem> user create the
|
---|
[4839c17] | 131 | <filename>/etc/sysconfig/network-devices/ifconfig.eth0/dhcpcd</filename>
|
---|
[893d9711] | 132 | configuration file using the following commands. Adjust appropriately
|
---|
[820d164a] | 133 | for additional interfaces:</para>
|
---|
[4839c17] | 134 |
|
---|
[820d164a] | 135 | <indexterm zone="dhcpcd dhcpcd-config2">
|
---|
| 136 | <primary sortas="e-etc-sysconfig-dhcpcd">/etc/sysconfig/.../dhcpcd</primary>
|
---|
| 137 | </indexterm>
|
---|
| 138 |
|
---|
[e3353b3] | 139 | <screen role='root'><userinput>install -v -d /etc/sysconfig/network-devices/ifconfig.eth0 &&
|
---|
[820d164a] | 140 | cat > /etc/sysconfig/network-devices/ifconfig.eth0/dhcpcd << "EOF"
|
---|
| 141 | <literal>ONBOOT="yes"
|
---|
[afa198d] | 142 | SERVICE="dhcpcd"
|
---|
[7e1f3aa] | 143 | DHCP_START="<replaceable><insert appropriate start options here></replaceable>"
|
---|
| 144 | DHCP_STOP="-k <replaceable><insert additional stop options here></replaceable>"
|
---|
[00f97e91] | 145 |
|
---|
[893d9711] | 146 | # Set PRINTIP="yes" to have the script print
|
---|
[7ee9849] | 147 | # the DHCP assigned IP address
|
---|
[00f97e91] | 148 | PRINTIP="no"
|
---|
| 149 |
|
---|
[893d9711] | 150 | # Set PRINTALL="yes" to print the DHCP assigned values for
|
---|
[7ee9849] | 151 | # IP, SM, DG, and 1st NS. This requires PRINTIP="yes".
|
---|
[820d164a] | 152 | PRINTALL="no"</literal>
|
---|
| 153 | EOF</userinput></screen>
|
---|
| 154 |
|
---|
[893d9711] | 155 | <para>For more information on the appropriate <envar>DHCP_START</envar> and
|
---|
| 156 | <envar>DHCP_STOP</envar> values, examine the man page for
|
---|
[820d164a] | 157 | <command>dhcpcd</command>.</para>
|
---|
[4839c17] | 158 |
|
---|
[820d164a] | 159 | <note>
|
---|
[fefa337] | 160 | <para id="dhcpcd-config3">The default behavior of <command>dhcpcd</command>
|
---|
| 161 | is to overwrite <filename>/etc/resolv.conf</filename>. All modifications on
|
---|
| 162 | system configuration files like <filename>/etc/resolv.conf</filename>,
|
---|
| 163 | <filename>/etc/yp.conf</filename> and <filename>/etc/ntp.conf</filename> are
|
---|
[f9a784a] | 164 | done by hooks which are stored in <filename class="directory">/lib/dhcpcd/dhcpcd-hooks</filename>.
|
---|
[fefa337] | 165 | Setup <command>dhcpcd</command> by removing or adding hooks from/to that directory.
|
---|
[f9a784a] | 166 | The execution of hooks can be disabled by using the -C command line option.</para>
|
---|
| 167 | <para>Review the <command>dhcpcd</command> man page for switches to add to the
|
---|
[820d164a] | 168 | <envar>DHCP_START</envar> value.</para>
|
---|
| 169 | </note>
|
---|
[4839c17] | 170 |
|
---|
[820d164a] | 171 | <indexterm zone="dhcpcd dhcpcd-config3">
|
---|
| 172 | <primary sortas="e-etc-resolv.conf">/etc/resolv.conf</primary>
|
---|
| 173 | </indexterm>
|
---|
[fefa337] | 174 | <!-- These are not modified by default with version 4 of dhcpcd
|
---|
[820d164a] | 175 | <indexterm zone="dhcpcd dhcpcd-config3">
|
---|
| 176 | <primary sortas="e-etc-yp.conf">/etc/yp.conf</primary>
|
---|
| 177 | </indexterm>
|
---|
[4839c17] | 178 |
|
---|
[820d164a] | 179 | <indexterm zone="dhcpcd dhcpcd-config3">
|
---|
| 180 | <primary sortas="e-etc-ntp.conf">/etc/ntp.conf</primary>
|
---|
| 181 | </indexterm>
|
---|
[fefa337] | 182 | -->
|
---|
[820d164a] | 183 | </sect3>
|
---|
[4839c17] | 184 |
|
---|
[820d164a] | 185 | </sect2>
|
---|
[4839c17] | 186 |
|
---|
[820d164a] | 187 | <sect2 role="content">
|
---|
| 188 | <title>Contents</title>
|
---|
| 189 |
|
---|
| 190 | <segmentedlist>
|
---|
| 191 | <segtitle>Installed Program</segtitle>
|
---|
| 192 | <segtitle>Installed Libraries</segtitle>
|
---|
[b1d305ed] | 193 | <segtitle>Installed Directory</segtitle>
|
---|
[4839c17] | 194 |
|
---|
[820d164a] | 195 | <seglistitem>
|
---|
| 196 | <seg>dhcpcd</seg>
|
---|
| 197 | <seg>None</seg>
|
---|
[f9a784a] | 198 | <seg>/lib/dhcpcd, /etc/dhcpcd</seg>
|
---|
[820d164a] | 199 | </seglistitem>
|
---|
| 200 | </segmentedlist>
|
---|
[4839c17] | 201 |
|
---|
[820d164a] | 202 | <variablelist>
|
---|
| 203 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 204 | <?dbfo list-presentation="list"?>
|
---|
| 205 | <?dbhtml list-presentation="table"?>
|
---|
[4839c17] | 206 |
|
---|
[820d164a] | 207 | <varlistentry id="dhcpcd-prog">
|
---|
| 208 | <term><command>dhcpcd</command></term>
|
---|
| 209 | <listitem>
|
---|
[232e46a] | 210 | <para>is an implementation of the DHCP client specified
|
---|
[f9a784a] | 211 | in RFC2131.</para>
|
---|
[820d164a] | 212 | <indexterm zone="dhcpcd dhcpcd-prog">
|
---|
| 213 | <primary sortas="b-dhcpcd">dhcpcd</primary>
|
---|
| 214 | </indexterm>
|
---|
| 215 | </listitem>
|
---|
| 216 | </varlistentry>
|
---|
[4839c17] | 217 |
|
---|
[820d164a] | 218 | </variablelist>
|
---|
| 219 |
|
---|
| 220 | </sect2>
|
---|
[f45b1953] | 221 |
|
---|
| 222 | </sect1>
|
---|