Machtelt_Garrels_Introduction_to_Linux.pdf

(546 KB) Pobierz
Machtelt Garrels
Introduction to Linux
A Hands-On Guide
Second Edition
Fultus
Books
Introduction to Linux
A Hands-On Guide
by
Machtelt Garrels
Cover design by Fultus Corporation
Cover illustration by Anna Khayrullina
ISBN 1-59682-112-4
(Second Edition)
All rights reserved.
Copyright © 2002-2007 by Machtelt Garrels
Published by Fultus Corporation
Corporate Web Site:
Fultus eLibrary:
Online Book Superstore:
email:
www.fultus.com
elibrary.fultus.com
store.fultus.com
production@fultus.com
The text of this book is freely distributable under the terms of the GNU Free Documentation License, which can
be found at
http://www.gnu.org/copyleft/fdl.html.
Cover art and layout are copyright Fultus Corporation and may
not be reproduced without permission; violators will be prosecuted to the fullest extent permissible by law.
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.
Linux is a registered trademark of Linus Torvalds. Penguin logo based on artwork by Larry Ewing.
All product names and services identified throughout this manual are trademarks or registered trademarks of
their respective companies.
Table of Contents
Table of Contents
Introduction ......................................................................................................................... 15
H
H
Chapter 1 What is Linux?..................................................................................................... 19
H
H
1.1 History................................................................................................................................... 19
1.1.1 UNIX ............................................................................................................................... 19
1.1.2 Linus and Linux............................................................................................................. 21
1.1.3 Current application of Linux systems ........................................................................ 22
1.2 The user interface................................................................................................................. 22
1.2.1 Is Linux difficult?........................................................................................................... 22
1.2.2 Linux for non-experienced users................................................................................. 23
1.3 Does Linux have a future? .................................................................................................. 24
1.3.1 Open Source ................................................................................................................... 24
1.3.2 Ten years of experience at your service ..................................................................... 24
1.4 Properties of Linux .............................................................................................................. 26
1.4.1 Linux Pros....................................................................................................................... 26
1.4.2 Linux Cons ..................................................................................................................... 27
1.5 Linux Flavors........................................................................................................................ 29
1.5.1 Linux and GNU ............................................................................................................. 29
1.5.2 GNU/Linux.................................................................................................................... 30
1.5.3 Which distribution should I install? ........................................................................... 30
1.6 Summary ............................................................................................................................... 32
1.7 Exercises ................................................................................................................................ 32
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
Chapter 2 Quickstart............................................................................................................. 35
H
H
2.1 Logging in, activating the user interface and logging out ............................................. 35
2.1.1 Introduction ................................................................................................................... 35
2.1.2 Graphical mode ............................................................................................................. 36
2.1.3 Text mode ....................................................................................................................... 38
H
H
H
H
H
H
H
H
3
Introduction to Linux
2.2 Absolute basics.....................................................................................................................
2.2.1 The commands ..............................................................................................................
2.2.2 General remarks ............................................................................................................
2.2.3 Using Bash features ......................................................................................................
2.3 Getting help ..........................................................................................................................
2.3.1 Be warned.......................................................................................................................
2.3.2 The man pages...............................................................................................................
2.3.3 More info ........................................................................................................................
2.4 Summary...............................................................................................................................
2.5 Exercises................................................................................................................................
2.5.1 Connecting and disconnecting ....................................................................................
2.5.2 Passwords.......................................................................................................................
2.5.3 Directories ......................................................................................................................
2.5.4 Files .................................................................................................................................
2.5.5 Getting help ...................................................................................................................
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
39
39
39
40
42
42
42
45
48
49
49
50
50
51
52
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
Chapter 3 About files and the file system........................................................................ 53
3.1 General overview of the Linux file system ......................................................................
3.1.1 Files .................................................................................................................................
3.1.2 About partitioning ........................................................................................................
3.1.3 More file system layout ................................................................................................
3.2 Orientation in the file system.............................................................................................
3.2.1 The path..........................................................................................................................
3.2.2 Absolute and relative paths.........................................................................................
3.2.3 The most important files and directories...................................................................
3.2.4 The most important configuration files .....................................................................
3.2.5 The most common devices...........................................................................................
3.2.6 The most common variable files .................................................................................
3.3 Manipulating files................................................................................................................
3.3.1 Viewing file properties .................................................................................................
3.3.2 Creating and deleting files and directories ...............................................................
3.3.3 Finding files ...................................................................................................................
3.3.4 More ways to view file content ...................................................................................
3.3.5 Linking files ...................................................................................................................
3.4 File security...........................................................................................................................
3.4.1 Access rights: Linux's first line of defense.................................................................
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
53
53
55
60
63
63
65
66
69
72
73
74
74
78
82
87
88
91
91
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
H
4
Zgłoś jeśli naruszono regulamin