source: postlfs/config/logon.xml

trunk
Last change on this file was 497d485, checked in by Xi Ruoyao <xry111@…>, 11 days ago

Update or remove broken URLs

Reported-by: rhubarbpieguy@…
Suggested-by: Vladimir Pertsev <info@…>

  • Property mode set to 100644
File size: 3.7 KB
Line 
1<?xml version="1.0" encoding="UTF-8"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6]>
7
8<sect1 id="postlfs-config-logon" xreflabel="Customizing your Logon with /etc/issue">
9 <?dbhtml filename="logon.html"?>
10
11
12 <title>Customizing your Logon with /etc/issue</title>
13
14 <indexterm zone="postlfs-config-logon">
15 <primary sortas="e-etc-issue">/etc/issue</primary>
16 </indexterm>
17
18 <para>
19 When you first boot up your new LFS system, the logon screen will be
20 nice and plain (as it should be in a bare-bones system). Many people
21 however, will want their system to display some information in the logon
22 message. This can be accomplished using the
23 file <filename>/etc/issue</filename>.
24 </para>
25
26 <para>
27 The <filename>/etc/issue</filename> file is a plain text file
28 which will also accept certain escape sequences (see below) in order to
29 insert information about the system. There is also the file
30 <filename>issue.net</filename> which can be used when logging on remotely.
31 <command>ssh</command> however, will only use it if you set the option in
32 the configuration file and will <emphasis>not</emphasis> interpret the
33 escape sequences shown below.
34 </para>
35
36 <para>
37 One of the most common things which people want to do is clear the
38 screen at each logon. The easiest way of doing that is to put a "clear"
39 escape sequence into <filename>/etc/issue</filename>. A simple way of
40 doing this is to issue the command <command>clear &gt;
41 /etc/issue</command>. This will insert the relevant escape code into
42 the start of the <filename>/etc/issue</filename> file. Note that if
43 you do this, when you edit the file, you should leave the characters
44 (normally '^[[H^[[2J') on the first line alone.
45 </para>
46
47 <note>
48 <para>
49 Terminal escape sequences are special codes recognized by the terminal.
50 The ^[ represents an ASCII ESC character. The sequence ESC [ H
51 puts the cursor in the upper left hand corner of the screen and ESC 2 J
52 erases the screen. For more information on terminal escape sequences see
53 <ulink url='https://invisible-mirror.net/xterm/ctlseqs/ctlseqs.html'/>
54 </para>
55 </note>
56
57 <para>
58 The following sequences are recognized by <command>agetty</command>
59 (the program which usually parses <filename>/etc/issue</filename>). This
60 information is from <command>man agetty</command> where you can find
61 extra information about the logon process.
62 </para>
63
64 <para>
65 The <filename>issue</filename> file can contain certain character
66 sequences to display various information. All <filename>issue</filename>
67 sequences consist of a backslash (\) immediately followed by one of the
68 letters explained below (so <option>\d</option> in
69 <filename>/etc/issue</filename> would insert the current date).
70 </para>
71
72<screen><literal>b Insert the baudrate of the current line.
73d Insert the current date.
74s Insert the system name, the name of the operating system.
75l Insert the name of the current tty line.
76m Insert the architecture identifier of the machine, e.g., i686.
77n Insert the nodename of the machine, also known as the hostname.
78o Insert the domainname of the machine.
79r Insert the release number of the kernel, e.g., 2.6.11.12.
80t Insert the current time.
81u Insert the number of current users logged in.
82U Insert the string "1 user" or "&lt;n&gt; users" where &lt;n&gt; is the
83 number of current users logged in.
84v Insert the version of the OS, e.g., the build-date etc.</literal></screen>
85
86</sect1>
Note: See TracBrowser for help on using the repository browser.