mirror of https://github.com/tLDP/LDP
493 lines
17 KiB
XML
493 lines
17 KiB
XML
<?xml version="1.0" encoding="ISO-8859-1"?>
|
|
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN"
|
|
"http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd" [
|
|
|
|
<!ENTITY chap1 SYSTEM "chap1.xml">
|
|
<!ENTITY chap2 SYSTEM "chap2.xml">
|
|
<!ENTITY chap3 SYSTEM "chap3.xml">
|
|
<!ENTITY chap4 SYSTEM "chap4.xml">
|
|
<!ENTITY chap5 SYSTEM "chap5.xml">
|
|
<!ENTITY chap6 SYSTEM "chap6.xml">
|
|
<!ENTITY chap7 SYSTEM "chap7.xml">
|
|
<!ENTITY chap8 SYSTEM "chap8.xml">
|
|
<!ENTITY chap9 SYSTEM "chap9.xml">
|
|
<!ENTITY chap10 SYSTEM "chap10.xml">
|
|
<!ENTITY app1 SYSTEM "app1.xml">
|
|
<!ENTITY app2 SYSTEM "app2.xml">
|
|
<!ENTITY app3 SYSTEM "app3.xml">
|
|
<!ENTITY app4 SYSTEM "app4.xml">
|
|
<!ENTITY app5 SYSTEM "app5.xml">
|
|
<!ENTITY gloss SYSTEM "gloss.xml">
|
|
]>
|
|
|
|
<book>
|
|
<bookinfo>
|
|
<title>Introduction to Linux</title>
|
|
<subtitle>A Hands on Guide</subtitle>
|
|
|
|
<authorgroup>
|
|
<author>
|
|
<firstname>Machtelt</firstname>
|
|
<surname>Garrels</surname>
|
|
<affiliation>
|
|
<orgname>CoreSequence.com</orgname>
|
|
<address>
|
|
<email>tille@coresequence.com</email>
|
|
</address>
|
|
</affiliation>
|
|
</author>
|
|
</authorgroup>
|
|
|
|
<edition>Version 1.9 20031201</edition>
|
|
|
|
<keywordset>
|
|
<keyword>Linux</keyword>
|
|
<keyword>Beginners</keyword>
|
|
<keyword>linux</keyword>
|
|
<keyword>start</keyword>
|
|
<keyword>Getting started</keyword>
|
|
<keyword>guide</keyword>
|
|
<keyword>Guide</keyword>
|
|
<keyword>Exercises</keyword>
|
|
<keyword>exercises</keyword>
|
|
</keywordset>
|
|
|
|
</bookinfo>
|
|
|
|
<preface>
|
|
|
|
<title>Introduction</title>
|
|
|
|
<section id="intro_01">
|
|
<title>Why this guide?</title>
|
|
|
|
<para>Many people still believe that learning Linux is difficult, or that only
|
|
experts can understand how a Linux system works. Though there is a lot of free
|
|
documentation available, the documentation is widely scattered on the Web, and
|
|
often confusing, since it is usually oriented toward experienced UNIX or Linux
|
|
users. Today, thanks to the advancements in development, Linux has grown in
|
|
popularity both at home and at work. The goal of this guide is to show people
|
|
of all ages that Linux can be simple and fun, and used for all kinds of purposes.
|
|
</para>
|
|
|
|
</section>
|
|
|
|
<section id="intro_02">
|
|
<title>Who should read this book?</title>
|
|
|
|
<para>
|
|
This guide was created as an overview of the Linux Operating System, geared
|
|
toward new users as an exploration tour and getting started guide, with
|
|
exercises at the end of each chapter. For more advanced trainees it can be a
|
|
desktop reference, and a collection of the base knowledge needed to proceed with
|
|
system and network administration. This book contains many real life examples
|
|
derived from the author's experience as a Linux system and network
|
|
administrator, trainer and consultant. We hope these examples will help you
|
|
to get a better understanding of the Linux system and that you feel encouraged
|
|
to try out things on your own.
|
|
</para>
|
|
<para>Everybody who wants to get a CLUE, a Command Line User Experience, with
|
|
Linux (and UNIX in general) will find this book useful.
|
|
</para>
|
|
</section>
|
|
|
|
<section id="intro_03">
|
|
<title>New versions of this guide</title>
|
|
|
|
<para>This document is published in the Guides section of the Linux
|
|
Documentation Project collection at
|
|
<ulink url="http://www.tldp.org/guides.html" />;
|
|
you can also download PDF and PostScript formatted versions here for printing.
|
|
</para>
|
|
<para>The most recent edition is available at
|
|
<ulink url="http://tille.soti.org/training/tldp/">
|
|
http://tille.soti.org/training/tldp/</ulink>.
|
|
</para>
|
|
</section>
|
|
|
|
<section id="intro_04">
|
|
<title>Revision History</title>
|
|
<para>
|
|
<revhistory>
|
|
<revision>
|
|
<revnumber>1.0</revnumber>
|
|
<date>2002-12-29</date>
|
|
<authorinitials>MG</authorinitials>
|
|
<revremark>Initial release for TLDP</revremark>
|
|
</revision>
|
|
<revision>
|
|
<revnumber>1.1</revnumber>
|
|
<date>2003-01-22</date>
|
|
<authorinitials>MG</authorinitials>
|
|
<revremark>Bug fixes;
|
|
removed some more too RedHat specific stuff;
|
|
corrected minor errors;
|
|
moved most recent version to decent URL;
|
|
improved tar section, added something about jar.</revremark>
|
|
</revision>
|
|
<revision>
|
|
<revnumber>1.2</revnumber>
|
|
<date>2003-02-28</date>
|
|
<authorinitials>MG</authorinitials>
|
|
<revremark>ps a bit better explained;
|
|
more in getting started: --help, whatis, apropos explained;
|
|
more on find;
|
|
chmod and umask still contained a couple of errors and incompletenesses;
|
|
resized images that were too large to be printed;
|
|
resized oversized text boxes for better print quality;
|
|
updated glossary.</revremark>
|
|
</revision>
|
|
<revision>
|
|
<revnumber>1.3</revnumber>
|
|
<date>2003-03-26</date>
|
|
<authorinitials>MG</authorinitials>
|
|
<revremark>grep and escape characters;
|
|
exporting variables;
|
|
more consequent about security issues;
|
|
init and cron revised;
|
|
window and desktop managers explanation;
|
|
removed some more too RedHat specific stuff;
|
|
added piece about (x)inetd;
|
|
local authentication;
|
|
text conversions and encoding;
|
|
graphical help, graphical file managers, note on internet connections;
|
|
spell check.
|
|
</revremark>
|
|
</revision>
|
|
<revision>
|
|
<revnumber>1.4</revnumber>
|
|
<date>2003-04-27</date>
|
|
<authorinitials>MG</authorinitials>
|
|
<revremark>Added sound and video playing, chat/conference;
|
|
got rid of redhat-config image and redhat printtool gui stuff;
|
|
bash key combinations in chap2;
|
|
XML keycap tag on all key combinations, parameter tag on arguments, guibutton
|
|
tag for graphical buttons, menuchoice, guimenu and guimenuitem tags for GUI
|
|
menu selections;
|
|
replaced pico with ed, added piece about Linux in the office, replaced abiword
|
|
image with openoffice screenshot;
|
|
added conventions and organization sections in introduction;
|
|
added konqueror screenshot in chap2;
|
|
replaced system-monitor screenshot in chap4 with something more up to date;
|
|
summary for chap2, checked exercises;
|
|
added bash in app3 differing features;
|
|
License section is now only invariant section.
|
|
</revremark>
|
|
</revision>
|
|
<revision>
|
|
<revnumber>1.5</revnumber>
|
|
<date>2003-06-17</date>
|
|
<authorinitials>MG</authorinitials>
|
|
<revremark>Redo of chapter 10 on Networking, left out some sections
|
|
that were too complicated.
|
|
</revremark>
|
|
</revision>
|
|
<revision>
|
|
<revnumber>1.6</revnumber>
|
|
<date>2003-07-21</date>
|
|
<authorinitials>MG</authorinitials>
|
|
<revremark>Corrected details in chap 1 to 5, tried shorter lines in intro and chap1 to make it easier on translators using CVS. See what this gives: next update diffs should be more readable for these parts.</revremark>
|
|
</revision>
|
|
<revision>
|
|
<revnumber>1.7</revnumber>
|
|
<date>2003-07-26</date>
|
|
<authorinitials>MG</authorinitials>
|
|
<revremark>Added RPM and apt-get examples, corrected issues with tar incremental backup.
|
|
Updated glossary and added links to sections within document.</revremark>
|
|
</revision>
|
|
<revision>
|
|
<revnumber>1.8</revnumber>
|
|
<date>2003-09-16</date>
|
|
<authorinitials>MG</authorinitials>
|
|
<revremark>Added app5, corrected some minor details.</revremark>
|
|
</revision>
|
|
<revision>
|
|
<revnumber>1.9</revnumber>
|
|
<date>2003-11-29</date>
|
|
<authorinitials>MG</authorinitials>
|
|
<revremark>Acted upon remarks from readers to clarify issues with compressed files, removable media; found a couple more spelling errors, added an extra example for cron and one for prompt settings; took out reference to Acrobat Reader and stuffit, which are not Open Source (pointing to a fancy flight simulator instead ;-) More on keyboard layout. Added RPM example, added yum package manager.</revremark>
|
|
</revision>
|
|
|
|
</revhistory>
|
|
</para>
|
|
</section>
|
|
|
|
<section id="intro_05">
|
|
<title>Contributions</title>
|
|
|
|
<para>
|
|
Many thanks to all the people who shared their experiences. And especially to
|
|
the Belgian Linux users, among them my husband, for hearing me out every day
|
|
and always being generous in their comments.
|
|
</para>
|
|
<para>Also a special thought for Tabatha Marshall for doing a really thorough
|
|
revision, spell check and styling, and to Eugene Crosser for marking the errors
|
|
that we two looked over.
|
|
</para>
|
|
<para>And thanks to all the readers who noticed me about missing topics and who
|
|
helped to pick out the last errors, unclear definitions and typos by going
|
|
through the trouble of mailing me all their remarks.
|
|
</para>
|
|
<para>Finally, a big thank you for the volunteers who are currently translating
|
|
this document in French, Swedish, German and more. It is a big work that should
|
|
not be underestimated; I admire your courage.
|
|
</para>
|
|
</section>
|
|
|
|
<section id="intro_06">
|
|
<title>Feedback</title>
|
|
|
|
<para>
|
|
Missing information, missing links, missing characters? Mail it to the
|
|
maintainer of this document: <address><email>tille@coresequence.com</email></address>
|
|
</para>
|
|
<para>Don't forget to check with the
|
|
<ulink url="http://tille.soti.org/training/tldp/">latest version</ulink> first!
|
|
</para>
|
|
</section>
|
|
|
|
<section id="intro_07">
|
|
<title>Copyright information</title>
|
|
|
|
<para>Copyright 2002-2003 Machtelt Garrels.
|
|
</para>
|
|
<para> Permission is granted to copy, distribute and/or modify this document
|
|
under the terms of the GNU Free Documentation License, Version 1.1 or any later
|
|
version published by the Free Software Foundation; with the Invariant Sections
|
|
being the <quote>Copyright information</quote> and <quote>Feedback</quote>
|
|
sections, with no Front-Cover Texts and no Back-Cover Texts. A copy of the
|
|
license is included in <xref linkend="app4" /> entitled <quote>GNU Free
|
|
Documentation License</quote>.
|
|
</para>
|
|
<para>Read <ulink url="http://www.fsf.org/gnu/manifesto.html">The GNU Manifesto
|
|
</ulink> if you want to know why this license was chosen for this book.
|
|
</para>
|
|
|
|
<para>The author and publisher have made every effort in the preparation of this
|
|
book to ensure the accuracy of the information. However, the information
|
|
contained in this book is offered without warranty, either express or implied.
|
|
Neither the author nor the publisher nor any dealer or distributor will be held
|
|
liable for any damages caused or alleged to be caused either directly or
|
|
indirectly by this book.
|
|
</para>
|
|
|
|
<para>The logos, trademarks and symbols used in this book are the properties of
|
|
their respective owners.
|
|
</para>
|
|
</section>
|
|
|
|
<section id="intro_08">
|
|
<title>What do you need?</title>
|
|
<para>You will require a computer and a medium containing a Linux distribution.
|
|
Most of this guide applies to all Linux distributions - and UNIX in general.
|
|
Apart from time, there are no further specific requirements.
|
|
</para>
|
|
<para>The <ulink url="http://www.tldp.org/HOWTO/Installation-HOWTO/">
|
|
Installation HOWTO</ulink> contains helpful information on how to obtain
|
|
Linux software and install it on your computer. Hardware requirements and
|
|
coexistence with other operating systems are also discussed.
|
|
</para>
|
|
<para>CD images can be downloaded from <ulink url="http://www.linux-iso.com/">
|
|
linux-iso.com</ulink> and many other locations, see <xref linkend="app1" />.
|
|
</para>
|
|
<para>An interesting alternative for those who don't dare to take the step of
|
|
an actual Linux installation on their machine are the Linux distributions that
|
|
you can run from a CD, such as the <ulink url="http://www.knoppix.com/">
|
|
Knoppix</ulink> distribution.
|
|
</para>
|
|
</section>
|
|
|
|
<section id="intro_09">
|
|
<title>Conventions used in this document</title>
|
|
<para>The following typographic and usage conventions occur in this text:
|
|
</para>
|
|
|
|
<table id="conventions" frame="all"><title>Typographic and usage conventions</title>
|
|
<tgroup cols="2" align="left" colsep="1" rowsep="1">
|
|
|
|
<thead>
|
|
<row><entry>Text type</entry><entry>Meaning</entry></row>
|
|
</thead>
|
|
|
|
<tbody>
|
|
<row>
|
|
<entry><quote>Quoted text</quote></entry>
|
|
<entry>Quotes from people, quoted computer output.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><screen>terminal view</screen></entry>
|
|
<entry>Literal computer input and output captured from the terminal,
|
|
usually rendered with a light grey background.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><command>command</command></entry>
|
|
<entry>Name of a command that can be entered on the command line.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><varname>VARIABLE</varname></entry>
|
|
<entry>Name of a variable or pointer to content of a variable, as in
|
|
<varname>$VARNAME</varname>.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><option>option</option></entry>
|
|
<entry>Option to a command, as in <quote>the <option>-a</option> option to the
|
|
<command>ls</command> command</quote>.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><parameter>argument</parameter></entry>
|
|
<entry>Argument to a command, as in <quote>read
|
|
<command>man <parameter>ls</parameter></command></quote>.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><cmdsynopsis><command>command <option>options</option>
|
|
<parameter>arguments</parameter></command></cmdsynopsis></entry>
|
|
<entry>Command synopsis or general usage, on a separated line.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><filename>filename</filename></entry>
|
|
<entry>Name of a file or directory, for example <quote>Change to the
|
|
<filename>/usr/bin</filename> directory.</quote></entry>
|
|
</row>
|
|
<row>
|
|
<entry><keycap>Key</keycap></entry>
|
|
<entry>Keys to hit on the keyboard, such as <quote>type <keycap>Q</keycap>
|
|
to quit</quote>.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><guibutton>Button</guibutton></entry>
|
|
<entry>Graphical button to click, like the <guibutton>OK</guibutton>
|
|
button.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><menuchoice><guimenu>Menu</guimenu><guimenuitem>Choice</guimenuitem>
|
|
</menuchoice></entry>
|
|
<entry>Choice to select from a graphical menu, for instance: <quote>Select
|
|
<menuchoice><guimenu>Help</guimenu><guimenuitem>About Mozilla</guimenuitem>
|
|
</menuchoice> in your browser.</quote></entry>
|
|
</row>
|
|
<row>
|
|
<entry><emphasis>Terminology</emphasis></entry>
|
|
<entry>Important term or concept: <quote>The Linux <emphasis>kernel</emphasis>
|
|
is the heart of the system.</quote></entry>
|
|
</row>
|
|
<row>
|
|
<entry>See <xref linkend="chap_01" /></entry><entry>link to related subject
|
|
within this guide.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><ulink url="http://tille.soti.org">The author</ulink></entry>
|
|
<entry>Clickable link to an external web resource.</entry>
|
|
</row>
|
|
</tbody>
|
|
|
|
</tgroup>
|
|
</table>
|
|
|
|
</section>
|
|
|
|
<section id="intro_10">
|
|
<title>Organization of this document</title>
|
|
|
|
<para>This guide aims to be the foundation for all other materials that you
|
|
can get from The Linux Documentation Project. As such, it provides you with
|
|
the fundamental knowledge needed by anyone who wants to start working with a
|
|
Linux system, while at the same time it tries to consciously avoid to re-invent
|
|
the hot water. Thus, you can expect this book to be incomplete and full of
|
|
links to sources of additional information on your system, on the Internet and
|
|
in your system documentation.
|
|
</para>
|
|
<para>The first chapter is an introduction to the subject on Linux; the next
|
|
two discuss absolute basic commands. Chapters 4 and 5 discuss some more
|
|
advanced but still basic topics. Chapter 6 is needed for continuing with the
|
|
rest, since it discusses editing files, an ability you need to pass from Linux
|
|
newbie to Linux user. The following chapters discuss somewhat more advanced
|
|
topics that you will have to deal with in everyday Linux use.
|
|
</para>
|
|
<para>All chapters come with exercises that will test your preparedness for the
|
|
next chapter.</para>
|
|
|
|
<itemizedlist>
|
|
<listitem>
|
|
<para><xref linkend="chap_01" />: What is Linux, how did it come into existence,
|
|
who should use it, installing your computer.</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para><xref linkend="chap_02" />: Getting started, connecting to the system,
|
|
basic commands, where to find help.</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para><xref linkend="chap_03" />: The filesystem, important files and
|
|
directories, managing files and directories, security modes.</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para><xref linkend="chap_04" />: Understanding and managing processes, boot and
|
|
shutdown procedures, postponing tasks, repetitive tasks.</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para><xref linkend="chap_05" />: What are standard input, output and error and
|
|
how are these features used from the command line.</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para><xref linkend="chap_06" />: Why you should learn to work with an editor,
|
|
discussion of the most common editors.</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para><xref linkend="chap_07" />: Configuring your graphical, text and audio
|
|
environment, settings for the non-native English speaking Linux user, tips for
|
|
adding extra software.</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para><xref linkend="chap_08" />: Converting files to a printable format,
|
|
getting them out of the printer, hints for solving print problems.</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para><xref linkend="chap_09" />: Preparing data to be backed up, discussion of
|
|
various tools.</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para><xref linkend="chap_10" />: Overview of Linux networking tools and user
|
|
applications, with a short discussion of the underlying service daemon programs
|
|
and secure networking.</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para><xref linkend="app1" />: Which books to read and sites to visit when you
|
|
have finished reading this one.</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para><xref linkend="app2" />: A comparison.</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para><xref linkend="app3" />: If you ever get stuck, these tables might be an
|
|
outcome. Also a good argument when your boss insists that YOU should use HIS
|
|
favorite shell.</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para><xref linkend="app4" />: What you can do with this guide, from the legal
|
|
perspective.</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
|
|
</section>
|
|
|
|
</preface>
|
|
|
|
<toc></toc>
|
|
|
|
&chap1;
|
|
&chap2;
|
|
&chap3;
|
|
&chap4;
|
|
&chap5;
|
|
&chap6;
|
|
&chap7;
|
|
&chap8;
|
|
&chap9;
|
|
&chap10;
|
|
&app1;
|
|
&app2;
|
|
&app3;
|
|
&app4;
|
|
&app5;
|
|
&gloss;
|
|
</book>
|