Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revision | |||
| en:veos:admin_manual [2024/09/26 15:29] – external edit 127.0.0.1 | en:veos:admin_manual [2026/05/28 15:49] (current) – elena.krasnobryzh | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| - | ====== Administrator' | ||
| {{indexmenu_n> | {{indexmenu_n> | ||
| + | ====== VEOS Administrator Guide ====== | ||
| - | ===== General principles of VEOS operation ===== | + | **VEOS** is a multi-user Linux-based operating system for managing telecom services.\\ |
| + | This guide contains basic operating principles, administration commands, and configuration examples. | ||
| - | ==== Processes | + | **Key VEOS features: |
| + | * Compatibility with standard Linux commands | ||
| + | * Management through the **bash** command shell (default) | ||
| + | * File system compliant with the **FHS** standard | ||
| + | * Initialization through **systemd** | ||
| + | * Access control based on users and groups | ||
| - | VEOS is a multi-user integrated system, i.e. it is designed for simultaneous operation of several users. | + | ---- |
| - | The user can either work in the system himself, executing some sequence of commands, or application processes can be executed on their behalf. The user interacts with the system through a command interpreter, | + | ===== 1. Process management |
| - | === OS functioning processes === | + | A **process** is a program loaded into the server memory and currently being executed. |
| + | Processes are divided into two types: | ||
| - | All programs that are loaded into the server memory (i.e. executed) at the current time are called processes. The processes can be divided into two main classes: system processes and user processes. | + | ^ Process type ^ Description ^ Examples ^ |
| + | | **System** | Ensure | ||
| + | | **User** | Started | ||
| - | VEOS was originally developed as a multitasking system. It uses technologies tried and tested by other UNIX implementations - VEOS predecessors. The process | + | **Commands for process |
| - | ==== OS File System ==== | + | ^ Action ^ Command ^ Note ^ |
| + | | View all processes | '' | ||
| + | | Process tree | '' | ||
| + | | Run in background | '' | ||
| + | | Stop a process by PID | '' | ||
| - | VEOS uses the Linux file system, which is a single tree. The root of this tree is a directory called root and denoted by /. Parts of the file system tree can be physically located in different partitions of different disks or on other computers altogether — this is clear to the user. The process of attaching a partition file system to a tree is called mounting, and deleting is called unmounting. For example, the CD-ROM file system in the distribution is mounted by default in the / | + | == Background mode == |
| - | > cd .. | + | A process |
| - | + | If the process requires input, it will be stopped by the kernel until returned to normal mode. | |
| - | === Directory structure === | + | |
| - | Root directory /: | + | == Example == |
| - | * /bin — command shells, basic utilities; | + | <code bash> |
| - | * /boot — contains the system kernel; | + | # Run a script |
| - | * /dev — pseudo files of devices that allow to work with devices directly. Files in /dev are created by the udev service; | + | ./backup.sh & |
| - | * /etc — system-wide configuration files for most programs in the system; | + | |
| - | * /etc/rc?.d, / | + | |
| - | * /etc/passwd – a user database that contains information about the user name, their real name, personal directory, their encrypted password and other data; | + | |
| - | * /etc/shadow — shadow user database. In this case, the information from the /etc/passwd file is moved to / | + | |
| - | * /home — users' home directories; | + | |
| - | * /lib — contains files of dynamic libraries required for the operation of most applications, | + | |
| - | * /lost+found — recovered files; | + | |
| - | * /media — pluggable media (directories for mounting removable devices file systems); | + | |
| - | * /mnt — temporary mount points; | + | |
| - | * /opt — helper packets; | + | |
| - | * / | + | |
| - | * /proc – a virtual file system stored in the computer memory when the OS is loaded. This directory contains the latest information about all processes running on the computer; | + | |
| - | * /root — home directory of the system administrator; | + | |
| - | * /run — application status files; | + | |
| - | * /sbin — a set of programs for administrative work with the system (system utilities); | + | |
| - | * /selinux — SELinux virtual file system; | + | |
| - | * /srv — virtual service data; | + | |
| - | * /sys — a file system containing information about the current state of the system; | + | |
| - | * /tmp — temporary files; | + | |
| - | * /usr — user binaries and read-only data (programs and libraries); | + | |
| - | * /var — files for storing changing data (working program files, queues, logs). | + | |
| - | /usr directory: | + | # View background jobs in the current session |
| - | * /usr/bin — additional programs for all accounts; | + | jobs |
| - | * /usr/sbin — commands used during system administration and not intended to be placed | + | </code> |
| - | * /usr/local – a location where it is recommended to place files installed without using packet managers, the internal organization of directories is almost the same as the root directory; | + | |
| - | * /usr/man — directory where the man reference manual files are stored; | + | |
| - | * /usr/share – a directory for hosting public files of most applications. | + | |
| - | /var directory: | + | ---- |
| - | * /var/log — the place where the system and application audit files are stored; | + | |
| - | * /var/spool – a directory for storing files in the processing queue for a particular process (print queues, unread or unsent emails, cron tasks, etc.). | + | |
| - | | + | ===== 2. Working with the file system ===== |
| - | === File structure organization | + | |
| - | The system of users home directories helps to organize the safe work of users in a multi-user system. Outside of their home directory, the user has minimal rights (usually reading and executing files) and cannot damage the system, for example, by deleting or modifying | + | VEOS uses a **hierarchical Linux file system** — a single tree starting |
| + | Different partitions and devices are mounted into directories | ||
| - | * lowercase and uppercase letters; | + | === 2.1. Root directory structure === |
| - | * underscore character (_); | + | |
| - | * dot (.). | + | |
| + | Most important directories: | ||
| - | <note important> | + | ^ Directory ^ Contents ^ |
| + | | '' | ||
| + | | '' | ||
| + | | '' | ||
| + | | '' | ||
| + | | '' | ||
| + | | '' | ||
| + | | '' | ||
| + | | '' | ||
| + | | '' | ||
| + | | '' | ||
| + | | '' | ||
| + | | '' | ||
| - | For convenience, | + | === 2.2. Navigating |
| - | === Disk and partition names === | + | ^ Command ^ Action ^ |
| + | | '' | ||
| + | | '' | ||
| + | | '' | ||
| + | | '' | ||
| + | | '' | ||
| - | All physical devices of your computer are displayed in the /dev directory | + | <note important> |
| - | | + | **Important: |
| - | | + | </note> |
| - | etc. Disks are designated /dev/sdX, where X is a, b, c, d, e, ... depending on the serial number of the disk on the bus. A disk partition | + | === 2.3. Disk and partition |
| - | === Partitions required for VEOS operation === | + | Devices are displayed in '' |
| - | For the OS operation, at least two partitions shall be created on the hard disk(s): the root one (that is, the one that will contain the / directory) and the swap partition. The size of the latter, as a rule, ranges from one to two times the computer's RAM size. If there is a lot of free space on the disk, then separate partitions for the /usr, /home, /var directories may be created. | + | ^ Device ^ Name ^ |
| + | | First disk | '' | ||
| + | | Second | ||
| + | | Disk partition | '' | ||
| - | ===== Working with the most frequently used components ===== | + | **Minimum partitions required for VEOS installation: |
| + | * Root partition '' | ||
| + | * '' | ||
| + | * Optional: separate partitions for '' | ||
| - | ==== Virtual Console ==== | + | ---- |
| - | VEOS provides access to virtual consoles from which several working sessions in the system may be carried out simultaneously. Switching between the first six virtual consoles is performed by pressing the keyboard shortcut Alt+F1 — Alt+F6 (Ctrl+Alt+F1 — Ctrl+Alt+F6). | + | |
| - | ==== Command shells | + | ===== 3. The bash shell ===== |
| - | Command interpreters | + | **Bash** |
| - | * bash — Bourne Again Shell, the most common shell | + | === 3.1. Useful keyboard shortcuts === |
| - | * ksh — Korn Shell, a well-known shell in UNIX systems. | + | |
| - | You can check which shell is currently being used by running | + | ^ Shortcut ^ Action ^ |
| - | $ echo $SHELL | + | | '' |
| + | | '' | ||
| + | | '' | ||
| + | | '' | ||
| + | | '' | ||
| - | The default shell is Bash — the most common shell under Linux, which keeps a command history and provides for their editability. | + | === 3.2. Command history === |
| - | ==== Bash Command | + | ^ Command |
| + | | '' | ||
| + | | '' | ||
| + | | '' | ||
| - | Bash has several techniques for working with a command string. For example, the following combinations can be used: | + | === 3.3. Grouping and chaining commands === |
| - | * Ctrl+A — go to the beginning of the string; | + | |
| - | * Ctrl+U — delete the current string; | + | |
| - | * Ctrl+C — stop the current task. | + | |
| - | To enter multiple commands in one string, the separator ";" can be used. You can navigate through the history of commands using the keys ↑ (" | + | ^ Operator ^ Purpose ^ Example ^ |
| - | > !command number | + | | '' |
| - | If you enter: | + | | '' |
| - | | + | | '' |
| - | the last of the entered commands will start. | + | | '' |
| + | | '' | ||
| - | In Bash, command names may be substituted from the general list of commands, which greatly facilitates working | + | **Example |
| - | > gu | + | <code bash> |
| - | Then press the Tab key. Since there are several possible ways to complete the command in this case, you need to press the Tab key again to get a list of names starting with gu. In the proposed example, the following list can be got: | + | # Sort the list of files in /etc in reverse order |
| - | > gu | + | ls -la /etc | sort -r |
| - | guile gunzip gupnp-binding-tool | + | </code> |
| - | If you type: n (gunzip is the only name, the third letter of which is " | + | |
| - | | + | |
| - | ==== Command ==== | + | ---- |
| - | The simplest command consists of a single " | + | |
| - | > ls | + | |
| - | > ls -l | + | |
| - | Such parameters are called keys or execution modifiers. The key belongs to this particular command and does not make sense by itself. This is how it differs from other parameters (for example, file names, numbers) that have their own meaning, independent of any command. Each command can recognize a certain set of keys and change its behavior accordingly. The same key can define completely different values for different commands. | + | |
| - | There is no rigid standard for the key format, but there are agreements: | + | ===== 4. User and permission management ===== |
| - | * If the key starts with -, then this is a simple key. - is usually followed by a single character, most often a letter denoting the action or property that this key gives to the command. This makes it easier to distinguish keys from other parameters. | + | |
| - | * If the key starts with –, then it is called an extended key. The extended key format begins with two –characters, | + | |
| - | Some keys have both a simple | + | |
| - | ==== Docking commands in the VEOS system ==== | + | Users are identified by **UID** (numeric identifier), |
| - | === Standard input and standard output | + | === 4.1. Basic commands |
| - | Многие команды системы имеют так называемые стандартный ввод (standard input) и стандартный вывод (standard output), часто сокращаемые до stdin и stdout. Ввод и вывод — это входная и выходная информация для данной команды. Программная оболочка делает так, что стандартным вводом является клавиатура, | + | ^ Action ^ Command ^ Note ^ |
| - | Пример с использованием команды cat. По умолчанию команда cat читает данные из всех файлов, которые указаны в командной строке, и посылает эту информацию непосредственно в стандартный вывод (stdout). Следовательно, | + | | View information about the current user | '' |
| - | cat / | + | | Change password | '' |
| - | выведет на экран сначала содержимое файла. | + | | Change another user's password | '' |
| - | Если имя файла не указано, программа cat читает входные данные из stdin и возвращает их в stdout. Пример: | + | | Add a user | '' |
| - | cat | + | | Modify user parameters | '' |
| - | Привет. | + | | Delete a user | '' |
| - | Привет. | + | |
| - | Пока. | + | |
| - | Пока. | + | |
| - | Ctrl-D | + | |
| - | Каждую строку, | + | |
| + | === 4.2. Groups and permissions === | ||
| - | Many system commands have so-called standard input and standard output, often abbreviated to stdin and stdout. Input and output are the input and output information for a given command. The software shell makes it so that the standard input is the keyboard, and the standard output is the monitor screen. Example using the cat command. By default, the cat command reads data from all files that are specified on the command string and sends this information directly | + | Each user belongs |
| - | Example: | + | Additional groups are assigned using '' |
| - | cat \\ | + | |
| - | Hello. \\ | + | |
| - | Hello. \\ | + | |
| - | Bye. \\ | + | |
| - | Bye. \\ Ctrl-D \\ | + | |
| - | The cat program returns each string entered from the keyboard to the screen. When entering information from standard input, the end of the text is signaled by entering | + | **Example |
| + | <code bash> | ||
| + | usermod -G wheel test | ||
| + | </ | ||
| - | === Redirecting input and output === | + | **View user groups:** |
| + | <code bash> | ||
| + | id test | ||
| + | </ | ||
| - | If necessary, the standard output may be redirected using the > symbol and standard input using the < symbol. Filter is a program that reads data from standard input, processes it in some way, and directs | + | <note important> |
| + | **Attention: | ||
| + | </ | ||
| - | === Using docked commands === | + | ---- |
| - | Command docking | + | ===== 5. Superuser mode (root) ===== |
| - | > ls -la /etc| sort -r | + | |
| - | -rw-r--r--. | + | |
| - | -rw-r--r--. | + | |
| - | -rw-r--r--. | + | |
| - | -rw-r--r--. | + | |
| - | Output a list of files in parts: | + | The **superuser |
| - | > ls /usr/bin | more | + | |
| - | If you need to display the last alphabetically named file in the current directory, the following command can be used: | + | |
| - | > ls | sort -r | head -1 notes | + | |
| - | where the head -1 command displays the first string of the input string stream it receives | + | |
| - | === Redirecting output in Append mode === | + | === 5.1. The '' |
| - | The effect of using the > symbol to redirect the file output is destructive; | + | ^ Command ^ Result ^ |
| - | > ls > file-list | + | | '' |
| - | will destroy | + | | '' |
| - | < | + | **Why '' |
| + | Without the hyphen, the '' | ||
| - | ===== Superuser Mode ===== | + | === 5.2. The '' |
| - | VEOS is a multi—user system, and therefore the user is a key concept for organizing the entire access system. The files of all users in VEOS are stored separately, each user has their own home directory in which they can store their data. Other users' | + | Allows executing individual commands as root without fully switching |
| + | To use ''%%sudo%%'', | ||
| - | System utilities require superuser privileges for their work, because they make changes to system files. When they are launched, a warning is displayed about insufficient rights of the current user. | + | ---- |
| - | For experienced users who know how to work with the command string, there are two different ways to get superuser rights. The first is to log in as root. The second way is to use a special su (shell of user) utility, which allows to execute one or more commands on behalf of another user. By default, this utility executes the sh command from the root user, that is, it starts the command interpreter. The difference from the previous method is that it is always known who exactly launched su, which means it is clear who performed a certain administrative action. In some cases, it is more convenient to use not su, but the sudo utility, which allows to execute only preset commands. | + | ===== 6. systemd initialization system ===== |
| - | <note important> | + | **systemd** is the primary initialization |
| - | To switch to superuser mode, enter the su - command in the terminal. | + | === 6.1. Basic service management commands === |
| - | If you use the su command without | + | ^ Action ^ Command (systemd) ^ Sysvinit equivalent ^ |
| + | | Start a service | '' | ||
| + | | Stop a service | '' | ||
| + | | Restart a service | '' | ||
| + | | View service status | '' | ||
| + | | Enable autostart | '' | ||
| + | | Disable autostart | '' | ||
| - | At the same time, the value of the environment variables, in particular $PATH, remains the same as the user's: there will be no /sbin, /usr/sbin directories in the $PATH variable, the route, shutdown, mkswap and other commands will be unavailable without specifying the full name. Moreover, the $HOME variable will indicate the user's directory, all programs running in superuser mode will save their settings with root rights in the user's directory, which may cause problems in the future. To avoid this, you should use su -. In this mode, su will launch the command interpreter as a login shell, and it will behave exactly as if root had registered in the system. | + | **Example for the '' |
| + | <code bash> | ||
| + | systemctl start fastdpi.service | ||
| + | systemctl status fastdpi.service | ||
| + | systemctl enable fastdpi.service | ||
| + | </ | ||
| - | ===== User Management ===== | + | === 6.2. Viewing logs (journal) |
| - | Users and groups within | + | ^ Command ^ Action ^ |
| - | | + | | '' |
| - | Such an entry means that the user test (digital identifier 500) is a member of the test and rpm groups. Different groups may have different access levels to certain directories; | + | | '' |
| + | | '' | ||
| + | | '' | ||
| - | <note important>Due to the fact that most of the privileged system utilities in VEOS have not SUID-, but SGID-bits, be extremely careful and cautious in reassigning group rights to system directories.</note> | + | **Example: |
| + | <code bash> | ||
| + | journalctl | ||
| + | </code> | ||
| - | ==== The passwd command ==== | + | ---- |
| - | The passwd command supports the traditional options of passwd and shadow utilities. Syntax: | + | |
| - | passwd [PARAMETERS...] < | + | ===== 7. Frequently asked questions |
| - | -k, --keep-tokens | + | |
| - | -d, --delete | + | |
| - | -l, --lock | + | |
| - | -u, --unlock | + | |
| - | -e, --expire | + | |
| - | -f, --force | + | |
| - | -x, --maximum=DAYS | + | |
| - | -n, --minimum=DAYS | + | |
| - | -w, --warning=DAYS how many days before the password expires it is required to start warning the user (root only) | + | |
| - | -i, --inactive=DAYS how many days after the password expires the account shall be locked (root only) | + | |
| - | -S, --status | + | |
| - | --stdin | + | |
| - | Exit code: Upon successful completion, passwd terminates with exit code 0. Exit code 1 means that an error has occurred. The text description of the error is output to the standard error stream. The user can change their password at any time. The only thing required to change the password is to know the current password. Only the superuser can update another user's password. | + | **Question:** Which command shell is used in VEOS by default? |
| + | **Answer:** **bash**. You can check it using '' | ||
| - | ==== Adding a new user ==== | + | **Question: |
| + | **Answer:** Run '' | ||
| - | To add a new user, use the useradd | + | **Question: |
| - | > useradd test | + | **Answer:** '' |
| - | > passwd test | + | |
| - | The test user password is changed. | + | |
| - | New password : | + | |
| - | As a result, a test user with a specified password has appeared in the system. If the password turned out to be too weak from the system point of view, it will warn you about it. The user can later change their password using the passwd command — but if they try to put a weak password, the system will refuse to change it (unlike | + | **Question: |
| + | **Answer: | ||
| - | ==== User records modification ==== | + | **Question: |
| + | **Answer:** Use '' | ||
| - | The usermod utility is used to modify user records: | + | **Question: |
| - | > usermod -G wheel,test test | + | **Answer:** Yes, if the user is added to the '' |
| - | Such a command will change | + | |
| - | > usermod | + | ---- |
| - | The user name will be changed from test to test1. | + | < |
| + | < | ||
| - | The usermod | + | **Document last reviewed:** 2026-05-12\\ |
| + | **Applicable VEOS version:** 8.6 and later\\ | ||
| + | **Author:** VAS Experts | ||
| - | ==== Deleting users ==== | + | </details> |
| - | + | ||
| - | To delete users, use userdel. | + | |
| - | + | ||
| - | The userdel test1 command will remove test1 user from the system. If the -r parameter is additionally set, the user home directory will also be destroyed. A user cannot be deleted if they are still working in the system at the moment | + | |
| - | + | ||
| - | ===== The systemd initialization system ===== | + | |
| - | + | ||
| - | + | ||
| - | ==== Starting the operating system ==== | + | |
| - | The algorithm for starting the computer is approximately as follows: | + | |
| - | - The BIOS of the computer. | + | |
| - | - The system loader (for example, LILO, GRUB or another). In the loader, you can set the system startup parameters or select the system to run. | + | |
| - | - The Linux kernel is loaded. | + | |
| - | - The first process in the system is started for execution — init. | + | |
| - | - The kernel runs the very first program in the init system. Its task is to launch new processes and restart the completed ones. You can see where init is located in your system process hierarchy by entering the pstree command. | + | |
| - | + | ||
| - | The init configuration determines which initialization system will be used. The initialization system is a set of scripts that will be executed when the system starts. | + | |
| - | + | ||
| - | The systemd initialization system is the main VEOS initialization system, which has absorbed the advantages of the classic System V init and more modern launchd (OS X), SMF (Solaris) and Upstart (Ubuntu, Fedora), but at the same time free of many of their disadvantages. It was developed to provide a better expression of dependencies between services, which allows to do more work at the same time at the system boot, and reduce the system boot time. | + | |
| - | + | ||
| - | systemd (system daemon) implements a fundamentally new approach to system initialization and operation control. One of the key innovations of this approach is the high degree of services launch parallelization during system initialization, | + | |
| - | + | ||
| - | ==== Examples of service control commands, a systemd log ==== | + | |
| - | + | ||
| - | The service and chkconfig commands will continue to work in the systemd world with virtually no changes. However, this table shows how to perform the same actions using the built-in systemctl utilities. | + | |
| - | + | ||
| - | ^ Sysvinit commands ^ Systemd commands ^ Notes ^ | + | |
| - | | service fastdpi start | systemctl start fastdpi.service | Used to start the service (does not restart the constant ones) | | + | |
| - | | service fastdpi stop |systemctl stop fastdpi.service | Used to stop the service (does not restart the constant ones)| | + | |
| - | | service fastdpi restart | systemctl restart fastdpi.service | Used to stop and then start the service | | + | |
| - | | service fastdpi reload | systemctl reload fastdpi.service | If supported, reloads configuration files without interrupting unfinished operations | | + | |
| - | | service fastdpi condrestart | systemctl condrestart fastdpi.service | Restarts the service if it is already running | | + | |
| - | | service fastdpi status | systemctl status fastdpi.service | Notifies whether the service is already running | | + | |
| - | | ls /etc/ | + | |
| - | | chkconfig fastdpi on | systemctl enable fastdpi.service | Enables the service during the next reboot, or any other trigger | | + | |
| - | | chkconfig fastdpi off | systemctl disable fastdpi.service | Shuts down the service during the next reboot, or any other trigger | | + | |
| - | | chkconfig fastdpi | systemctl is-enabled fastdpi.service | Used to check whether the service is configured to run in the current environment | | + | |
| - | | chkconfig --list | systemctl list-unit-files --type=service(preferred) | Outputs a table of services. It shows at which loading levels they (don' | + | |
| - | | chkconfig fastdpi --list | ls / | + | |
| - | | chkconfig fastdpi --add | systemctl daemon-reload | Used when you create a new service or modify any configuration | | + | |
| - | + | ||
| - | ==== The systemd log ==== | + | |
| - | + | ||
| - | Systemd includes the ability to maintain a system log. To read the log, use the journalctl command. By default, the syslog service no longer needs to be started. You can run journalctl with different keys: | + | |
| - | > journalctl -b — will show messages only from the current download; | + | |
| - | > journalctl -f — will show only the latest messages. | + | |
| - | + | ||
| - | You can also view the messages of a certain process: | + | |
| - | | + | |
| - | + | ||
| - | To get acquainted with other features, read the journalctl manual. To do this, use the man journalctl command. | + | |