Manual
Site: | Savoir-faire Linux Formation |
Course: | In english |
Book: | Manual |
Printed by: | Visiteur anonyme |
Date: | Thursday, 21 November 2024, 10:33 AM |
1. A few characteristics
- A multi-user connection-oriented system.
- Users and groups.
- Concept of superuser (root).
- Login: alphanumerical, maximum of eight characters is a UNIX standard (more so in the case of Linux).
- Password: assigned by root, user-modifiable.
- Case-sensitivity (UPPER-CASE/lower-case).
- Interfaces: text (shell) or graphical (X/Window).
- Default shell is BASH (Bourne Again SHell).
2. Users and groups
- To connect to a Linux system, the user must be created on the system by the administrator (root).
- Each user possesses attributes on the system: name, password, groups, work directory (the home directory), a default shell.
- A user belongs to a main group and then to a number of secondary groups.
3. Shell prompt (invite)
The shell's invite (for bash, in this case) appears as follows:
A standard shell invite:
[jane@name_machine /home/jane]$
By default, the $ (dollar) symbol is used at the end of the invite for any connection initiated by ordinary users. When the connection is established by the superuser (root), the symbol used at the end of the invite is then the # (number sign) symbol.
A root shell invite:
[root@name_machine /root]#
4. A few commands and basic concepts
- The “/” (slash) symbol serves as a separator character in paths.
- The root directory of the tree structure is the “/” directory.
- Commands previously entered on the shell can be recalled using the keyboard's up and down arrow buttons.
Basic commands
The pwd (print working directory) command displays the path of the current directory.
The ls (listing) command displays a list of files and sub-directories of the current working directory, or that of the directory path given as argument.
The cd (change directory) command changes the current working directory, allowing to move within the tree structure.
The date command displays or sets the system time and date.
5. Basic directories
Directory | Description |
---|---|
/bin | User commands files |
/boot | System initialization files |
/dev | Peripherals (devices) files |
/etc | Applications and system services configuration files |
/home | Conventionally, personal directories for users with an account on the system can be found here |
/lib | System and applications libraries and core modules |
/lost+found | Used for file retrieval after a check with fsck |
/mnt | Contains directories for mounting removable file systems (disk reader, CD-ROM, etc.) |
/opt | Local applications |
/root | Superuser's home directory |
/sbin | System administration commands files |
/tmp | Temporary files |
/usr | Applications, libraries, and documentation. |
/var | Files for saving variable data: journals (logs), queues (spool) |
6. Online documentation
The online documentation can be very useful for obtaining information on:
- The purpose of a command
- The syntax and options of a command
- How-to for an application
We can obtain this documentation from various sources:
- The manual: the man command
- Info files: the info command
- HOW-TOs and hands-on documentation: the /usr/share/doc/ directory.
The manual: the man command
Accessing the manual page:
man [command]
man [option] [command]
$ man ls $ man man $ man -S5 passwd, $ man -k keyword
Use of the man command
Section | Contents |
---|---|
1 | User commands |
2 | System calls |
3 | Functions / libraries |
4 | Special files and peripherals |
5 | File formats and conventions |
6 | Games |
7 | Macros |
8 | System administration commands |
9 | Core (Kernel) |
Information layout on a manual page
Here is the presentation layout schema used in the manual:
NAME | Name of the command |
SYNOPSIS | Command's usage summary |
DESCRIPTION | Detailed description of the command |
OPTIONS | Explanation for each of the command's options |
ENVIRONMENT | Lists the names and values of the environment variables used by the command |
EXAMPLES | Examples of use |
FILES | Description of files used by the command |
SEE ALSO | Suggests reference pages on related topics |
WARNINGS | Displays uses which may cause problems with this command |
DIAGNOSTICS | Explains the meaning of diagnostic messages which may be outputted by the command |
BUGS | Enumerates known bugs affected this command |