The best books about Linux. D. Bendel, R. Naper - Using Linux. Using the vi editor

Name: Linux tutorial for the user.

The book is dedicated to using the Linux operating system. Provides information about the history creating Linux and existing distributions. Discusses Linux OS installation and configuration, describes the file system, graphical and command line interface, connecting and configuring hardware, installation and updating software packages, work in local network and the Internet. Programs for working with text and operating shells, designed for file manipulation. Links to Internet resources are provided. For experienced users and novice network administrators.


Content
Preface.1
Who is this book for.1
What is this book about.2
How this book came about.3
Typographic conventions.4
Acknowledgments.5
Chapter 1. Linux OS: history and distributions. 7
1.1. What is an OS in general and Linux in particular.7
1.1.1. UNIX.7 OS family
1.1.2. A little history.8
1.1.3. Main characteristics of Linux OS.11
Real multitasking.11
Multi-user access.11
Swap random access memory to disk.11
Page memory organization.12
Loading executable modules "on demand".12
Sharing executable programs.12
Shared Libraries.12
Dynamic disk caching.12
100% satisfaction POSIX standard 1003.1.
Partial support for System V and BSD.13 features
System VIPC.13
Launch capability executable files other OS.13
Support various formats file systems.13
Network capabilities.14
Work on different hardware platforms.14
1.2. Linux distributions.14
1.3. Computer requirements.17
1.4. Where can I get Linux?.19
Chapter 2. Installing Linux OS on a Windows computer. 21
2.1. Preparing for installation.21
2.2. Cautions and recommendations.23
2.3. Disk partitions and boot process.25
2.3.1. What is "disc geometry"?.25
2.3.2. Disk partitions and disk partition table.26
2.3.3. Microsoft OS boot process.28
2.3.4. Problems with large disks.31
2.4. Bootloader selection.32
2.4.1. LILO loader from Linux OS distribution.33
2.4.2. Other OS.34 bootloaders
2.4.3. Download options.35
2.5. Preparing partitions on the disk.36
2.5.1. Recommendations for creating partitions.36
2.5.2. Programs for disk partitioning.39
2.6. Windows NT and Linux: loading via OS Loader from NT.40
2.7. Using the LILO.43 bootloader
2.7.1. Installing and configuring the LILO.43 bootloader
2.7.2. Installing other operating systems after Linux.47
2.7.3. Moving the /boot directory to the DOS partition.48
2.8. Booting Linux from MS-DOS using loadlin.exe.48
Chapter 3. First launch of Linux OS. 53
3.1. Loading Linux OS.53
3.2. Login.54
3.3. Console, virtual terminals and shell.56
3.4. Editing the command line. Team history.59
3.5. Shutting down a Linux system.63
3.6. Help with working with Linux.64
3.6.1. Sources of reference information.65
3.6.2. man.65 online manual pages
3.6.3. Command info.67
3.6.4. Help command.68
3.6.5. Documentation supplied with the distribution and software packages.68
3.6.6. Team Xtap.69
3.6.7. helptool.69 command
3.6.8. Books and Internet.70
Chapter 4. Introducing the ext2fs file system. 71
4.1. Files and their names.71
4.2. Catalogs.74
4.3. Purpose of the main system directories.
4.4. File types.83
4.4.1. Physical Device Files.83
4.4.2. Named pipes (pipes).85
4.4.3. Domain sockets.85
4.4.4. Symbolic links (once again about file names).86
4.5. Access rights to files and directories.87
4.6. Commands for working with files and directories.94
4.6.1. chown and chgrp.94 commands
4.6.2. Command mkdir.94
4.6.3. Team cat.94
4.6.4. Team sr.95
4.6.5. Team mv.96
4.6.6. Commands t and rmdir.96
4.6.7. Commands toge and less.97
4.6.8. Command//^ and wildcard characters for file names.98
4.6.9. Split command - split the file into several parts.101
4.6.10. File comparison and patch.102 command
4.7. File archiving commands.103
4.7.1. Program tar.104
4.7.2. Program gzip.106
4.7.3. bzip2.108 program
4.8. Creating and mounting file systems.110
Chapter 5. bash shell. 117
5.1. What is a shell?.117
5.2. Special characters.118
5.3. Executing commands.120
5.3.1. Operator;.120
5.3.2. Operator &.120
5.3.3. Operators && and |.120
5.4. Standard I/O.121
5.4.1. I/O streams.121
5.4.2. Command echo.122
5.4.3. cat.122 command
5.5. I/O redirection, channels and filters.123
5.5.1. Operators >,< и ».123
5.5.2. Operator |.125
5.5.3. Filters.125
5.6. Parameters and variables. Shell environment.126
5.6.1. Varieties of parameters.127
5.6.2. Shell invitations.129
5.6.3. Variable PATH.131
5.6.4. Variable IFS.131
5.6.5. Current and home directories.131
5.6.6. Export.132 command
5.7. Expression Expansion.132
5.7.1. Opening brackets.132
5.7.2. Replacing tilde.133
5.7.3. Substitution of parameters and variables.133
5.7.4. Command substitution.134
5.7.5. Arithmetic substitutions.134
5.7.6. Word separation.135
5.7.7. Expanding file and directory name patterns.135
5.7.8. Removing special characters.136
5.8. Shell as a programming language.136
5.8.1. Operators // and test (or ).136
5.8.2. Operator and conditional expressions.138
5.8.3. Statement case.140
5.8.4. select statement.141
5.8.5. Operatorfor.142
5.8.6. While statements and until.143
5.8.7. Functions.143
Syntax.143
Arguments.144
Local variables.144
Function for calculating factorialfact.145
5.9. Shell scripts and source.145 command
5.10. Teams.146
Chapter 6. Program Midnight Commander. 147
6.1. Installing the Midnight Commander.147 program
6.2. Appearance Midnight Commander.148 screen
6.3. Getting help.150
6.4. Mouse support.152
6.5. Panel management.152
6.5.1. File list display formats.153
6.5.2. Other display modes.156
6.5.3. Keyboard commands for controlling panels.158
6.6. Function keys and File menu.159
6.7. File masks for copy/rename operations.162
6.8. Midnight Commander messages when copying and moving files.165
6.9. Shell command line.166
6.10. Menu Commands.168
6.11. Setting up the Midnight Commander.173 program
Chapter 7. Graphical interface. 181
7.1. XFree86 and its components.181
7.2. How a computer video system works.186
7.3. Configuring the X server.189
7.3.1. Collection of necessary data.190
7.3.2. File structure /etc/Xll/XF86Config.191
7.3.3. Setting /etc/Xll/XF86ConfIg.200
7.4. Starting the X Window System.207
7.5. Selecting and configuring a window manager.211
7.6. Graphics environment KDE.212
7.7. Using the Display Manager.213
Chapter 8. Basics of system administration. 215
8.1. Main goals system administration. Processes and their identifiers.215
8.2. Linux OS boot procedure.218
8.2.1. The init process and the /etc/inittab.218 file
8.2.2. Basic configuration files.222
8.2.3. Other files that affect the download process.224
8.2.4. Processes that occur during user registration.225
8.2.5. Loading in single-user mode.226
8.3. Launching and configuring system-wide services.228
8.3.1. Editing the /etc/fstab.228 file
8.3.2. Swap files and partitions.229
8.3.3. Launching demons.231
8.3.4. System V Init Editor ksysv.232
8.4. Process management.235
8.4.1. Team/w.235
8.4.2. Team top.237
8.4.3. Priorities, nice value and renice command.238
8.4.4. Signals and kill command.239
8.4.5. Transferring the process to the background.242
8.4.6. Team nohup.243
8.5. User management.243
8.6. Resource Management.246
8.6.1. How much disk space is left?.247
8.6.2. Freeing up disk space.248
8.7. Software tools for system configuration.250
8.8. Setting up the user's environment.253
Chapter 9 Connecting and configuring hardware devices. 255
9.1. Device drivers.255
9.2. Special files devices.257
9.3. Keyboard.259
9.3.1. kbdrate.260 command
9.3.2. Character encoding tables.260
9.3.3. Entering characters from the keyboard.264
9.3.4. Changing the keyboard layout for text mode.267
9.3.5. Creating your own layout.268
9.3.6. Working with the keyboard in graphical mode.270
9.3.7. Module ХКВ.270
Some practical recommendations on setting up the XKV.275 module
9.4. Mouse.277
9.4.1. Determining the type of mouse.278
9.4.2. Interrupt conflicts.278
9.4.3. Mouse settings.279
9.5. Hard drive.280
9.5.1. Numbering.280
9.5.2. Formatting the hard drive.281
9.5.3. Command hdparm.282
9.5.4. Team fc.285
9.6. Printer.288
9.6.1. Traditional UNIX Printing Tools.288
9.6.2. File/etc/printcap.290
9.6.3. Configuring LPD using the printconf-gui.292 program
9.6.4. Filters.296
9.6.5. PostScript and Ghostscript.297
9.6.6. Fonts for Ghostscript.298
9.6.7. Printing to a remote printer.301
9.7. Sound card.301
9.8. CD-ROM drive.303
9.9. Iomega Zip disk for parallel port.304
Chapter 10. Installing and updating software packages. 307
10.1. Two ways to install software.307
10.2. Program rpm.307
10.3. Compiling software from source texts.313
10.3.1. Necessary information about programming in C.313 language
10.3.2. Installation of software packages from source texts.315
Chapter 11. Russification and fonts. 317
11.1. Preliminary information.318
11.1.1. Displaying characters on the screen.318
Text mode.318
Graphics mode.320
11.1.2. Localization.320
11.2. Settings system tools localization.322
11.2.1. Checking the availability of localization tools.322
11.2.2. Format for setting localization variable values.323
11.2.3. Enabling localization tools.324
11.3. Russification of the console.325
11.3.1. What needs to be done.325
11.3.2. How it's done in the Black Cat.328 distribution
11.3.3. Switching encodings.330
11.4. Russification X Window.330
11.4.1. A little about terminology.331
11.4.2. Font file formats.334
Bitmap Fonts.334
Type 1.334 fonts
Type 3.335 fonts
TrueType.335 fonts
Type 42.335 fonts
Comparison of Type 1 and TrueType.335 formats
Metafont.336
11.4.3. X server configuration.337
11.4.4. Font servers.338
Font server xfs.338
Font servers xfstt and xfsft.339
11.4.5. Revision of type industry.340
Is font server installed?.340
What fonts do you have on your system?.340
Files fonts.dir, fonts.alias and fonts.scale.343
Removing unnecessary fonts.346
11.4.6. Connecting new fonts.346
Font sources.346
Installation of raster fonts and Type fonts 1.348
Installing TrueType.349 fonts
11.5. Cyrillization of shell and other programs.352
11.5.1.bash.353
11.5.2. less.353
11.5.3. man.354
11.5.4. MOff.354
11.5.5.1s.354
11.5.6. The Midnight Commander.354
11.5.7. Windows 95 and DOS.355 disks
11.5.8. Samba.355
11.5.9. riogin.355
11.5.10. telnet.355
11.5.11. Ircll.356
11.6. Cyrillization of print.356
Chapter 12. Programs for working with text. 359
12.1. A few words about text file formats.359
12.2. Programs for viewing texts in different formats.360
12.2.1. Traditional UNIX tools for viewing text files.360
12.2.2. Acrobat program Reader (version 4.05).361
12.2.3. gv.365 program
12.2.4. Viewers for PS, PDF and DVI files from KDE.367
12.2.5. WordViewer.369 package
12.2.6. Code page transcoder programs.371
12.3. Spell check.373
12.4. About three types of text editors.376
12.5. Console editors for ASCII files.378
12.5.1. Editors like vi.378
12.5.2. Emacs.378 editor
12.5.3. CoolEdit - built-in editor of the Midnight Commander.379 program
12.6. ASCII file editors for graphics mode.383
12.6.1. Editor KEdit.383
12.6.2. Editor KWrite.387
12.6.3. Text editor Nedit version 5.1.1.387
12.7. Word processors.391
12.7.1. Possibilities of word processors.391
12.7.2. Word processors for Linux.392
12.7.3. Text editor Ted.392
12.7.4. Word processor AbiWord.397
12.7.5. Word processor KWord.399
12.7.6. Word processors StarWriter and OpenOffice.org Writer.409
12.8. Dictionaries and translators.412
Chapter 13. Access to local networks. 415
13.1. Preparing to go online.415
13.1.1. Network device drivers in the kernel.415
13.1.2. Dynamic connection of drivers.416
13.1.3. Receipt network address and installation of software.417
13.2. Setting up network interfaces.418
13.2.1. Location of configuration files.418
13.2.2. ifconfig.419 command
Setting up local interface 1о.419
Setting up the board interface Ethernet local networks (ethO).420
Interface for serial port.420
13.2.3. Setting up routing.420
13.2.4. Setting up the naming service.422
13.2.5. Network connection testing.424
13.2.6. netconf.425 utility
13.3. Telnet and ftp.427 programs
13.3.1 Telnet and rlogin programs.428
13.3.2. Program ftp.428
13.4. Network file system NFS.431
13.5. Connecting to a Windows network.432
13.5.1. What is Samba.432
13.5.2. Mounting file systems using Samba.434
Difficulties.435
13.6. Connecting to a Novell Netware.435 server
Chapter 14. Internet and email. 439
14.1. Essential information about Internet protocols.439
14.2. Preparing to go online.442
14.3. Program krrr.
14.3.1. Configuring crrr.445
14.3.2. Establishing communication using kppp.461
14.3.3. Problems setting up connection.465
If it still doesn’t work (where to go for help).467
14.4. Internet browsers.468
14.4.1. Traveling the Internet using the lynx.468 program
14.4.2. Browsers Netscape Navigator and Mozilla.472
14.4.4. File manager Konqueror.476
14.5. Email.478
Chapter 15. Living in the KDE environment. 489
15.1. KDE.489 Basics
15.1.1. Appearance.490
15.1.2. Main menu KDE.492
15.1.3. KDE.493 Control Center
15.1.4. Customizing the panel and icons on the desktop.497
15.2. What is a “comfortable work environment”.501
15.3. Utilities.502
15.4. Office applications.506
15.5. Graphics editor GIMP.510
15.6. Personal organizer.514
15.7. Communication with the rest of the world.517
15.8. Multimedia and games.519
15.8.1. Sound.519
15.8.2. Video.524
Program aKtion.524
Xine.527 program
MPlayer.535 program
15.8.3. Games.536
Chapter 16. back side file system. 541
16.1. Types of file systems supported in Linux.541
16.2. Disk partition structure in ext2fs.543
16.3. File inodes.547
16.4. Data addressing system.550
16.5. Virtual file system VFS.551
16.6. New file systems.552
16.7. Journaled file systems.553
16.8. File system ReiserFS.554
Chapter 17. Kernel update. 557
17.1. What is the kernel and when should it be changed.557
17.2. Kernel version numbering.558
17.3. Installing a new kernel from an RPM package.559
17.4. About compiling a new kernel.561
17.4.1. Why do you need to compile the kernel at all?.561
17.4.2. What you need to know before compiling.563
17.5. Seven steps to a new kernel.564
17.5.1. Obtaining and unzipping the kernel.564
17.5.2. Update software.565
17.5.3. Configuring the future kernel.566
17.5.4. Checks.569
17.5.5. Kernel compilation.570
17.5.6. Compiling modules.571
17.5.7. Installing the kernel.571
17.6. Conclusion.573
Chapter 18. Virtual computer (VMware system). 575
18.1. What is a "virtual computer".576
18.2. Installation of virtual machine system.578
18.3. Installing a license to use VMware.579
18.4. Creating a virtual machine.579
18.5. First session on a virtual computer.584
18.6. About some features of working with a virtual computer.585
18.6.1. Copy and paste.585
18.6.2. Suspending and instantly restoring the state of VM.586
18.6.3. Shutdown VM.587
18.6.4. Using DMA.587
18.6.5. Allocation of RAM for VMware.588
18.7. Connecting physical disks to a virtual computer.589
18.7.1. Necessary measures precautions.590
18.7.2. Connection physical disk to virtual computer.591
Disk permissions.591
Physical disk description file.591
Procedure for connecting a physical disk.592
18.7.3. Booting the OS from a physical disk.594
18.8. Connection to local network.600
18.8.1. Four options for organizing network services in the VMware.600 system
18.8.2. Support Tools networking opportunities in VMware.603
18.8.3. Assigning MAC addresses for virtual computers.604
18.8.4. Installing network support tools.605
18.8.5. Several examples of setting up network access.610
Example 1: Connecting to an existing local network
in the "Bridged networking" option.610
Example 2: Creating a network on an isolated computer.611
Example 3. Connecting a virtual and physical network.612
18.8.6. Access to virtual computer disks from the base OS.613
18.9. A few additional notes.614
18.9.1. Again about precautions.614
18.9.2. List of users who are allowed to access the Samba.614 server
18.9.3. How to eliminate the "leakage" of packets from a virtual network to a real one.615
18.9.4. About using the VMware.615 system
18.9.5. A little about performance.616
18.9.6. About primary sources.617
Application. Sources and links to additional materials. 619
Subject index.

Download options.
So, in my opinion, choosing a download option is done as follows.
-If you have Windows NT or Windows 2000 installed, then use NT Loader.

If you have Windows 95 or Windows 98 on FAT16, and you don't want to install a boot loader program from another OS or from an independent developer, you can either use LILO or start DOS first and then boot Linux using loadlin.exe (or another similar program, there are several of them, but we will not consider others).

If you have Windows 95 OSR2 or Windows 98 on FAT32 installed, and you do not want to install a loader program from another OS or from an independent developer, then you will have to use loadlin.exe. Many IIOWTO guides state that you don't need to use LILO if your active partition is formatted FAT32, although I don't know why. But my own attempt to boot Linux using NT Loader installed on a PAT32 partition ended in failure. So I also had to use the program in this case

The tutorial "Linux for the User", written by the creator of the virtual encyclopedia "Linux in Russian" Viktor Kostromin and published by the publishing house "BHV-Petersburg" in 2002, contains 18 chapters and covers all aspects of working with the system - from choosing a distribution to fine tuning hardware and use of VMWare. The book is written in simple in clear language and can serve as an excellent educational tool for those taking their first steps in the world of Linux.

[IN. Kostromin (kos at rus-linux dot net) - 09/25/2004]

/

/

    This book is about programming in the Unix shell language. The shell is a powerful tool capable of correct use automate a large number of routine tasks. They even write interactive programs in the shell using the dialog/xdialog utilities! (This is exactly how Slackware configuration scripts and many Knoppix utilities work) The shell programming language is included in the "gentleman's kit" of every qualified Unix administrator.

    [A. Soloviev - 09/25/2004]

/

    This guide describes a set of basic FTP commands and also suggests rules for working in FTP. Despite the fact that the material is given on the example of a text FTP client working with command line, we tried to make the advice universal.

    [A. Stoyanovsky - 09/25/2004]

/

    "VMWare Encyclopedia" is an electronic textbook on the VMWare virtual machine, written by the author of the tutorial "Linux for the User" Viktor Kostromin. The guide covers in detail all aspects of interaction with VMWare: installation, creation and launch of a new virtual machine, use of VMWare Tools (for Linux, FreeBSD and Microsoft Windows), guest OS installation, etc. This information will be useful to anyone who needs to work in two simultaneously various systems on one physical computer(for example, run specific Windows applications from under Linux)

    [V.A. Kostromin - 09/25/2004]

/

    We present to your attention a Russian translation of the "Slackware Linux Essentials" manual. This book is intended for beginner users of the Slackware Linux operating system. This does not mean that it will cover all the details of using the distribution. But the main possibilities of its use will be highlighted and the basic working knowledge for working in the system will be provided.

    [David Cantrell, Logan Johnson, Chris Lumens. Translation: V. Tolpekin - 09/25/2004]

/

    Frequently asked questions about setting up Slackware Linux

/

    This comprehensive guide, written by Qt co-developer Jasmine Blanchette and Trolltech Documentation Manager Mark Summerfield, walks you through the ins and outs of using Qt to write cross-platform applications. You will start with the basics of Qt, compulsory program"Hello, World!" and gradually rise to the heights of mastery. Unlike other tutorials, the book focuses exclusively on Qt. You'll learn how to create programs without the help of third-party wizards (such as those included in KDevelop) and will have a very good idea of ​​what's going on behind the scenes.

    [AND. Blanchett, M. Summerfield - 01/12/2004]

/

    I recently encountered a situation where my Linux system suddenly stopped booting. Since I had been experimenting with the master boot sector just before, it was natural to assume that the cause was damage to this very sector - either the boot program or the disk partition table. Reinstalling the bootloader did not solve the problem, so I started looking at the disk partition table. I started by searching for information about how the partition table works and partition recovery software. I will try to present everything that I managed to learn during these searches and experiments with partition tables on my disks in this article.

    [V.A. Kostromin - 12/30/2004]

/

    The book is devoted to a description of free POSIX-compatible (or Unix-like) operating systems, representatives of which are Linux, FreeBSD and other members of the BSD family, as well as their use as a universal platform for general (including home) purposes. The presentation is not tied to any specific OS or distribution, but contains a description of the general principles of installation, configuration and use of any of the representatives of this family.

    The author refuses the traditional "paper" publications linear circuit presentation of the material. The main storyline (book chapters) contain general principles devices of POSIX-compatible systems and work in them. It is aimed at a wide range of curious users, including beginners with no experience in Unix and Linux. The book's chapters alternate with interludes detailing the general material and illustrating it with examples from specific systems and distributions. They assume some preliminary preparation(to the extent of the general part) and may be of interest to “current” users of free Unix-like operating systems.

    [Alexey Fedorchuk - 10/13/2005]

"Books and manuals" - all materials in the section:

    This guide is about writing kernel modules for Linux 2.6. Issues such as interacting with user processes through device files and file system/proc, as well as the implementation of new system calls. The text is richly illustrated with examples.

We all need to get knowledge from somewhere. These can be your own experiments, articles from the Internet, forums. But the most reliable and trusted source is books. If you want to level up Linux knowledge to system administrator level, you will definitely need the best books about Linux. At the moment, there are already a large number of books about the Linux operating system, Unix, networks and programming, but most of them are distributed for money and not all are available in Russian.

In this article, I have collected 18 of the best books about Linux. They affect various areas: administration, programming, open source software philosophy, training for beginners. Not all of them have been translated into Russian. Yes, yes Linux users must know English. In the description of each book I will write in what language it is distributed and its price. However, most of these Linux books can be found for free on the Internet. Here are the best linux books for beginners and linux books for advanced users and professionals.

Linus Torvalds, David Diamond - Just for fun

The book is undoubtedly a Must Have! For every self-respecting Linux user. It was written by the creator Linux kernels- Linus Torvalds. In it, he tells his biography, describes how it all began, the process of creating and developing the Linux kernel and operating system. The book reflects Linus's vision of the concept of free software, further development Linux and the computer industry. The best book on Linux and the history of its creation.

Languages: original - Finnish and Swedish, translated into many languages ​​of the world, including Russian.

Year of issue: 2002

Price: For free

Yu. Vakhalia - UNIX from the inside

This book is not really about Linux, it's about the Unix kernel. It covers all aspects of the Unix kernel from a developer's point of view. Described internal organization kernels, their structures and their implementation. The book is clearly not for beginners and can be used as a textbook for studying the UNIX kernel in universities.

Language: Russian English

Year of issue: 2003

Price: $7

Andrey Robachevsky - UNIX operating system

Another book about the UNIX kernel, only this time from a Russian author. Its concept is similar to the previous book. Under consideration interior architecture kernels, input/output subsystems, memory and process management, system calls and libraries. The TCP/IP network protocols, network subsystems and sockets are slightly affected.

Language: Russian

Year of issue: 2010

Price: $26

D. N. Kolisnechenko, V. Allen - LINUX Complete Guide

This is one of the most comprehensive reference books on Linux, providing the most comprehensive understanding of the operating system. The book highlights three aspects: Linux for the user, Linux for the system and network administrator, and programming in Linux. Everything is covered here - from simple software installation to serious settings and internal system processes. The distributions mainly described are Red Hat, Fedora and Mandriva. This is the best book about Linux for beginners and experienced users alike.

Language: Russian

Year of issue: 2007

Price: $5

Evi Nemeth, Garth Snyder, Trent R. Hayne - Linux Administrator's Guide

This is a book written by professionals, the most complete guide on setting up and deploying most popular distributions Linux: Red Hat, Fedora, Suse Linux, Debian, Ubuntu and others. Everything is covered here - from basic administration tasks to more complex problems - network configuration and system performance.

Language: Russian

Year of issue: 2007

Paper book price: $31

David Tansley - Linux and UNIX: shell programming. Developer's Guide

This practical guide for programming in the Unix command interpreter - Bourme shell, which is fully compatible with Linux interpreter BASH. The book is suitable for both beginners and more experienced users. You will learn to create scripts to solve most problems that arise.

Language: Russian

Year of issue: 2001

James Armstrong - Unix Secrets

This book stands out among other UNIX publications. There are books on Linux for beginners that cover the basics; there are also many books for experts; this book is aimed at ordinary experienced users. It is not just described here Unix commands, but internal processes occurring in the system. The book will teach you how to use the right tools to solve your problems and unite teams to achieve best result. There is everything from the basics to developing your own programs.

Language: Russian English

Year of issue: 2001

Steven Spainauer, Ellen Seaver - Linux. Directory

This is a guide covering everything Linux commands, available on most distributions. There are commands ranging from system administration tools to program creation tools, all described in great detail with detailed descriptions of command options and their syntax, as well as several command interpreters.

Language: Russian English

Year of issue: 2001

Brian Kernighan, Rob Pike - UNIX. Software environment

The book describes UNIX through the lens of the C programming language. It will be useful to those who want to learn how to program using the tools supplied with the system. It describes input, working with files, environment variables, system signals and calls. After reading the book, you will be able to work with the system even more effectively.

Language: Russian

Year of issue: 2003

Scott Mann - Linux. Administration of TCP/IP networks

This is a book about the most popular protocol at the moment - the protocol networking between computers - TCP/IP. The description starts from TCP basics and OSI models and completes detailed review everyone OSI level with examples of implementation in Linux.

The book will be interesting network administrators and network application developers.

Language: Russian

Year of issue: 2008

Evi Nemeth - UNIX. System Administrator's Guide

The book is intended for system administrators running in a UNIX environment. It will be useful to both professionals and beginners who are just learning this difficult and very interesting activity. Many techniques used by experienced administrators are described here: configuration, increasing productivity, network administration, setting up mail exchange, connecting devices. A relatively new and best book on Linux for system administrators.

The book contains a large number of examples for most popular versions UNIX - FreeBSD and Red Hat.

Language: Russian

Year of issue: 2012

D. Bendel, R. Naper - Using Linux

IN linux book practical aspects of working with Linux are presented for both beginners and more experienced users. There is a description of system setup, KDE and Gnome desktops, and the internal architecture of the system is described. The book is aimed at Calculera, Red Hat and Debain Linux. This is an excellent book about Linux for new users, despite the fact that it was written quite a long time ago.

Language: Russian

Year of issue: 2005

Andrew Tanenbaum - Modern Operating Systems

This book will help you understand the big picture of modern operating systems and their functioning. Here is a description of not only how Linux works, but also Windows 8, as well as Android. The book also touches on multi-core systems and cloud computing.

Language: Russian

Year of issue: 2015

Daniel J. Barrett - Linux. Basic commands. Pocket Guide

Another command reference for Linux. Suitable for beginners as teaching aid, and experienced users. The commands are divided into categories, the location of the command on disk and its membership in the package are described. For some teams there are examples of working with them.

Language: Russian

Year of issue: 2007

Matt Welsh, Matthias Calle Dahlheimer, Terry Dawson, Lar Kaufman - Running Linux

This is one of the best Linux guides for beginners. Everything you need to understand, install and get started with this operating system is described here. The authors talk about possible difficulties and offer solutions that will make your work with Linux easier. Setup issues with which problems most often arise are discussed.

Language: Russian

Year of issue: 2004

Mark Mitchell, Geoffrey Oldham, Alex Samuel - Linux Programming. Professional approach

A book about programming in the Linux environment. You will learn to program programs with an interface that users are accustomed to, master multitasking, multi-threaded programming, and inter-task interaction. The book is aimed at programmers already familiar with the C programming language.

Language: Russian

Year of issue: 2003

Daniel Robbins - Linux Basics from the Gentoo Founder

A book for beginners in which Daniel Robbins, Chris Heizer and Aron Griffiths talk about Linux basics. Topics covered include Bash, basic commands Linux, working with files, effective work in the terminal and much more.

Language: English, but part has been translated into Russian.

Year of issue: 2010

Price: For free

Master Unix on your own within 24 hours

If you need a book about UNIX from scratch, this is it. The book is divided into 24 lessons, each of which will teach you a specific aspect of UNIX and includes practical problems.

Language: English

Year of issue: 2001

Price: $21

conclusions

This concludes the article. But these are definitely not all good Linux books, there are many more out there. What books about Linux/Unix would you recommend for beginners and experienced users to read? Write in the comments.

Before you can use the system, you must register yourself in the system. This is necessary because it is unwise to use the superuser name (root) for normal purposes. root user needed to execute privileged commands and maintain the system.

In order to register yourself, you need to log in as root and use the useradd or adduser command (depending on the distribution). For more information on this procedure, see Section 4.6.

3.2.2 Login.

When you log in, you will see a prompt on the screen, for example, something like this:

Mousehouse login:

Enter your login name and press Enter. Our hero larry will type the following:

Mousehouse login: larry Password:

Now enter your password. The password will not be displayed on the screen as you enter it, so be careful when typing. If you entered the password incorrectly, you will see a message on the screen:

Login is incorrect and you should try again.

It’s a very funny situation when the password is completely forgotten. Then you will have to log in as root and erase the password for the corresponding user (how this is done will be described below). An even funnier situation is when the root password is forgotten. It's funny to everyone except the root itself. Although the system, even from such a situation, can be brought to working condition, this is not easy to do.

When you finally enter your username and password correctly, you will officially be allowed into the system and can surf freely.

3.2.3 Virtual consoles.

This brings us to the burning question: What are teams? What happens when you type ``make love ""? The first word of the command line `` make "" is the name of the command that is supposed to be executed. Everything else on the command line is treated as command arguments.

When you enter a command, the shell does several things. First, it looks at what the command name could (should) be and whether it is a command internal to the shell (internal is a command that the shell knows how to execute. There are a number of such commands, we'll talk about them later). Shell also checks to see if the command is a synonym for another or if name substitution is required. If this is not necessary, the shell searches for a program on disk corresponding to this name. If the shell finds such a program, it executes it, passing it arguments from the command line.

In our example, the shell looks for a program called make and tries to execute it with the argument love . make is a program that is often used when compiling large programs, it takes as an argument the name of the compilation "target" file. In the case of ``make love "" we told the make command to compile love. Since make could not find a file with that name, it reported (in a somewhat amusing manner) that the command could not be executed and returned to the prompt.

What happens if we enter a command and the shell can't find the program with that command? Let's try: /home/larry# eat dirt eat: command not found. /home/larry# It's very simple, if the shell cannot find a program with the name given on the command line (here `` eat "), it displays an error message that explains why the command failed. You will often see this message if you type misspelled command names. (for example, you would type `` make love "" instead of `` make love "").

3.2.5 Logout.

/home/larry# exit to exit. There are other ways out, but this is the safest.

3.2.6 Change password.

3.2.7 Files and directories.

As already mentioned, directories can be nested inside each other. For example, let Larry have a directory called papers and another directory called notes. This directory contains files named math-notes and cheat-sheet. The cheat-sheet file path will be:

Papers/notes/cheat-sheet

So, the path is the route that must be taken to get to a specific file. The directory above this (sub)directory is called parent directory. Here the papers directory is the parent of the notes directory.

3.2.8 Directory tree.

Most Linux systems have a standard directory structure, which makes it easier to install a specific system. The structure is a directory tree, starting with the directory ``/"", known as the "root directory". The directories below / are among the most important subdirectories: among them /bin , /etc , /dev , and /usr . These directories in turn contain other directories that contain system configuration files, programs, etc.

3.3 First steps in Linux.

Before we begin, it's important to note that all file and command names are capital- and capital-sensitive (which is not the case on systems like MS-DOS). For example, the make command is very different from Make or MAKE . The same applies to directory names.

3.3.1 First walk.

Now we can log in and learn how to access files and change locations on the file system to make our life easier on the file system. The command for moving through a directory tree is cd , (``change directory""). You'll soon notice that many commonly used Linux commands are two or three letters long. cd command format:

CD directory where directory the name of the directory you want to go to. As we said, when you log in, you are automatically taken to your home directory. If Larry wants to move lower in the tree (for example, to the papers subdirectory), he should use the command: /home/larry# cd papers /home/larry/papers#

As you can see, the tooltip has changed to reflect the change in location (new working directory). Now he's in the papers directory and can look at his history-final file with the command:

/home/larry/papers# more history-final

To go back from the papers subdirectory, use the command:

/home/larry/papers# cd .. /home/larry#

Note the space between `` cd "" and `` .. "". Each directory contains the name `` .. "", which refers to the parent (for that directory) directory. Also each directory is named ``. "", which refers to himself. Therefore the command:

/home/larry/papers# cd . won't translate anywhere.

In the cd command you can use routes. To change to Carl's home directory, you can use the command:

/home/larry/papers# cd /home/karl /home/harl#

Using the cd command without arguments will return you to your home directory from anywhere in the tree:

/home/karl# cd /home/larry#

3.3.2 Viewing the contents of directories.

Now you know how to browse catalogs, but the question probably arises: “So what next?” Walking through directories in itself is useless, let's get acquainted with the new ls command. ls (LiSt) displays a list of files and directories (by default from the current directory). For example,

/home/larry# Is Mail letters papers /home/larry#

Here we see that Larry has three "storage units" in his current directory: Mail , letters and papers . But this doesn't say much: are they directories or files? You can use the -F option in the ls command to get more information:

/home/larry# Is --F Mail/ letters/ papers/ /home/larry#

/ appended to the right of file names indicates that these are subdirectories.

Using ls -F (note " -F " is written without a space) can also produce `` * "" at the end of some filenames. This will say what it is performed files or programs. If, when calling ls -F , nothing is appended to the right of the name, then this is a “normal” file, i.e. not a directory or an executable file.

In general, each UNIX command can have several options in addition to other arguments. These options are usually written with a `` - "" sign, as shown with ls -F . The -F option tells the ls command what to output Additional information about the file type.

If you type a directory name into the ls command, it will print the contents of the specified directory:

/home/larry# Is -F papers english-lit history-final masters-thesis notes/ /home/larry#

Or, to make it more interesting, let's look at what's in the system /etc/ directory:

/home/larry# Is /etc Images ftpusers lpc rc.new shells adm getty magic rc0.d startcons bcheckrc gettydefs motd rc1.d swapoff brc group mount rc2.d swapon brc inet mtab rc3.d syslog.conf csh.cshrc init mtools rc4.d syslog.pid csh.login init.d pac rc5.d syslogd.reload default initrunlvl passwd rmt termcap disktab inittab printcap rpc umount fdprm inittab.old profile rpcinfo update fstab issue psdatabase securetty utmp ftpaccess lilo rc services wtmp /home/larry #

For users who have exited MS-DOS, it is useful to note that file names can be longer than 8 characters and contain a period at any position. You can even use multiple dots in one name.

Let's climb up the tree (translator’s note: it just so happens that in UNIX the initial top of the tree is the “root”), using the command `` cd .. "" and then going down to another directory (/usr/bin):

/home/larry# cd .. /home# cd .. /#cd usr /usr# cd bin /usr/bin#

You can, of course, move through directories in large steps, for example, immediately run cd /usr/bin .

Try browsing through the directories using the ls and cd commands. In some cases, you may encounter an annoying `` Permission denied "" message. This is just the UNIX security system working; you must have permission to execute commands in certain directories. We'll talk more about this later.

3.3.3 Creating new directories.

It's time to learn how to create directories. This is done with the mkdir command. Try this:

/home/larry# mkdir foo /home/larry# Is -F Mail/ foo/ letters/ papers/ /home/larry# cd foo /home/larry/foo# Is /home/larry/foo#

Our congratulations to you! You have just created a new directory and entered it. Since there are no files in this new directory yet, let's take a look at how to copy files.

3.3.4 Copying files.

You and I created unnecessary files by studying the ls command. To remove files, use the rm (ReMove) command:

/home/larry/foo# rm bells sells /home/larry/foo# Is -F shells /home/larry/foo#

We have nothing left except shells, but let's not worry. Note that the rm command will not prompt you before deleting, so be careful. User orders are not discussed, they are carried out!

A related command to rm is rmdir . This command removes directories, but only empty directories. If there are any files or subdirectories in the directory, she will sign in powerlessness.

3.3.7 View files.

The more and cat commands are used to view the contents of files. more displays the file screen by screen, while cat displays the entire file at once. (translator's note: if the file is long, then when using the cat command the file will flash and the last lines will remain on the screen).

To view the shells file, use the command:

/home/larry/foo# more shells

When using the more command, press Spacebar to go to the next page and b to go back to the previous page. Pressing q will exit more.

Now try the command cat etc/termcap/. The text flashes by too quickly for you to read it. In fact, the `` cat "" (conCATenate) command is mainly used for other purposes, for the same concatenation of multiple files. This will be discussed further.

3.3.8 Receiving prompt assistance.

Almost every UNIX has what is called a "manual pages") . This man command contains documentation on various commands systems, resources, configuration files. For example, if you want to find information about other options for the ls command, type: /home/larry# man Is and the ls manual pages will be displayed.

Unfortunately, most of the manual pages are written with users in mind who have some understanding of how the corresponding commands work. Therefore, the Manual pages usually contain command reference information rather than tutorial material.

But the Guide is invaluable for refreshing your memory if you've forgotten the command syntax. The manual can also tell you a lot about commands that we won't even mention in this book. I suggest you look in the Guide for the teams we have already discussed and all the ones we will be meeting. You will find that not all commands have a Guide. There are several reasons for this. One, some pages of the Manual have simply not been written yet ( the Linux Documentation Project, a documentation program for Linux, seems to be responsible for solving this problem. We have already collected most of the documentation). Secondly, the team can be internal team shell or alias, as discussed, in each of these cases there is no own pages. Let's take cd as an example, which is internal shell command. Shell executes this command, but it does not have its own separate program.

3.4 Access to MS-DOS files.

If, for some unexplained reason, you need to provide access to MS-DOS files, you can do it easily.

Typically, to access MS-DOS files, you simply mount an MS-DOS partition or floppy disk and access the files through the Linux file system. For example, if you insert an MS-DOS floppy disk into /dev/fd0 (A: in MS/DOS notation), the command: # mount -t msdos /dev/fd0 /mnt will mount the diskette to the /mnt directory. See section 4.8.4 for more information on mounting floppy disks.

Likewise, you can mount an MS-DOS partition on your hard drive. If you, for example, have an MS-DOS partition on /dev/hda1 , the command is:

# mount -t msdos /dev/hdal /mnt will mount it. Don't forget to unmount the DOS partition when you're done working with it. You can mount the MS-DOS partition automatically at boot time if you add a line to the /etc/fstab file (see Section 4.4). For example, the following line in the /etc/fstab file mounts the DOS partition /dev/hda1 into the /dos directory: /dev/hdal dos msdos defaults

You can also mount the VFAT file system used by Windows 95/98/2000:

# mount -t vfat /dev/hdal /mnt This way you will be able to work with long names files. This approach is only applicable to sections that actually store long names. You cannot work with long names if the partition is mounted as normal FAT16. Note: VFAT and FAT32 are supported by the same kernel module, so if you can mount a VFAT partition, you can mount a FAT32 partition. This situation sometimes leads to funny situations, such as the case with Red Hat Linux, in which there was no mention of FAT32, although there was support for it (they were talking only about VFAT).

3.6 File system exploration.

3.7 Types of shells.

3.8 Wildcards.

Note that when we use `` * "", none of the files with names starting with `` . "" is not displayed: /home/larry# Is * frog Joe stuff /home/larry# This is a precaution: if `` * "" would select filenames starting with `` . "", she would also choose the names `` . "" and ``.. "". But this can be dangerous when executing a number of commands.

Another wildcard character `` ? "". `` ? "" allows you to substitute exactly one character. So `` ls ? "" will only return single-character filenames, while `` ls termca? "" will print ``termcap "", but will not display ``termcap.backup "". Here's another example:

/home/larry# Is J?e Joe /home/larry# Is f??g frog /home/larry# Is ????f stuff /home/larry#

As you can see, the wildcard allows you to describe many files at once. When we looked at basic commands, we said that the cp and mv commands can copy or move multiple files at once. For example,

/home/larry# cp /etc/s* /home/larry will copy all files in /etc with names starting with ``s"" to the /home/larry directory. The format of the cp command is actually: cp files destination where files a list of files to be copied, and destination this is the file or directory to which the copy is made. mv has a similar syntax.

Please note that if you are copying or moving more than one file, must be a directory. You can only copy or move one file per file.

3.9 Linux channels.

3.9.1 Standard input and standard output.

Now, let's assume that we want to send the sorting result to a file in order to save the list of planned purchases somewhere. Shell gives us the opportunity redirect standard output to a file using the ``>"" symbol. Here's how it works:

/home/larry/papers# sort>shopping-list bananas carrots apples Ctrl-D /home/larry/papers# As you can see, the result of the work sort commands is not displayed on the screen, but is instead saved in the shopping-list file. Let's look at this file: /home/larry/papers# cat shopping-list apples bananas carrots /home/larry/papers# Now we can not only sort (order) the list of planned purchases, but also save it! But let's say we stored our unsorted original purchasing list in a file called items. One way to sort and save it is to sort the file with the given name, instead of getting the file from standard input, and redirect standard output to the file. For example: /home/larry/papers# sort items>shopping-list /home/larry/papers# cat shopping-list apples bananas carrots /home/larry/papers# But this can be done in another way. Not only can standard output be redirected, but also standard output input, using the `` character<"": /home/larry/papers# sort

Technically, sort

3.12 Work management.

3.12.1 Tasks and processes.

3.13 Using the vi editor.

A text editor is a program used to edit files that contain text, such as letters, C programs, or system configuration files. Although there are many different editors on Linux, the only editor you are guaranteed to find on any UNIX is vi (``visual editor''). vi is not the easiest editor to use. But since it is so common in the UNIX/Linux world and you might need it at any time, it deserves at least some description here.

3.13.1 Concepts.

When using vi, you can be in one of three operating modes at any time. These modes are known as command mode, insert mode And last line mode.

3.13.4 Deleting text.

To exit vi without making changes to a pre-existing file, use the command:q! .

When you type `` : "", the cursor will move to the last line of the screen because you will be in last line mode: COW IS THE TIME FOR ALL HUMANS TO COME TO THE AID OF THE HUNGRY.

Some advanced commands can be executed in last line mode. One of them is q! , which allows you to exit vi without writing. The command:wq saves (writes) the file and then exits vi. The ZZ command (in command mode, without the ` : "") is equivalent to :wq . Remember that you must press Enter after typing the command in last line mode. If you want to write a file without exiting vi , just use :w .

3.13.8 Editing another file.

To edit another file, use the command:e. For example, to stop editing the file test and continue editing the file foo , use the command:

COW IS THE TIME FOR ALL HUMANS TO COME TO THE AID OF THE HUNGRY. foci

If you use :e without first saving the file, you will first get an error message: No write since last change ("edit" overrides). which simply means that vi doesn't want to edit another file until the first one is saved. At this point you can use :w to save the original file and then use :e or use the command: COW IS THE TIME FOR ALL HUMANS TO COME TO THE AID OF THE HUNGRY. foci `` ! "" tells vi that you actually mean edit the new file without saving the changes you made to the first one.

3.13.9 Inserting other files.

3.13.10 Executing Shell commands.

You can also run commands directly from vi. Team:r! works like :r , but instead of reading a file, it inserts the output of the given command into a buffer at the location where the cursor is. For example, if you use the command:

:r! Is -F you will get as a result: COW IS THE TIME FOR ALL WOMEN TO COME TO THE AID OF THE HUNGRY letters/ misc/ papers/

You can run a command while in the vi editor and return to the editor when it completes. For example, if you use the command:

Is -F The command ls -F will be executed, and the result will be displayed on the screen, rather than pasted into the file being edited. If you use the command: shell vi will launch a shell, which will allow you to temporarily "put aside" vi and run the commands. After exiting the shell (using the exit command), you will be returned to vi.

3.13.11 Getting help with vi.

vi isn't very good at online help (and neither are most UNIXes), but you can always look at the vi manual pages. vi is the "visual part" of the ex editor; this ex does a lot to maintain last line mode and command mode in vi. So in addition to reading the vi manual, also look at the ex manual.

3.14 Setting up the environment.

Shell provides various mechanisms for customizing your work environment. We mentioned earlier that the shell is more than an interpretation command: it is also a powerful programming language. But discussing shell programming would take us a long way, and we'd like to introduce you to some ways to make your work on UNIX easier by taking advantage of some additional useful shell features.

As we mentioned earlier, different shells use different syntax to write their programs. For example, Tcsh uses a syntax similar to C, while the Bourne shell has a different syntax. In this section we will not deal with their differences, but will look at examples using the Bourne shell syntax.

3.14.1 Shell scripts.

Let's say you frequently use a series of commands and would like to reduce the amount of constant typing by grouping them into one command. For example, the commands: /home/larry# cat chapter1 chapter2 chapter3 >book /home/larry# wc -1 book /home/larry# Ip book concatenates files containing book chapters: chapter1 , chapter2 , chapter3 and places the result in the file book . The number of lines in the book (in the book file) is then counted and displayed on the display, and finally printed with the lp command.

Instead of entering these commands each time, you can collect them into one script or script (batch file). We'll briefly describe shell scripts later. And the script that will execute the above commands will look like this:

#!/bin/sh # A shell script to create and print the booh cat chapter1 chapter2 chapter3 > book wc -1 book Ip book

If this script is placed in the makebook file, then you can simply use the following command:

/home/larry# makebook which will execute all script commands. Shell scripts are simple text files that you can create using an editor like emacs or vi.

Let's look at this scenario. The first line `` #! bin/sh/"" tells the file that this file is a script and tells the shell how to execute the script. In this case, you need to pass the script to the /bin/sh command for execution, where /bin/sh is the shell program itself. Why is it important? On most UNIX systems, /bin/sh is a Bourne-type shell, such as bash. By initiating a shell script, it is executed using /bin/sh , and we ensure that the script will be executed under a Bourne shell (and not, say, a C shell). This script will run under the Bourne shell even if you are using Tcsh (or some other C shell) as your working shell.

The second line is