Ignore:
Timestamp:
06/11/2016 05:26:20 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, 12.2, 7.10, 8.0, 8.1, 8.2, 8.3, 8.4, 9.0, 9.1, basic, bdubbs/svn, elogind, gimp3, 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/for-12.3, xry111/intltool, xry111/llvm18, xry111/soup3, xry111/spidermonkey128, xry111/test-20220226, xry111/xf86-video-removal
Children:
cec6657e
Parents:
a9e71e2
Message:

[Systemd merge] - Chapter 16

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

File:
1 edited

Legend:

Unmodified
Added
Removed
  • networking/netprogs/samba.xml

    ra9e71e2 r7b478500  
    121121    commands:</para>
    122122
    123 <screen><userinput>./configure                            \
     123<screen revision="sysv"><userinput>./configure                            \
    124124    --prefix=/usr                      \
    125125    --sysconfdir=/etc                  \
     
    130130    --without-ad-dc                    \
    131131    --without-systemd                  &amp;&amp;
     132make</userinput></screen>
     133
     134<screen revision="systemd"><userinput>./configure                            \
     135    --prefix=/usr                      \
     136    --sysconfdir=/etc                  \
     137    --localstatedir=/var               \
     138    --with-piddir=/run/samba           \
     139    --with-pammodulesdir=/lib/security \
     140    --enable-fhs &amp;&amp;
    132141make</userinput></screen>
    133142
     
    183192    a manner compliant with the Filesystem Hierarchy Standard (FHS).</para>
    184193
    185     <para><parameter>--without-systemd</parameter>: Disable
     194    <para revision="sysv"><parameter>--without-systemd</parameter>: Disable
    186195    <application>systemd</application> integration, which is not part of
    187196    LFS/BLFS. If you use <application>systemd</application>, replace by
    188197    <parameter>--with-systemd</parameter>.</para>
    189198
    190     <para><option>--without-ad-dc</option>: Disable Active Directory Domain
    191     Controller functionality. See <ulink
     199    <para revision="sysv"><option>--without-ad-dc</option>: Disable Active
     200    Directory Domain Controller functionality. See <ulink
    192201    url="https://wiki.samba.org/index.php/Setup_a_Samba_Active_Directory_Domain_Controller">
    193202    Setup a Samba Active Directory Domain Controller</ulink> for detailed
    194     information. </para>
     203    information.</para>
    195204
    196205    <para><option>--with-selftest-prefix=SELFTEST_PREFIX</option>: This option
     
    203212    <para><command>ln -v -sf ../../lib/libnss_winbind.so.2 /usr/lib/libnss_winbind.so</command>
    204213    and <command>ln -v -sf ../../lib/libnss_wins.so.2    /usr/lib/libnss_wins.so</command>:
    205     These symlinks are required when applicates build against these libraries.</para>
     214    These symlinks are required when applicationss build against these
     215    libraries.</para>
    206216
    207217    <para><command>install -v -m644 examples/LDAP/* /etc/openldap/schema</command>:
     
    407417      </sect4>
    408418
    409       <sect4 id="samba-init">
     419      <sect4 id="samba-init" revision="sysv">
    410420        <title>Boot Script</title>
    411421
    412422        <para>For your convenience, boot scripts have been provided for
    413423        <application>Samba</application>. There are two included in the
    414         <xref linkend="bootscripts" revision="sysv"/>
    415         <xref linkend="systemd-units" revision="systemd"/> package. The first,
     424        <xref linkend="bootscripts"/> package. The first,
    416425        <filename>samba</filename>, will start the <command>smbd</command>
    417426        and <command>nmbd</command> daemons needed to provide SMB/CIFS
     
    453462<screen role="root"><userinput>make install-winbindd</userinput></screen>
    454463
    455        </sect4>
     464      </sect4>
     465
     466      <sect4 id="samba-init-sysd" revision="systemd">
     467        <title>Systemd Units</title>
     468
     469        <para>The default <application>Samba</application> installation uses the
     470        <systemitem class='username'>nobody</systemitem> user for guest access
     471        to the server. This can be overridden by setting the
     472        <option>guest account =</option> parameter in the
     473        <filename>/etc/samba/smb.conf</filename> file. If you utilize the
     474        <option>guest account =</option> parameter, ensure this user exists in
     475        the <filename>/etc/passwd</filename> file.</para>
     476
     477        <para>
     478          To start the <application>Samba</application> daemons at boot,
     479          install the systemd units from the <xref linkend="systemd-units"/>
     480          package by running the following command as the
     481          <systemitem class="username">root</systemitem> user:
     482        </para>
     483
     484        <indexterm zone="samba samba-init-sysd">
     485          <primary sortas="f-samba">samba</primary>
     486        </indexterm>
     487
     488<screen role="root"><userinput>make install-samba</userinput></screen>
     489
     490        <para>
     491          To start the <command>winbindd</command> daemon at boot,
     492          install the systemd unit from the <xref linkend="systemd-units"/>
     493          package by running the following command as the
     494          <systemitem class="username">root</systemitem> user:
     495        </para>
     496
     497        <indexterm zone="samba samba-init-sysd">
     498          <primary sortas="f-winbindd">winbindd</primary>
     499        </indexterm>
     500
     501<screen role="root"><userinput>make install-winbindd</userinput></screen>
     502
     503        <note>
     504        <para>This package comes with two types of units: A service file and a
     505        socket file. The service file will start the smbd daemon once at boot
     506        and it will keep running until the system shuts down. The socket file
     507        will make systemd listen on the smbd port (Default 445, needs to be
     508        edited for anything else) and will start the smbd daemon when something
     509        tries to connect to that port and stop the daemon when the connection
     510        is terminated. This is called socket activation and is analogous to
     511        using <application>{,x}inetd</application> on a SysVinit based
     512        system.</para>
     513
     514        <para>By default, the first method is used - the smbd daemon is started
     515        at boot and stopped at shutdown. If the socket method is desired, you
     516        need to run the following commands as the
     517        <systemitem class="username">root</systemitem> user:</para>
     518
     519<screen role="root"><userinput>systemctl stop smbd &amp;&amp;
     520systemctl disable smbd &amp;&amp;
     521systemctl enable smbd.socket &amp;&amp;
     522systemctl start smbd.socket</userinput></screen>
     523
     524        <para>Note that only the smbd daemon can be socket activated.</para>
     525        </note>
     526      </sect4>
    456527
    457528    </sect3>
Note: See TracChangeset for help on using the changeset viewer.