Changeset fcceb000


Ignore:
Timestamp:
12/21/2007 05:08:30 PM (16 years ago)
Author:
Alexander E. Patrakov <alexander@…>
Branches:
10.0, 10.1, 11.0, 11.1, 11.2, 11.3, 12.0, 12.1, 6.3, 6.3-rc1, 6.3-rc2, 6.3-rc3, 7.10, 7.4, 7.5, 7.6, 7.6-blfs, 7.6-systemd, 7.7, 7.8, 7.9, 8.0, 8.1, 8.2, 8.3, 8.4, 9.0, 9.1, basic, bdubbs/svn, elogind, gnome, kde5-13430, kde5-14269, kde5-14686, kea, ken/TL2024, ken/inkscape-core-mods, ken/tuningfonts, krejzi/svn, lazarus, lxqt, nosym, perl-modules, plabs/newcss, plabs/python-mods, python3.11, qt5new, rahul/power-profiles-daemon, renodr/vulkan-addition, systemd-11177, systemd-13485, trunk, upgradedb, xry111/intltool, xry111/llvm18, xry111/soup3, xry111/test-20220226, xry111/xf86-video-removal
Children:
c21b2c7
Parents:
d118bb3
Message:

Updated the text about default mount options.

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

Files:
3 edited

Legend:

Unmodified
Added
Removed
  • general.ent

    rd118bb3 rfcceb000  
    44-->
    55
    6 <!ENTITY day          "19">                   <!-- Always 2 digits -->
     6<!ENTITY day          "21">                   <!-- Always 2 digits -->
    77<!ENTITY month        "12">                   <!-- Always 2 digits -->
    88<!ENTITY year         "2007">
    99<!ENTITY version      "svn-&year;&month;&day;">
    10 <!ENTITY releasedate  "December &day;th, &year;">
     10<!ENTITY releasedate  "December &day;st, &year;">
    1111<!ENTITY pubdate      "&year;-&month;-&day;"> <!-- metadata req. by TLDP -->
    1212<!ENTITY blfs-version "svn">                  <!-- svn|[release #] -->
  • general/sysutils/hal.xml

    rd118bb3 rfcceb000  
    310310      url="http://ivman.sourceforge.net/">Ivman</ulink> should be
    311311      installed.</para>
    312 
    313       <!-- Following note is only relevant for HAL-0.5.7.x.
    314            Fixed upstream. -->
    315       <note>
    316         <para><application>HAL</application> will ignore any devices listed
    317         in <filename>/etc/fstab</filename> for the purpose of automounting.
    318         You must remove any listings for devices that you would like
    319         automounted such as CD-ROMs or USB keys.</para>
    320       </note>
    321 
    322     <!-- This section commented out for now until it is determined what should
    323          be placed in this section
    324 
    325          FIXME: I think this information is still relevant with the
    326          exception of its interaction with /etc/fstab. Needs investigation.
    327 
    328       <para>No configuration is necessary for the majority of installations
    329       on systems configured with ISO-8859-1 compatible locales. The defaults
    330       should work just fine. For some installations, tweaking of the various
    331       policies may be required. One such configuration change necessary in some
    332       locales is identifying the <option>iocharset</option> and
    333       <option>codepage</option> variables in the
    334       <filename>/etc/fstab</filename> entries created by the
    335       <command>fstab-sync</command> program. If changes are required to the
    336       configuration so that your locale is properly identified in the entries
    337       created in <filename>/etc/fstab</filename>, issue the following commands
    338       as the <systemitem class="username">root</systemitem> user (you must
    339       substitute the proper data for the
    340       <replaceable>&lt;iocharset&gt;</replaceable> and
    341       <replaceable>&lt;codepage&gt;</replaceable> info):</para>
     312      <!-- FIXME: is Ivman still alive? -->
     313
     314      <para>In some cases, it is necessary to specify some default mount
     315      options for filesystems. E.g., in non-English environments, the
     316      <option>iocharset</option> and <option>codepage</option> options
     317      are needed for filesystems with Windows origin in order to show
     318      national characters correctly. Also, due to a
     319      <ulink url="https://launchpad.net/bugs/133567">bug</ulink> in the
     320      Linux kernel version in LFS (2.6.22.x), you may want to pass the
     321      <option>usefree</option> options to vfat filesystems in order to reduce
     322      the time needed to determine the amount of free space on the
     323      filesystem.</para>
     324
     325      <para>Google search results for <quote>hal default mount options</quote>
     326      are still full of recommendations to create <filename>*.fdi</filename>
     327      files mentioning either
     328      <option>volume.policy</option> or <option>storage.ploicy</option> keys.
     329      Such recommendations worked for HAL-0.4.x only and are invalid now.
     330      For HAL-&hal-version;, mount options are expected to be handled
     331      as follows:</para>
     332
     333      <itemizedlist>
     334        <listitem>
     335          <para>An event handler from the desktop environment receives an
     336          event describing the newly-added storage device.</para>
     337        </listitem>
     338        <listitem>
     339          <para>If the storage device is not already mentioned in
     340          <filename>/etc/fstab</filename>, mount options are fetched from
     341          a database of user preferences, which is specific to the desktop
     342          environment, and passed back to HAL.
     343          This process can be influenced by the filesystem type
     344          and possibly other volume properties available from HAL.</para>
     345        </listitem>
     346        <listitem>
     347          <para>If the options are in the list of permitted ones, HAL
     348          mounts the volume.</para>
     349        </listitem>
     350      </itemizedlist>
     351
     352      <para>The important point above is that the configuration procedure is
     353      desktop-specific. However, as of December, 2007, only GNOME allows the
     354      user to set default mount options on a per-filesystem basis. To do so,
     355      change the
     356      <systemitem>/system/storage/default_options/[fs_type]/mount_options</systemitem>
     357      GConf key either using <xref linkend="gconf-editor"/>, or from the
     358      command line, as demonstrated in the following example:</para>
     359
     360<screen><userinput>gconftool-2 --type list --list-type=string \
     361    --set /system/storage/default_options/vfat/mount_options \
     362    "[shortname=mixed,uid=,usefree,iocharset=koi8-r,codepage=866]"</userinput></screen>
     363
     364      <para>See more details in the gnome-mount(1) manual page.</para>
     365     
     366      <para>KDE allows the mount options to be set only on a per-volume basis,
     367      not per-filesystem, which is a
     368      <ulink url="http://bugs.kde.org/show_bug.cgi?id=133456">bug</ulink>,
     369      because, as mentioned in the report, <quote>for every new device (let's
     370      say your friend USB stick) you have to first not mount it, then change
     371      options and then mount</quote>. Xfce, if compiled with HAL support,
     372      <ulink url="http://bugzilla.xfce.org/show_bug.cgi?id=2891">hard-codes</ulink>
     373      the mount options without any means to override them,
     374      which is even worse.
     375      <!-- (for BLFS editors only: they mention policy-kit as a future
     376           solution, but, from the description, policy-kit looks like
     377           an XML-ized sudo-like confguration parser, which has nothing
     378           common with the "default mount options" problem. -->
     379      In these desktop environments, if the built-in
     380      default mount options are not suitable, it is needed to mention every
     381      possible removable storage device in <filename>/etc/fstab</filename>
     382      with the correct options, thus mostly defeating the point of
     383      installing HAL.</para>
     384
     385      <para>If HAL does not accept new mount options by default,
     386      (in the above example, this happens with the <option>usefree</option>
     387      option), as <systemitem class="username">root</systemitem> user,
     388      create a custom policy file that mentions unknown mount options:</para>
    342389
    343390<screen role="root"><userinput>install -v -m755 -d /etc/hal/fdi/policy/30user &amp;&amp;
    344 cat &gt; /etc/hal/fdi/policy/30user/30user-policy.fdi &lt;&lt; "EOF"
     391cat &gt; /etc/hal/fdi/policy/30user/30user-options.fdi &lt;&lt; "EOF"
    345392<literal>&lt;?xml version="1.0" encoding="UTF-8"?&gt; &lt;!- -*- SGML -*- -&gt;
    346393
     
    353400
    354401&lt;deviceinfo version="0.2"&gt;
    355 
    356402  &lt;device&gt;
    357     &lt;match key="info.udi"
    358         string="/org/freedesktop/Hal/devices/computer"&gt;
    359 
    360       &lt;!- Set the iocharset variable in the /etc/fstab file entry -&gt;
    361       &lt;merge
    362         key="storage.policy.default.mount_option.iocharset=<replaceable>&lt;iocharset&gt;</replaceable>"
    363         type="bool"&gt;true&lt;/merge&gt;
    364 
    365       &lt;!- Set the codepage variable in the /etc/fstab file entry -&gt;
    366       &lt;merge
    367         key="storage.policy.default.mount_option.codepage=<replaceable>&lt;codepage&gt;</replaceable>"
    368         type="bool"&gt;true&lt;/merge&gt;
    369 
     403
     404    &lt;!-- this is to be able to mount media in drives we cannot poll,
     405         e.g. IDE Zip Drives and PC style floppy drives --&gt;
     406    &lt;match key="storage.media_check_enabled" bool="false"&gt;
     407      &lt;match key="storage.no_partitions_hint" bool="true"&gt;
     408        &lt;append key="volume.mount.valid_options" type="strlist"&gt;usefree&lt;/append&gt;
     409      &lt;/match&gt;
    370410    &lt;/match&gt;
     411
     412    &lt;match key="volume.fsusage" string="filesystem"&gt;
     413
     414      &lt;!-- allow these mount options for vfat --&gt;
     415      &lt;match key="volume.fstype" string="vfat"&gt;
     416        &lt;append key="volume.mount.valid_options" type="strlist"&gt;usefree&lt;/append&gt;
     417      &lt;/match&gt;
     418    &lt;/match&gt;
     419
    371420  &lt;/device&gt;
    372 
    373421&lt;/deviceinfo&gt;</literal>
    374 
    375422EOF</userinput></screen>
    376 
    377       <note>
    378         <para>The previous commands created a file named
    379         <filename>/etc/hal/fdi/policy/30user/30user-policy.fdi</filename>. To
    380         ease readability of the file, put everything between the
    381         &lt;angle brackets&gt; and &lt;merge&gt;&lt;/merge&gt; tags on one
    382         line. You must have at least one space character
    383         where the ends of the lines were. The file would then look like this
    384         (trimmed at the top and bottom for brevity):</para>
    385 
    386 <screen><literal>  &lt;device&gt;
    387     &lt;match key="<replaceable>&lt;text&gt;</replaceable>" string="<replaceable>&lt;text&gt;</replaceable>"&gt;
    388 
    389       &lt;!- Set the iocharset variable in the /etc/fstab file entry -&gt;
    390       &lt;merge key="<replaceable>&lt;iocharset text&gt;</replaceable>" type="bool"&gt;true&lt;/merge&gt;
    391 
    392       &lt;!- Set the codepage variable in the /etc/fstab file entry -&gt;
    393       &lt;merge key="<replaceable>&lt;codepage text&gt;</replaceable>" type="bool"&gt;true&lt;/merge&gt;
    394 
    395     &lt;/match&gt;
    396   &lt;/device&gt;</literal></screen>
    397 
    398       </note>
    399 
    400     -->
    401423
    402424    </sect3>
  • introduction/welcome/changelog.xml

    rd118bb3 rfcceb000  
    4141
    4242-->
     43
     44    <listitem>
     45      <para>December 21st, 2007</para>
     46      <itemizedlist>
     47        <listitem>
     48          <para>[alexander] - Updated the text about default mount options
     49          on the HAL page.</para>
     50        </listitem>
     51      </itemizedlist>
     52    </listitem>
    4353
    4454    <listitem>
Note: See TracChangeset for help on using the changeset viewer.