Ignore:
Timestamp:
06/09/2016 05:34:10 AM (8 years ago)
Author:
DJ Lucas <dj@…>
Branches:
10.0, 10.1, 11.0, 11.1, 11.2, 11.3, 12.0, 12.1, 7.10, 8.0, 8.1, 8.2, 8.3, 8.4, 9.0, 9.1, basic, bdubbs/svn, elogind, kea, ken/TL2024, ken/inkscape-core-mods, ken/tuningfonts, lazarus, lxqt, nosym, perl-modules, plabs/newcss, plabs/python-mods, python3.11, qt5new, rahul/power-profiles-daemon, renodr/vulkan-addition, trunk, upgradedb, xry111/intltool, xry111/llvm18, xry111/soup3, xry111/test-20220226, xry111/xf86-video-removal
Children:
2bbb3379
Parents:
0098ace6
Message:

[Systemd merge] - Chapter 14

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

File:
1 edited

Legend:

Unmodified
Added
Removed
  • networking/connect/dhcpcd.xml

    r0098ace6 r138bdf6  
    240240nameserver 208.67.220.220</literal>
    241241EOF</userinput></screen>
     242
     243    </sect3>
     244
     245   <sect3 id="dhcpcd-init3" revision="systemd">
     246      <title>General Configuration Information</title>
     247
     248      <para>
     249        If you want to configure network interfaces at boot using
     250        <command>dhcpcd</command>, you need to install the
     251        systemd unit included in <xref linkend="systemd-units"/>
     252        package by running the following command as the
     253        <systemitem class="username">root</systemitem> user:
     254      </para>
     255
     256<screen role="root"><userinput>make install-dhcpcd</userinput></screen>
     257
     258      <indexterm zone="dhcpcd dhcpcd-init3">
     259        <primary sortas="f-dhcpcd">dhcpcd</primary>
     260      </indexterm>
     261
     262      <para>
     263        Whenever <command>dhcpcd</command> configures or shuts down
     264        a network interface, it executes hook scripts. For more details
     265        about those scripts, see the <command>dhcpcd-run-hooks</command> and
     266        <command>dhcpcd</command> man pages.
     267      </para>
     268
     269      <note>
     270        <para id="dhcpcd-config5">The default behavior of
     271        <command>dhcpcd</command> sets the hostname and mtu settings. It also
     272        overwrites <filename>/etc/resolv.conf</filename> and
     273        <filename>/etc/ntp.conf</filename>.
     274
     275        These modifications to system files and settings on system
     276        configuration files are done by hooks which are stored in <filename
     277        class="directory">/lib/dhcpcd/dhcpcd-hooks</filename>.
     278
     279        Setup <command>dhcpcd</command> by removing or adding hooks from/to
     280        that directory.  The execution of hooks can be disabled by using the
     281        <option>--nohook</option> (<option>-C</option>) command line option or
     282        by the <option>nohook</option> option in the
     283        <filename>/etc/dhcpcd.conf</filename> file.</para>
     284      </note>
     285
     286      <indexterm zone="dhcpcd dhcpcd-config5">
     287        <primary sortas="e-etc-resolv.conf">/etc/resolv.conf</primary>
     288      </indexterm>
     289
     290    <note>
     291      <para>
     292        Make sure that you disable the <command>systemd-networkd</command>
     293        service or configure it not to manage the interfaces you want to manage
     294        with <application>dhcpcd</application>.
     295      </para>
     296    </note>
     297
     298      <para>
     299        At this point you can test if <command>dhcpcd</command> is
     300        behaving as expected by running the following command as the
     301        <systemitem class="username">root</systemitem> user:
     302      </para>
     303
     304<screen role="root"><userinput>systemctl start dhcpcd@<replaceable>eth0</replaceable></userinput></screen>
     305
     306      <para>
     307        To start <command>dhcpcd</command> on a specific interface
     308        at boot, enable the previously installed systemd unit by
     309        running the following command as the
     310        <systemitem class="username">root</systemitem> user:
     311      </para>
     312
     313<screen role="root"><userinput>systemctl enable dhcpcd@<replaceable>eth0</replaceable></userinput></screen>
     314
     315      <para>
     316        Replace <replaceable>eth0</replaceable> with the actual interface name.
     317      </para>
    242318
    243319    </sect3>
Note: See TracChangeset for help on using the changeset viewer.