Changeset e0d33ef
- Timestamp:
- 05/30/2005 09:56:30 PM (19 years ago)
- Branches:
- 10.0, 10.1, 11.0, 11.1, 11.2, 11.3, 12.0, 12.1, 6.1, 6.2, 6.2.0, 6.2.0-rc1, 6.2.0-rc2, 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:
- 3aa07d1
- Parents:
- f009801
- Location:
- postlfs/config
- Files:
-
- 10 edited
Legend:
- Unmodified
- Added
- Removed
-
postlfs/config/autofs.xml
rf009801 re0d33ef 32 32 <para>The <application>autofs</application> package contains userspace 33 33 tools that work with the kernel to mount and un-mount removable file 34 systems. This is useful for allowing users to mount floppies, cdroms and 34 systems. This is useful for allowing users to mount floppies, cdroms and 35 35 other removable storage devices without requiring the system 36 administrator to mount the devices. This may not be ideal for all 36 administrator to mount the devices. This may not be ideal for all 37 37 installations, so be aware of the risks before implementing this feature.</para> 38 38 … … 121 121 <title>Installation of Autofs</title> 122 122 123 <para>Install <application>autofs</application> by running the following 123 <para>Install <application>autofs</application> by running the following 124 124 commands:</para> 125 125 … … 202 202 </note> 203 203 204 <para>While this package could be used to mount NFS shares and SMB 205 shares, that feature is not configured in these instructions. NFS shares 204 <para>While this package could be used to mount NFS shares and SMB 205 shares, that feature is not configured in these instructions. NFS shares 206 206 are covered on the next page.</para> 207 207 … … 209 209 working hardware. The loaded configuration file should load your cdrom 210 210 if <filename>/dev/cdrom</filename> is active or it can be edited to 211 match your device setup and examples for floppies are available in the file 211 match your device setup and examples for floppies are available in the file 212 212 and easily activated. Documentation for this file is available using the 213 213 <command>man 5 autofs</command> command.</para> … … 219 219 220 220 221 <para>Install the <filename>/etc/rc.d/init.d/autofs</filename> mount script 222 and <filename>/etc/sysconfig/autofs.conf</filename> support file included 221 <para>Install the <filename>/etc/rc.d/init.d/autofs</filename> mount script 222 and <filename>/etc/sysconfig/autofs.conf</filename> support file included 223 223 with the <xref linkend="intro-important-bootscripts"/> package.</para> 224 224 … … 232 232 <filename>/etc/sysconfig/autofs.conf</filename>. The installed file sets 233 233 a default of 60 seconds of inactivity before unmounting the device. A 234 much shorter time may be necessary to protect buffer writing to a floppy 234 much shorter time may be necessary to protect buffer writing to a floppy 235 235 if users tend to remove the media prior to the timeout setting.</para> 236 236 … … 262 262 <term><command>automount</command></term> 263 263 <listitem> 264 <para>is the daemon that performs the mounting when a request is 264 <para>is the daemon that performs the mounting when a request is 265 265 made for the device.</para> 266 266 <indexterm zone="autofs automount"> -
postlfs/config/compressdoc.xml
rf009801 re0d33ef 23 23 bzip2'ed pages, a feature you can use to free some disk space while keeping 24 24 your documentation available. However, things are not that simple; man 25 directories tend to contain links—hard and symbolic—which defeat 26 simple ideas like recursively calling <command>gzip</command> on them. A 25 directories tend to contain links—hard and symbolic—which defeat 26 simple ideas like recursively calling <command>gzip</command> on them. A 27 27 better way to go is to use the script below.</para> 28 28 … … 43 43 # to allow for a backup, to allow to keep the newest version of a page. 44 44 # 45 # Modified 20040330 by Tushar Teredesai to replace $0 by the name of the 45 # Modified 20040330 by Tushar Teredesai to replace $0 by the name of the 46 46 # script. 47 47 # (Note: It is assumed that the script is in the user's PATH) … … 53 53 # - choose a default compress method to be based on the available 54 54 # tool : gzip or bzip2; 55 # - offer an option to automagically choose the best compression 56 # methed on a per page basis (eg. check which of 55 # - offer an option to automagically choose the best compression 56 # methed on a per page basis (eg. check which of 57 57 # gzip/bzip2/whatever is the most effective, page per page); 58 58 # - when a MANPATH env var exists, use this instead of /etc/man.conf … … 78 78 79 79 --backup Specify a .tar backup shall be done for all directories. 80 In case a backup already exists, it is saved as .tar.old 81 prior to making the new backup. If a .tar.old backup 80 In case a backup already exists, it is saved as .tar.old 81 prior to making the new backup. If a .tar.old backup 82 82 exists, it is removed prior to saving the backup. 83 83 In backup mode, no other action is performed. … … 85 85 And where options are : 86 86 -1 to -9, --fast, --best 87 The compression level, as accepted by gzip and bzip2. 88 When not specified, uses the default compression level 89 for the given method (-6 for gzip, and -9 for bzip2). 87 The compression level, as accepted by gzip and bzip2. 88 When not specified, uses the default compression level 89 for the given method (-6 for gzip, and -9 for bzip2). 90 90 Not used when in backup or decompress modes. 91 91 92 --force, -F Force (re-)compression, even if the previous one was 93 the same method. Useful when changing the compression 94 ratio. By default, a page will not be re-compressed if 95 it ends with the same suffix as the method adds 92 --force, -F Force (re-)compression, even if the previous one was 93 the same method. Useful when changing the compression 94 ratio. By default, a page will not be re-compressed if 95 it ends with the same suffix as the method adds 96 96 (.bz2 for bzip2, .gz for gzip). 97 97 98 --soft, -S Change hard-links into soft-links. Use with _caution_ 99 as the first encountered file will be used as a 98 --soft, -S Change hard-links into soft-links. Use with _caution_ 99 as the first encountered file will be used as a 100 100 reference. Not used when in backup mode. 101 101 102 --hard, -H Change soft-links into hard-links. Not used when in 102 --hard, -H Change soft-links into hard-links. Not used when in 103 103 backup mode. 104 104 … … 106 106 Specify the location of man.conf. Defaults to /etc. 107 107 108 --verbose, -v Verbose mode, print the name of the directory being 109 processed. Double the flag to turn it even more verbose, 108 --verbose, -v Verbose mode, print the name of the directory being 109 processed. Double the flag to turn it even more verbose, 110 110 and to print the name of the file being processed. 111 111 112 112 --fake, -f Fakes it. Print the actual parameters compman will use. 113 113 114 dirs A list of space-separated _absolute_ pathnames to the 115 man directories. When empty, and only then, parse 114 dirs A list of space-separated _absolute_ pathnames to the 115 man directories. When empty, and only then, parse 116 116 ${MAN_CONF}/man.conf for all occurrences of MANPATH. 117 117 … … 120 120 both gzip and bzip2 on man pages, taking into account the hosting fs, 121 121 the architecture, etc... On the overall, the conclusion was that gzip 122 was much more efficient on 'small' files, and bzip2 on 'big' files, 122 was much more efficient on 'small' files, and bzip2 on 'big' files, 123 123 small and big being very dependent on the content of the files. 124 124 125 See the original post from Mickael A. Peters, titled 125 See the original post from Mickael A. Peters, titled 126 126 "Bootable Utility CD", dated 20030409.1816(+0200), and subsequent posts: 127 127 http://linuxfromscratch.org/pipermail/blfs-support/2003-April/038817.html 128 128 129 On my system (x86, ext3), man pages were 35564KB before compression. 130 gzip -9 compressed them down to 20372KB (57.28%), bzip2 -9 got down to 129 On my system (x86, ext3), man pages were 35564KB before compression. 130 gzip -9 compressed them down to 20372KB (57.28%), bzip2 -9 got down to 131 131 19812KB (55.71%). That is a 1.57% gain in space. YMMV. 132 132 133 What was not taken into consideration was the decompression speed. But 134 does it make sense to? You gain fast access with uncompressed man 135 pages, or you gain space at the expense of a slight overhead in time. 133 What was not taken into consideration was the decompression speed. But 134 does it make sense to? You gain fast access with uncompressed man 135 pages, or you gain space at the expense of a slight overhead in time. 136 136 Well, my P4-2.5GHz does not even let me notice this... :-) 137 137 … … 140 140 } 141 141 142 # This function checks that the man page is unique amongst bzip2'd, 142 # This function checks that the man page is unique amongst bzip2'd, 143 143 # gzip'd and uncompressed versions. 144 144 # $1 the directory in which the file resides 145 145 # $2 the file name for the man page 146 # Returns 0 (true) if the file is the latest and must be taken care of, 147 # and 1 (false) if the file is not the latest (and has therefore been 146 # Returns 0 (true) if the file is the latest and must be taken care of, 147 # and 1 (false) if the file is not the latest (and has therefore been 148 148 # deleted). 149 149 function check_unique () … … 177 177 MY_NAME=`basename $0` 178 178 179 # OK, parse the command-line for arguments, and initialize to some 180 # sensible state, that is: don't change links state, parse 181 # /etc/man.conf, be most silent, search man.conf in /etc, and don't 179 # OK, parse the command-line for arguments, and initialize to some 180 # sensible state, that is: don't change links state, parse 181 # /etc/man.conf, be most silent, search man.conf in /etc, and don't 182 182 # force (re-)compression. 183 183 COMP_METHOD= … … 258 258 ;; 259 259 *) 260 echo "\"$1\" is not an absolute path name" 260 echo "\"$1\" is not an absolute path name" 261 261 exit 1 262 262 ;; … … 286 286 esac 287 287 288 # Note: on my machine, 'man --path' gives /usr/share/man twice, once 288 # Note: on my machine, 'man --path' gives /usr/share/man twice, once 289 289 # with a trailing '/', once without. 290 290 if [ -z "$MAN_DIR" ]; then … … 319 319 echo "man.conf is.......: ${MAN_CONF}/man.conf" 320 320 echo -n "Hard-links........: " 321 [ "foo$LN_OPT" = "foo-S" ] && 321 [ "foo$LN_OPT" = "foo-S" ] && 322 322 echo "convert to soft-links" || echo "leave as is" 323 323 echo -n "Soft-links........: " 324 [ "foo$LN_OPT" = "foo-H" ] && 324 [ "foo$LN_OPT" = "foo-H" ] && 325 325 echo "convert to hard-links" || echo "leave as is" 326 326 echo "Backup............: $BACKUP" … … 344 344 echo "Backing up $DIR..." > $DEST_FD0 345 345 [ -f "${DIR_NAME}.tar.old" ] && rm -f "${DIR_NAME}.tar.old" 346 [ -f "${DIR_NAME}.tar" ] && 346 [ -f "${DIR_NAME}.tar" ] && 347 347 mv "${DIR_NAME}.tar" "${DIR_NAME}.tar.old" 348 348 tar -cfv "${DIR_NAME}.tar" "${DIR_NAME}" > $DEST_FD1 … … 361 361 362 362 # Fixes the case when hard-links see their compression scheme change 363 # (from not compressed to compressed, or from bz2 to gz, or from gz 363 # (from not compressed to compressed, or from bz2 to gz, or from gz 364 364 # to bz2) 365 # Also fixes the case when multiple version of the page are present, 365 # Also fixes the case when multiple version of the page are present, 366 366 # which are either compressed or not. 367 367 if [ ! -L "$FILE" -a ! -e "$FILE" ]; then continue; fi … … 371 371 372 372 if [ -d "$FILE" ]; then 373 cd "${MEM_DIR}" # Go back to where we ran "$0", 373 cd "${MEM_DIR}" # Go back to where we ran "$0", 374 374 # in case "$0"=="./compressdoc" ... 375 375 # We are going recursive to that directory … … 426 426 # Take care of hard-links: build the list of files hard-linked 427 427 # to the one we are {de,}compressing. 428 # NB. This is not optimum has the file will eventually be 429 # compressed as many times it has hard-links. But for now, 428 # NB. This is not optimum has the file will eventually be 429 # compressed as many times it has hard-links. But for now, 430 430 # that's the safe way. 431 431 inode=`ls -li "$FILE" | awk '{print $1}'` … … 483 483 484 484 else 485 # There is a problem when we get neither a symlink nor a plain 485 # There is a problem when we get neither a symlink nor a plain 486 486 # file. Obviously, we shall never ever come here... :-( 487 487 echo -n "Whaooo... \"${DIR}/${FILE}\" is neither a symlink " … … 497 497 chmod 755 /usr/sbin/compressdoc</userinput></screen> 498 498 499 <para>Now, as <systemitem class="username">root</systemitem>, you can issue a 500 <command>compressdoc --bz2</command> to compress all your system man 501 pages. You can also run <command>compressdoc --help</command> to get 499 <para>Now, as <systemitem class="username">root</systemitem>, you can issue a 500 <command>compressdoc --bz2</command> to compress all your system man 501 pages. You can also run <command>compressdoc --help</command> to get 502 502 comprehensive help about what the script is able to do.</para> 503 503 504 <para> Don't forget that a few programs, like the <application>X Window 505 System</application> and <application>XEmacs</application> also 506 install their documentation in non standard places (such as 507 <filename class="directory">/usr/X11R6/man</filename>, etc...). Be sure 508 to add these locations to the file <filename>/etc/man.conf</filename>, as a 504 <para> Don't forget that a few programs, like the <application>X Window 505 System</application> and <application>XEmacs</application> also 506 install their documentation in non standard places (such as 507 <filename class="directory">/usr/X11R6/man</filename>, etc...). Be sure 508 to add these locations to the file <filename>/etc/man.conf</filename>, as a 509 509 <envar>MANPATH</envar>=<replaceable>[/path]</replaceable> section.</para> 510 510 … … 518 518 ...</literal></screen> 519 519 520 <para>Generally, package installation systems do not compress man/info pages, 521 which means you will need to run the script again if you want to keep the size 520 <para>Generally, package installation systems do not compress man/info pages, 521 which means you will need to run the script again if you want to keep the size 522 522 of your documentation as small as possible. Also, note that running the script 523 after upgrading a package is safe; when you have several versions of a page 523 after upgrading a package is safe; when you have several versions of a page 524 524 (for example, one compressed and one uncompressed), the most recent one is kept 525 525 and the others deleted.</para> -
postlfs/config/config.xml
rf009801 re0d33ef 11 11 <title>After LFS Configuration Issues</title> 12 12 13 <para>The intention of LFS is to provide a basic system which you can 14 build upon. There are several things, about tidying up the system, which 13 <para>The intention of LFS is to provide a basic system which you can 14 build upon. There are several things, about tidying up the system, which 15 15 many people wonder about once they have done the base install. 16 16 We hope to cover these issues in this chapter.</para> 17 17 18 18 <para>Most people coming from non-Unix like backgrounds to Linux find the 19 concept of text-only configuration files slightly strange. In Linux, just 20 about all configuration is done via text files. The majority of these files 21 can be found in the <filename>/etc</filename> hierarchy. There are often 22 graphical configuration programs available for different subsystems but most 23 are simply pretty front ends to the process of editing the file. The advantage 24 of text-only configuration is that you can edit parameters using your favorite 25 text editor, whether that be <command>vim</command>, 19 concept of text-only configuration files slightly strange. In Linux, just 20 about all configuration is done via text files. The majority of these files 21 can be found in the <filename>/etc</filename> hierarchy. There are often 22 graphical configuration programs available for different subsystems but most 23 are simply pretty front ends to the process of editing the file. The advantage 24 of text-only configuration is that you can edit parameters using your favorite 25 text editor, whether that be <command>vim</command>, 26 26 <command>emacs</command>, or anything else.</para> 27 27 … … 29 29 critical need. Then the system is configured to ease addition of 30 30 new users, in <xref linkend="postlfs-config-bootdisk"/>, because this 31 can affect the choices you make in the two subsequent topics—<xref 31 can affect the choices you make in the two subsequent topics—<xref 32 32 linkend="postlfs-config-profile"/> and <xref linkend="postlfs-config-vimrc"/>.</para> 33 33 34 <para> The remaining topics, <xref linkend="postlfs-config-logon"/>, 35 <xref linkend="postlfs-config-shells"/>, <xref linkend="postlfs-config-random"/>, 36 <xref linkend="compressdoc"/>, <xref linkend="autofs"/>, and 37 <xref linkend="postlfs-config-netfs"/> are then addressed, in that order. They 34 <para> The remaining topics, <xref linkend="postlfs-config-logon"/>, 35 <xref linkend="postlfs-config-shells"/>, <xref linkend="postlfs-config-random"/>, 36 <xref linkend="compressdoc"/>, <xref linkend="autofs"/>, and 37 <xref linkend="postlfs-config-netfs"/> are then addressed, in that order. They 38 38 don't have much interaction with the other topics in this chapter.</para> 39 39 -
postlfs/config/etcshells.xml
rf009801 re0d33ef 20 20 </indexterm> 21 21 22 <para>The <filename>shells</filename> file contains a list of 22 <para>The <filename>shells</filename> file contains a list of 23 23 login shells on the system. Applications use this file to determine 24 24 whether a shell is valid. For each shell a single line should be … … 31 31 32 32 <para>It is a requirement for applications such as 33 <application>GDM</application> which does not populate the 34 face browser if it can't find <filename>/etc/shells</filename> or 35 FTP daemons which traditionally disallow access to users 33 <application>GDM</application> which does not populate the 34 face browser if it can't find <filename>/etc/shells</filename> or 35 FTP daemons which traditionally disallow access to users 36 36 with shells not included in this file.</para> 37 37 -
postlfs/config/inputrc.xml
rf009801 re0d33ef 24 24 </indexterm> 25 25 26 <para><filename>/etc/inputrc</filename> deals with the mapping of the 26 <para><filename>/etc/inputrc</filename> deals with the mapping of the 27 27 keyboard for certain situations. This file is the start-up file used by 28 <application>readline</application>, the input related library used by 28 <application>readline</application>, the input related library used by 29 29 <application>bash</application> and most other shells.</para> 30 30 31 31 <para>For more information see <command>info bash</command>—<emphasis 32 32 role="strong">Node: Readline Init</emphasis> file as well as 33 <command>info readline</command>. There is a lot that can be done with this 33 <command>info readline</command>. There is a lot that can be done with this 34 34 one rc file.</para> 35 35 … … 42 42 If you want your system to use both, or don't want <emphasis>global</emphasis> 43 43 keyboard handling, it is a good idea to place a default 44 <filename>.inputrc</filename> into the <filename 44 <filename>.inputrc</filename> into the <filename 45 45 class="directory">/etc/skel</filename> directory for use with new users.</para> 46 46 … … 50 50 51 51 <para>If you will create an <filename>.inputrc</filename> in 52 <filename class="directory">/etc/skel</filename> using the command below, 53 change the command's output to <filename>/etc/skel/.inputrc</filename> and 52 <filename class="directory">/etc/skel</filename> using the command below, 53 change the command's output to <filename>/etc/skel/.inputrc</filename> and 54 54 be sure to check/set permissions afterward. Then you can just copy that 55 55 file to <filename>/etc/inputrc</filename> and the home directory 56 of any user already existing in the system, including <systemitem 56 of any user already existing in the system, including <systemitem 57 57 class="username">root</systemitem>, that needs 58 58 a private version of the file. Be sure to use the <option>-p</option> 59 parameter of <command>cp</command> to maintain permissions and be sure to 59 parameter of <command>cp</command> to maintain permissions and be sure to 60 60 change owner and group appropriately.</para> 61 61 … … 67 67 68 68 # Enable 8bit input 69 set meta-flag On 69 set meta-flag On 70 70 set input-meta On 71 71 … … 79 79 set bell-style none 80 80 81 # All of the following map the escape sequence of the 82 # value contained inside the 1st argument to the 81 # All of the following map the escape sequence of the 82 # value contained inside the 1st argument to the 83 83 # readline specific functions 84 84 -
postlfs/config/logon.xml
rf009801 re0d33ef 20 20 </indexterm> 21 21 22 <para>When you first boot up your new LFS system, the logon screen will 23 be nice and plain (as it should be in a bare-bones system). Many people 24 however, will want their system to display some information in the logon 25 message. This can be accomplished using the 22 <para>When you first boot up your new LFS system, the logon screen will 23 be nice and plain (as it should be in a bare-bones system). Many people 24 however, will want their system to display some information in the logon 25 message. This can be accomplished using the 26 26 file <filename>/etc/issue</filename>.</para> 27 27 … … 30 30 insert information about the system. There is also the file 31 31 <filename>issue.net</filename> which can be used when logging on remotely. 32 <command>ssh</command> however, will only use it if you set the option in the 33 configuration file and will also <emphasis>not</emphasis> interpret the 32 <command>ssh</command> however, will only use it if you set the option in the 33 configuration file and will also <emphasis>not</emphasis> interpret the 34 34 escape sequences shown below.</para> 35 35 36 36 <para>One of the most common things which people want to do is to clear 37 the screen at each logon. The easiest way of doing that is to put a "clear" 38 escape-sequence into <filename>/etc/issue</filename>. A simple way of 37 the screen at each logon. The easiest way of doing that is to put a "clear" 38 escape-sequence into <filename>/etc/issue</filename>. A simple way of 39 39 doing this is to do <command>clear > /etc/issue</command>. 40 40 This will insert the relevant escape code into the start of the 41 <filename>/etc/issue</filename> file. Note that if you do this, when you 41 <filename>/etc/issue</filename> file. Note that if you do this, when you 42 42 edit the file, you should leave the ^[c character on the first line alone.</para> 43 43 44 44 <para>The following escapes are recognized by <command>agetty</command> 45 (the program which usually parses <filename>/etc/issue</filename>). This 46 information is from <command>man agetty</command> where you can find 45 (the program which usually parses <filename>/etc/issue</filename>). This 46 information is from <command>man agetty</command> where you can find 47 47 extra information about the logon process.</para> 48 48 49 <para>The <filename>issue</filename> file can contain certain escape codes to 50 display various information. All escape codes consist of a backslash (\) 51 immediately followed by one of the letters explained below (so 52 <option>\d</option> in <filename>/etc/issue</filename> would 49 <para>The <filename>issue</filename> file can contain certain escape codes to 50 display various information. All escape codes consist of a backslash (\) 51 immediately followed by one of the letters explained below (so 52 <option>\d</option> in <filename>/etc/issue</filename> would 53 53 insert the current date).</para> 54 54 -
postlfs/config/netfs.xml
rf009801 re0d33ef 21 21 </indexterm> 22 22 23 <para>While LFS is capable of mounting network file systems such as NFS, 24 these are not mounted by the <filename>mountfs</filename> init script. 25 Network file systems must be mounted after the networking is activated and 23 <para>While LFS is capable of mounting network file systems such as NFS, 24 these are not mounted by the <filename>mountfs</filename> init script. 25 Network file systems must be mounted after the networking is activated and 26 26 unmounted before the network goes down. The <filename>netfs</filename> 27 bootscript was written to handle both boot-time mounting of network 28 filesystems, if the entry in <filename>/etc/fstab</filename> contains the 29 <option>_netdev</option> option, and unmounting of all network filesystems 27 bootscript was written to handle both boot-time mounting of network 28 filesystems, if the entry in <filename>/etc/fstab</filename> contains the 29 <option>_netdev</option> option, and unmounting of all network filesystems 30 30 before the network is brought down.</para> 31 31 32 <para>As the <systemitem class="username">root</systemitem> user, install 33 the <filename>/etc/rc.d/init.d/netfs</filename> bootscript included with the 32 <para>As the <systemitem class="username">root</systemitem> user, install 33 the <filename>/etc/rc.d/init.d/netfs</filename> bootscript included with the 34 34 <xref linkend="intro-important-bootscripts"/> package.</para> 35 35 -
postlfs/config/random.xml
rf009801 re0d33ef 21 21 22 22 <para>The Linux kernel supplies a random number generator which is accessed 23 through <filename class="devicefile">/dev/random</filename> and 24 <filename class="devicefile">/dev/urandom</filename>. Programs that utilize 25 the random and urandom devices, such as <application>OpenSSH</application>, 23 through <filename class="devicefile">/dev/random</filename> and 24 <filename class="devicefile">/dev/urandom</filename>. Programs that utilize 25 the random and urandom devices, such as <application>OpenSSH</application>, 26 26 will benefit from these instructions.</para> 27 27 … … 33 33 start-ups.</para> 34 34 35 <para>Install the <filename>/etc/rc.d/init.d/random</filename> init script 35 <para>Install the <filename>/etc/rc.d/init.d/random</filename> init script 36 36 included with the <xref linkend="intro-important-bootscripts"/> package.</para> 37 37 -
postlfs/config/skel.xml
rf009801 re0d33ef 25 25 26 26 <para>Together, the <command>/usr/sbin/useradd</command> command and 27 <filename class="directory">/etc/skel</filename> directory (both are easy to 28 setup and use) provide a way to assure new users are added on your LFS 29 system with the same beginning settings for things like <envar>PATH</envar>, 30 keyboard processing and environmental variables. Using these two facilities 27 <filename class="directory">/etc/skel</filename> directory (both are easy to 28 setup and use) provide a way to assure new users are added on your LFS 29 system with the same beginning settings for things like <envar>PATH</envar>, 30 keyboard processing and environmental variables. Using these two facilities 31 31 makes it easier to assure this initial state for each new user.</para> 32 32 33 <para>The <filename class="directory">/etc/skel</filename> directory holds 34 copies of various initialization and other files that may be copied to the 33 <para>The <filename class="directory">/etc/skel</filename> directory holds 34 copies of various initialization and other files that may be copied to the 35 35 new user's home directory when the <command>/usr/sbin/useradd</command> 36 36 program adds the new user.</para> … … 41 41 default values kept in <filename>/etc/default/useradd</filename>, 42 42 if it exists. If the file does not exist, then it uses some internal 43 defaults. You can see the default values by running 43 defaults. You can see the default values by running 44 44 <command>/usr/sbin/useradd -D</command>.</para> 45 45 46 46 <para>To change these values to something new, create a base <filename> 47 /etc/default/useradd</filename> file with the same values as the output of 47 /etc/default/useradd</filename> file with the same values as the output of 48 48 <command>/usr/sbin/useradd -D</command>. Here is a sample.</para> 49 49 … … 64 64 <screen role="root"><userinput>/usr/sbin/useradd -D -s/bin/bash</userinput></screen> 65 65 66 <para>This will set the <envar>SHELL</envar>= line to 66 <para>This will set the <envar>SHELL</envar>= line to 67 67 <envar>SHELL</envar>=/bin/bash.</para> 68 68 … … 74 74 <bridgehead renderas="sect5">/etc/skel</bridgehead> 75 75 76 <para>To get started, create an <filename 77 class="directory">/etc/skel</filename> directory and make sure it is 78 writable only by the system administrator, usually <systemitem 79 class="username">root</systemitem>. Creating the 80 directory as <systemitem class="username">root</systemitem> is 76 <para>To get started, create an <filename 77 class="directory">/etc/skel</filename> directory and make sure it is 78 writable only by the system administrator, usually <systemitem 79 class="username">root</systemitem>. Creating the 80 directory as <systemitem class="username">root</systemitem> is 81 81 the best way to go.</para> 82 82 83 83 <para>The mode of any files from this part of the book that you put in 84 <filename class="directory">/etc/skel</filename> should be writable only by 85 the owner. Also, since there is no telling what kind of sensitive information 84 <filename class="directory">/etc/skel</filename> should be writable only by 85 the owner. Also, since there is no telling what kind of sensitive information 86 86 a user may eventually place in their copy of these files, you should 87 87 make them unreadable by "group" and "other".</para> 88 88 89 <para>You can also put other files in 89 <para>You can also put other files in 90 90 <filename class="directory">/etc/skel</filename> and 91 91 different permissions may be needed for them.</para> … … 93 93 <para>Decide which initialization files should be provided in every (or most) 94 94 new user's home directory. The decisions you make will affect what you 95 do in the next two sections, <xref linkend="postlfs-config-profile"/> and 95 do in the next two sections, <xref linkend="postlfs-config-profile"/> and 96 96 <xref linkend="postlfs-config-vimrc"/>. Some or all of those files will be 97 useful for <systemitem class="username">root</systemitem>, any 97 useful for <systemitem class="username">root</systemitem>, any 98 98 already-existing users, and new users.</para> 99 99 … … 108 108 109 109 <para>You will run a slightly modified set of commands for files which 110 are placed in <filename class="directory">/etc/skel</filename>. Each section 111 will remind you of this. In brief, the book's commands have been written for 112 files <emphasis>not</emphasis> added to 113 <filename class="directory">/etc/skel</filename> and just send the results to 114 the user's home directory. If the file is going to be in 115 <filename class="directory">/etc/skel</filename>, change the book's command(s) 110 are placed in <filename class="directory">/etc/skel</filename>. Each section 111 will remind you of this. In brief, the book's commands have been written for 112 files <emphasis>not</emphasis> added to 113 <filename class="directory">/etc/skel</filename> and just send the results to 114 the user's home directory. If the file is going to be in 115 <filename class="directory">/etc/skel</filename>, change the book's command(s) 116 116 to send output there instead and then just copy the file from 117 <filename class="directory">/etc/skel</filename> to the appropriate 118 directories, like <filename class="directory">/etc</filename>, 119 <filename class="directory">~</filename> or the home directory 117 <filename class="directory">/etc/skel</filename> to the appropriate 118 directories, like <filename class="directory">/etc</filename>, 119 <filename class="directory">~</filename> or the home directory 120 120 of any other user already in the system.</para> 121 121 … … 125 125 the <option>-m</option> parameter, which tells 126 126 <command>useradd</command> to create the user's home directory and 127 copy files from <filename class="directory">/etc/skel</filename> (can be 127 copy files from <filename class="directory">/etc/skel</filename> (can be 128 128 overridden) to the new user's home directory. For example:</para> 129 129 -
postlfs/config/vimrc.xml
rf009801 re0d33ef 33 33 <application>Emacs</application> users!</para> 34 34 35 <para>The LFS book gives a basic <filename>vimrc</filename> file. Here, we 36 attempt to enhance this file. At startup, <command>vim</command> reads 37 <filename>/etc/vimrc</filename> and <filename>~/.vimrc</filename> (i.e., the 35 <para>The LFS book gives a basic <filename>vimrc</filename> file. Here, we 36 attempt to enhance this file. At startup, <command>vim</command> reads 37 <filename>/etc/vimrc</filename> and <filename>~/.vimrc</filename> (i.e., the 38 38 global <filename>vimrc</filename> and the user-specific one.). Note that this is 39 39 only true if you compiled <application>vim</application> using LFS-3.1 onwards. 40 Prior to this, the global <filename>vimrc</filename> was 40 Prior to this, the global <filename>vimrc</filename> was 41 41 <filename>/usr/share/vim/vimrc</filename>.</para> 42 42 43 <para>Here is a slightly expanded <filename>.vimrc</filename> that you can 44 put in <filename>~/.vimrc</filename> to provide user specific effects. Of 45 course, if you put it into <filename>/etc/skel/.vimrc</filename> instead, it 43 <para>Here is a slightly expanded <filename>.vimrc</filename> that you can 44 put in <filename>~/.vimrc</filename> to provide user specific effects. Of 45 course, if you put it into <filename>/etc/skel/.vimrc</filename> instead, it 46 46 will be made available to users you add to the system later. You can also copy 47 the file from <filename>/etc/skel/.vimrc</filename> to the home directory of 48 users already on the system, like root. Be sure to set permissions, owner, and 49 group if you do copy anything directly from 47 the file from <filename>/etc/skel/.vimrc</filename> to the home directory of 48 users already on the system, like root. Be sure to set permissions, owner, and 49 group if you do copy anything directly from 50 50 <filename class="directory">/etc/skel</filename>.</para> 51 51 … … 58 58 " End .vimrc</literal></screen> 59 59 60 <para>A FAQ on the LFS mailing lists regards the comment tags in 61 <filename>vimrc</filename>. Note that they are " instead of the more 62 usual # or //. This is correct, the syntax for 60 <para>A FAQ on the LFS mailing lists regards the comment tags in 61 <filename>vimrc</filename>. Note that they are " instead of the more 62 usual # or //. This is correct, the syntax for 63 63 <filename>vimrc</filename> is slightly unusual.</para> 64 64 … … 67 67 68 68 <itemizedlist> 69 <!-- 69 <!-- 70 70 <listitem> 71 71 <para><option>set nocompatible</option> : This option … … 76 76 </listitem> 77 77 <listitem> 78 <para><option>set bs=2</option>: This influences the behavior 78 <para><option>set bs=2</option>: This influences the behavior 79 79 of the backspace option. It is fairly complex so see <command>:help 'bs' 80 80 </command> for more details.</para> … … 82 82 --> 83 83 <listitem> 84 <para><option>set columns=80</option>: This simply sets the 84 <para><option>set columns=80</option>: This simply sets the 85 85 number of columns used on the screen.</para> 86 86 </listitem> 87 <!-- 87 <!-- 88 88 <listitem> 89 89 <para><option>set background=dark</option>: This tells 90 <command>vim</command> to use colors which look good on a dark 90 <command>vim</command> to use colors which look good on a dark 91 91 background.</para> 92 92 </listitem> 93 93 --> 94 94 <listitem> 95 <para><option>set wrapmargin=8</option>: This is the number of 95 <para><option>set wrapmargin=8</option>: This is the number of 96 96 characters from the right window border where wrapping starts.</para> 97 97 </listitem> 98 <!-- 98 <!-- 99 99 <listitem> 100 100 <para><option>syntax on</option>: Enables … … 109 109 110 110 <para>More information on the <emphasis>many</emphasis> 111 <command>vim</command> options can be found by reading the help 112 inside <command>vim</command> itself. Do this by typing 113 <command>:</command><option>help</option> in 114 <command>vim</command> to get the general help, or by typing 115 <command>:</command><option>help usr_toc.txt</option> to view 111 <command>vim</command> options can be found by reading the help 112 inside <command>vim</command> itself. Do this by typing 113 <command>:</command><option>help</option> in 114 <command>vim</command> to get the general help, or by typing 115 <command>:</command><option>help usr_toc.txt</option> to view 116 116 the User Manual Table of Contents.</para> 117 117
Note:
See TracChangeset
for help on using the changeset viewer.