Transferring applications when reinstalling the system

Added by Elena FRISON 24 days ago

Calculate Linux can be updated in two ways: either from an ISO image or in a per package mode. Both methods have their pros and cons. The software is actually updated in a matter of minutes when from an ISO, but the preinstalled software is not transferred once the update procedure has been completed. The per package update takes much more time, the advantage being the automatic transferral of software. Nevertheless, it is the first, ISO-based option that is considered to be the safest way, as your previous system, that you know to run correctly, remains on a separate disk partition.

For over 12 years in our company, the desktops of Calculate personnel have been updated from an ISO. Installing software on the computers of programmers was easy, and other PCs use only basic software. But as we had to install additional software on several computers, we decided to add support for transferring installed applications, in order to avoid system overload and extra compilation.

The main thing that had to be considered was to make sure that temporary installations and flag and mask modifications would be ignored, i.e. to transfer “committed” changes only. To do this, we added a zz-autounmask file in directories /etc/portage/package.keywords/, /etc/portage/package.mask/, /etc/portage/package.unmask/ and /etc/portage/package.use/. Portage creates a file with this same name when trying to fix the dependencies, if there is an empty directory. It will therefore retain this file, as it is necessarily the latest alphabetically. For instance, ‘custom’ is replaced with ‘custom.cld’, where cld refers to the Calculate flavour. This file will be transferred to the new system. Using the .cld extension prevents software migration if you want, for example, to install another Calculate system on the second partition, say a server one. The portable 'custom.cld' file will also be used in the /etc/portage/sets/ sets and in the /etc/portage/make.conf/ global settings.

Starting from version 3.6.3, the "-K [ON / OFF], --update-pkg [ON / OFF]" option has been added in the cl-install installer, resulting in an update script to be generated on the installed system and to run during the first start, once the network is up and the software updated. Since custom.cld is saved in the pre-installed set list, all packages that were previously used will be installed as well as the updated packages. The installation log will be sent to tty12.

Note that we have been increasingly using the 'custom' set lately. It allows to select from all pre-installed packages those that are necessary for the operation of a particular computer. Now this list will be transferred along with the rest of the basic system settings, such as network settings, user accounts, etc.

The next update revision will rename the 'custom' set to 'custom.cld', and the 'custom' mask and flag to 'zz-autounmask'. It will also create empty 'custom.cld' files.

install.jpg (40.9 KB)


Thank you!