Jump to contentJump to page navigation: previous page [access key p]/next page [access key n]
documentation.suse.com / SUSE Linux Enterprise Micro – Dokumentation  / Upgrade Guide / Preparing the upgrade
Applies to SUSE Linux Enterprise Micro 5.5

2 Preparing the upgrade

Before you start the upgrade procedure of SLE Micro, you need to perform checks as described in this chapter.

2.1 Identifying the SLE Micro version

If you need to identify the version of an SLE Micro installation, check the content of the file /etc/os-release.

A machine readable XML output is available with zypper:

# zypper --no-remote --no-refresh --xmlout --non-interactive products -i
<?xml version='1.0'?>
<stream>
<product-list>
<product name="SUSE-MicroOS" version="5.1" release="1" epoch="0" arch="x86_64" vendor="SUSE" summary="SUSE Linux Enterprise Micro 5.1" repo="@System" productline="SUSE-MicroOS" registerrelease="" shortname="SUSE Linux Enterprise Micro" flavor="" isbase="true" installed="true"><endoflife time_t="0" text="0"/><registerflavor/><description>SUSE Linux Enterprise Micro 5.1</description></product>
</product-list>
</stream>

2.2 Read the release notes

Find a list of all changes, new features, and known issues in the release notes. You can also find the release notes on the installation media in the docu directory.

The release notes usually only contain the changes between two subsequent releases.

Check the release notes to see whether:

  • your hardware needs special considerations;

  • any used software packages have changed significantly;

  • special precautions are necessary for your installation.

2.3 Registering and deregistering machines

On registration, the system receives repositories from the SUSE Customer Center (see https://scc.suse.com/) or a local registration proxy like SMT. The repository names map to specific URIs in the customer center. To list all available repositories on your system, use zypper as follows:

# zypper repos -u

This gives you a list of all available repositories on your system. Each repository is listed by its alias, name and whether it is enabled and will be refreshed. The option -u also gives you the URI from where it originated.

To register your machine, run the transactional-update as follows:

# transactional-update register -r REGCODE

To deregister your machine, you can use the transactional-update as follows:

# transactional-update register -d

To check your locally installed products and their status, use the following command:

# SUSEConnect -s

2.4 Make sure the current system is up-to-date

Upgrading the system is only supported from the most recent patch level. Make sure the latest system updates are installed by running:

  # transactional-update patch

2.5 Listing installed packages and repositories

You can save a list of installed packages, for example when doing a fresh install of a new major SLE release or reverting to the old version.

Note
Note

Be aware that not all installed packages or used repositories are available in newer releases of SUSE Linux Enterprise. Some may have been renamed and others replaced. It is also possible that some packages are still available for legacy purposes while another package is used by default. Therefore some manual editing of the files might be necessary. This can be done with any text editor.

  1. Create a file named repositories.bak.repo containing a list of all used repositories:

    # zypper lr -e repositories.bak
  2. Also create a file named installed-software.bak containing a list of all installed packages:

    # rpm -qa --queryformat '%{NAME}\n' >
         installed-software.bak
  3. Back up both files. The repositories and installed packages can be restored with the following commands:

    # zypper ar repositories.bak.repo
    # transactional-update pkg install $(cat installed-software.bak)
    Note
    Note: Number of packages increases with an update to a new release

    A system upgraded to a new (minor or major) version may contain more packages than the initial system. It could also contain more packages than a fresh installation of the new SLE Micro with the same pattern selection. Reasons for this are:

    • Packages were split to allow a more fine-grained package selection.

    • When a package has been split, all new packages are installed in the upgrade case to retain the same functionality as with the previous version. However, the new default for a fresh installation of SLE Micro new versions may be to not install all packages.

    • Legacy packages from the initial SLE Micro may be kept for compatibility reasons.

    • Package dependencies and the scope of patterns may have changed.

2.6 Make a backup

Before upgrading, back up your data by copying the existing configuration files to a separate medium (such as tape device, removable hard disk, etc.). This primarily applies to files stored in /etc and some directories and files in /var and /opt. You may also want to write the user data in /home (the HOME directories) to a backup medium.

Back up all data as root. Only root has sufficient permissions for all local files.

2.7 Disk space

Software tends to grow from version to version. Therefore, take a look at the available partition space before updating. If you suspect you are running short of disk space, back up your data before increasing the available space by resizing partitions, for example. There is no general rule regarding how much space each partition should have. Space requirements depend on your particular partitioning profile and the software selected.

2.7.1 Checking disk space on Btrfs root file systems

On a Btrfs file system, the output of df can be misleading, because in addition to the space the raw data allocates, a Btrfs file system also allocates and uses space for metadata.

Consequently a Btrfs file system may report being out of space even though it seems that plenty of space is still available. In that case, all space allocated for the metadata is used up.

Make sure there is enough free space as the root file system uses Btrfs and might consume significant amount of space. Check the available space on all mounted partitions. In the worst case, an upgrade needs as much disk space as the current root file system (without /.snapshot) for a new snapshot.

The following recommendations have been proven:

  • For all file systems, including Btrfs, you need enough free disk space to download and install big RPMs. The space of old RPMs is only freed after new RPMs are installed.

  • For Btrfs with snapshots, you need as a minimum as much free space as your current installation takes. We recommend having twice as much free space as the current installation.

    If you do not have enough free space, you can try to delete old snapshots with snapper:

    # snapper list
    # snapper delete NUMBER

    However, this may not help in all cases. Before migration, most snapshots occupy only little space.

2.8 Shut down virtual machine guests

If your machine serves as a VM Host Server for KVM, make sure to properly shut down all running VM Guests prior to the update. Otherwise you may not be able to access the guests after the update.