Install

This page contains information on how to install additional packages in ALT Workstation system.

Additional software installation
A particular set of software is available when first running ALT Workstation after its installation. The number of preinstalled programs depends either on the set of programs of a particular distribution or on the options chosen by user during the system installation process. If your system does not contain the programs you are interested in, you can install them later from different sources.

Additional software may be located on the installation disk and/or in special software repositories located on the Internet and/or on a local network. Programs placed in these sources have the form of packages prepared for installation.

Using the installation CD
You can use Synaptic Package Manager to install any additional software.

Synaptic Package Manager
Synaptic Package Manager can be found at System → Settings → Synaptic Package Manager (System → Preferences → Other → Package Manager).



To make the search easier, the programs available for installation are divided into groups displayed on the left side of the program window. On the right there is a list of programs with their current status:
 * green label — package is already installed;
 * white label — package is not installed.

To start the installation, double-click the uninstalled package in the right half of the window and click Apply. If necessary, the package manager will ask you to insert the installation disc.

Adding repositories
This information may be useful when installing additional software from external repositories.

Synaptic Package Manager
Synaptic Package Manager can be used to select a repository that is compatible with your distribution. To specify a particular repository, select one of the options in the Settings → Repositories menu and click OK. If in doubt, select the lines containing ftp://ftp.altlinux.org/. You can add any repository to the proposed list by clicking the Create button and entering the required information.



Please note that after selecting and adding repositories, you need to reload information about the packages they contain by running Edit → Reload Package Information. Otherwise, the list of programs available for installation will not be relevant.

The installation process itself from the added repositories is no different from the method described above in the Using the installation CD section.

Advanced package installation
There are many shared resources in modern Linux-based systems: shared libraries that contain standard functions, executables, scripts, standard utilities, etc. These shared resources are being used by several programs. Removing or changing version of one of the system components may cause the other components associated with it or even the entire system to fail. In the context of system administration, this type of problem is referred to as a system integrity violation. The task of the administrator is to ensure that the system has consistent versions of all necessary software components or in other words to ensure the integrity of the system.

To install, uninstall, and update programs, as well as to maintain the integrity of the system in Linux, package managers (such as rpm) were primarily used. For a package manager, software is a set of components called packages. Packages contain a set of executable programs and auxiliary files necessary for correct operation of the software. Package managers make it easy to install programs: they allow you to check the availability of a suitable version of the component required for the installed program at the time of installation. Package managers perform the necessary procedures to register the program in all operating environments of the user: immediately after installation, the program becomes available to the user from the command line and appears, if it was provided, in the application menu of all graphical shells.

Often, components used by different programs are separated into separate packages and are marked so that you need to install package B to work with the desired software provided by package A. In this case, it is said that package A depends on package B or there is a dependency between packages A and B.

Tracking dependencies between packages is an important task for any distribution. Some components of packages can be interchangeable, that is, multiple packages can be found that offer the requested resource.

The task of monitoring the integrity and consistency of the software installed on the system is even more important. Imagine that some programs A and B require the presence of the component C of version 1.0. Version upgrade of package A, which requires the upgrade of component C to a new version (e.g., version 2.0 in which a new access interface is used), leads to a mandatory update of program B.

In practice, package managers have been unable to effectively eliminate system integrity violations and prevent any conflicts when installing or uninstalling programs. This drawback was especially acute for updating systems from a centralized repository in which packages are continuously updated, split into smaller ones, etc. It was this drawback that stimulated the creation of systems for managing software packages and maintaining the integrity of the operating system.

For automation and control of the processes described above, an improved APT (Advanced Packaging Tool) package management system was used. Automation and control are achieved by creating one or more external repositories which store the software packages that are available for installation.

APT has two databases at its disposal: one describing the packages installed on the system and the other describing the external repository. APT monitors the integrity of the system and, in case of contradictions in package dependencies, resolves conflicts and finds ways to correct them by following the information from external repositories.

The APT system consists of several utilities. The most commonly used package management utility is apt-get. It automatically detects dependencies between packages and strictly enforces them in any of the following operations: installing, removing, or updating packages.

Program sources (repositories)
Unlike a simple set of packages, the repositories with which APT works have meta information. This information contains indexes of the packages in the repository and other information about them. Therefore, to get all the information about the repository, it is enough for APT to get its indexes.

APT can be used by any number of repositories simultaneously, forming a single information base about all the packages contained in them. When installing packages, APT only pays attention to the package name, its version, and dependencies. For APT, the location of the package in a particular repository does not matter.

To use several repositories simultaneously, it is necessary to monitor their compatibility with each other, i.e. their package base should reflect one specific stage of development. Sharing repositories from different distributions or mixing a stable repository with an unstable development branch (Sisyphus) can lead to various surprises and difficulties when upgrading packages.

APT interacts with repositories using different access protocols. The most popular are HTTP and FTP.

In order for APT to be able to use a particular repository, the information about it must be placed in the /etc/apt/sources.list file, or in any other .list file (for example, mysources.list) in the /etc/apt/sources.list.d/ directory. Repository descriptions are stored in these files as follows:

where
 * rpm or rpm-src is the repository type (compiled programs or source code),
 * [signature] is an optional string as well as a pointer to the electronic signature of the developers. The presence of this field implies that each package from this repository must be signed with the corresponding electronic signature. Signatures are described in /etc/apt/vendors.list,
 * method is the repository access method: ftp, http, file, rsh, ssh, cdrom, copy,
 * path is the path to the repository in terms of the selected method,
 * database is the relative path to the repository database,
 * name is the name of the repository.

APT has a special utility for adding a repository from a CD to sources.list called apt-cdrom. To add a repository entry from a CD, simply insert the disc into the drive and run. After this, the sources.list will have a record of a mapped drive that looks like this:

After the list of repositories in sources.list is edited, you need to update the information about the available packages in the local APT database. This is done with the  command.

If there is a repository in sources.list whose contents can be changed (for example, a repository being constantly developed or a repository of security updates), then before working with APT, you need to synchronize the local database with the remote server by using the  command. The local database is re-created each time the repository is changed, whether a package in it is added, deleted, or renamed.

When installing a specific package, APT searches for the latest version of this package in all known repositories regardless of how you access them. Thus, if a newer version of the program is found in a repository available on the Internet compared to a CD-ROM, APT will start downloading the corresponding package from the Internet. Therefore, if the Internet connection is not available or is limited by low bandwidth or high cost, you should comment out the lines (by placing the # character at the beginning of the line) related to resources on the Internet in /etc/apt/sources.list.

Package search
If you do not know the exact package name, you can use the apt-cache utility to find it. This utility allows you to search for a package not only by its name, but also by its description.

The  command allows you to find all packages whose names or descriptions contain the specified substring. For example:

Use the  command to learn more about the package found and get a detailed description of it:

Installing/updating a package
Installing a package with APT is done with the command

Please note that, firstly, administrator privileges are required to install packages, and secondly, before installing and updating packages, you must run the update package indexes command:

apt-get allows you to install packages on your system that require other packages not yet installed. In this case, it determines which packages need to be installed. apt-get then installs them using all available repositories.

Installing the stardict-mueller7 package with  command will result in the following dialog with APT:

The command

is also used to update an already installed package or group of packages. In this case, apt-get additionally checks if there is an updated version of the package in the repository in comparison with the one installed on the system.

With APT you can also install a separate rpm package that is not a part of the repositories (for example, received from the Internet). To do this, just run the command

Meanwhile, APT will perform a standard procedure for checking dependencies and conflicts with already installed packages.

Sometimes, package operations without using APT break the integrity of the system and apt-get refuses to perform installation, removal, or upgrade operations. In this case, you must repeat the operation by specifying the  option that causes apt-get to fix broken dependencies or to remove or replace conflicting packages. You should carefully monitor the messages displayed by apt-get when using this option. Any action in this mode must be confirmed by the user.

Removing a package
Please note that administrator privileges are required to remove packages.

Use the  command to remove a package. In order to not violate the integrity of the system, all packages that depend on the removed one will also be removed. If you remove a package that belongs to the basic system components, apt-get will require additional confirmation to prevent a possible accidental error.

When attempting to use apt-get to remove a basic system component, you will be prompted to confirm the operation:

Each situation in which APT issues such a request must be considered separately. There is a very high probability that after executing such a command the system will become inoperable.

Updating all installed packages
To update all installed packages, the following commands must be executed:

The first command will update package indexes. The second one allows you to update only those installed packages for which there are newer versions in the repositories listed in /etc/apt/sources.list.

In case of upgrading the whole distribution, APT will conduct a comparison of the system with the repository, remove obsolete packages, install new versions of the packages presented on the system, keep track of situations with renaming of the packages or changing the dependencies between the old and new versions of programs. Everything that needs to be installed (or removed) in addition to that already presented in the system will be specified in the apt-get report with which APT will precede the update itself.

The  command will update the system, but not the system kernel.

Kernel update
To update the system kernel, run the following command:

If the indexes have not been updated for more than a day, make sure to run  prior to running the   command.

The  command also updates the kernel modules if any of them have been updated in the repository without updating the kernel.

The new kernel will boot only after the system is rebooted.