Changeset 019bc05


Ignore:
Timestamp:
10/22/2020 03:18:25 AM (14 months ago)
Author:
Douglas R. Reno <renodr@…>
Branches:
10.1, 11.0, ken/refactor-virt, lazarus, qt5new, trunk, upgradedb, xry111/git-date, xry111/git-date-for-trunk, xry111/git-date-test
Children:
f433fbd
Parents:
279fc64
Message:

Submit systemd-specific configuration for TigerVNC

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

Files:
2 edited

Legend:

Unmodified
Added
Removed
  • introduction/welcome/changelog.xml

    r279fc64 r019bc05  
    4545      <para>October 21st, 2020</para>
    4646      <itemizedlist>
     47        <listitem revision="systemd">
     48          <para>[renodr] - Add configuration instructions for the systemd
     49          variant of TigerVNC.</para>
     50        </listitem>
    4751        <listitem>
    4852          <para>[renodr] - Adapt gnome-nettool to work with current versions of
  • xsoft/other/tigervnc.xml

    r279fc64 r019bc05  
    9595      <listitem>
    9696        <para>
     97          Required patch:
     98          <ulink url="&patch-root;/tigervnc-&tigervnc-version;-configuration_fixes-1.patch"/>
     99        </para>
     100      </listitem>
     101      <listitem>
     102        <para>
    97103          Optional files:
    98104            <itemizedlist spacing="compact">
     
    102108              <listitem>
    103109                <para><ulink url="&sources-anduin-http;/tigervnc/vncserver.1"/></para>
     110              </listitem>
     111              <listitem>
     112                <para><ulink url="&sources-anduin-http;/tigervnc/Xsession"/></para>
    104113              </listitem>
    105114            </itemizedlist>
     
    135144  <sect2 role="installation">
    136145    <title>Installation of Tigervnc</title>
     146
     147    <para>
     148      First, make adjustments to the configuration files to make them
     149      compatible with LFS systems:
     150      <!-- Replaces an incompatible PAM file and disables SELinux support
     151           in systemd units. Also modifies the search path for
     152           /usr/libexec/vncserver to include /etc/X11/tigervnc -->
     153    </para>
     154
     155<screen><userinput remap="pre">patch -Np1 -i ../tigervnc-&tigervnc-version;-configuration_fixes-1.patch</userinput></screen>
    137156
    138157    <para>
     
    188207
    189208[ -e /usr/bin/Xvnc ] || ln -svf $XORG_PREFIX/bin/Xvnc /usr/bin/Xvnc</userinput></screen>
     209
     210   <para revision="sysv">
     211     Finally, modify the PAM file to be compatible with elogind:
     212   </para>
     213
     214<screen role="root" revision="sysv"><userinput>sed -i 's/pam_systemd.so/pam_elogind.so/' /etc/pam.d/tigervnc</userinput></screen>
     215
    190216<!-- These are installed as part of 'make install' for the client.
    191217    <para>
     
    283309    </para>
    284310
     311    <bridgehead renderas="sect3" revision="systemd">Server Configuration</bridgehead>
     312
     313    <note revision="systemd">
     314      <para>
     315        This section is optional and is only useful if you want to have VNC
     316        sessions launch on system startup. Both configuration methods can
     317        coexist on the same system.
     318      </para>
     319    </note>
     320
     321    <para revision="systemd">
     322      On systemd systems, another method of configuration is available.
     323      This configuration provides the added benefit of having a systemd scope
     324      get started for VNC sessions, which allows desktop environments like
     325      <application>GNOME</application> to autostart services once the VNC
     326      session is started. This configuration also gives the added benefit
     327      of starting VNC Sessions on system startup. To setup the VNC server
     328      in this fashion, follow these instructions.
     329    </para>
     330
     331    <para revision="systemd">
     332       First, install a rudimentary Xsession file so that the VNC server
     333       can initialize X sessions properly:
     334    </para>
     335
     336<screen role="root" revision="systemd"><userinput>install -vdm755 /etc/X11/tigervnc &amp;&amp;
     337install -v -m755 ../Xsession /etc/X11/tigervnc</userinput></screen>
     338
     339    <para revision="systemd">
     340      Next, setup a user mapping in
     341      <filename>/etc/tigervnc/vncserver.users</filename>. This tells the VNC
     342      Server which session is allocated to a user.
     343      <!-- For example: :1=renodr will assign 'renodr' to :1 -->
     344    </para>
     345
     346<screen role="root" revision="systemd"><userinput>echo ":1=$(whoami)" >> /etc/tigervnc/vncserver.users</userinput></screen>
     347
     348    <para revision="systemd">
     349      Next, setup a configuration file to tell
     350      <application>vncserver</application> which desktop environment should be
     351      used and what display geometry should be used. There are several other
     352      options that can be defined in this file, but they are outside the scope
     353      of BLFS.
     354    </para>
     355
     356<screen revision="systemd"><userinput>cat &gt; ~/.vnc/config &lt;&lt; EOF
     357<literal># Begin ~/.vnc/config
     358
     359session=LXDE      # The session must match one listed in /usr/share/xsessions.
     360geometry=1024x768
     361
     362# End ~/.vnc/config</literal>
     363EOF</userinput></screen>
     364
     365    <para revision="systemd">
     366      To start the VNC Server, run the following command:
     367    </para>
     368
     369<screen role="root" revision="systemd"><userinput>systemctl start vncserver@:1</userinput></screen>
     370
     371    <para revision="systemd">
     372      To start the VNC Server when the system boots, run the following command:
     373    </para>
     374
     375<screen role="root" revision="systemd"><userinput>systemctl enable vncserver@:1</userinput></screen>
     376
    285377  </sect2>
    286378
Note: See TracChangeset for help on using the changeset viewer.