Applies to openSUSE Leap 42.2

12 Upgrading the System and System Changes

Abstract

You can upgrade an existing system without completely reinstalling it. There are two types of renewing the system or parts of it: updating individual software packages and upgrading the entire system. Updating individual packages is covered in Chapter 9, Installing or Removing Software and Chapter 11, YaST Online Update. Two ways to upgrade the system are discussed in the following sections— see Section 12.1.3, “Upgrading with YaST” and Section 12.1.4, “Distribution Upgrade with Zypper”.

12.1 Upgrading the System

Important
Important: openSUSE Leap 42.2 is only available as 64-bit version

openSUSE Leap 42.2 is only available as 64-bit version. Upgrading 32-bit installations to 64-bit is not supported. Please follow the instructions in Chapter 1, Installation Quick Start and Chapter 2, Installation with YaST to install openSUSE Leap on your computer or consider switching to openSUSE Tumbleweed.

Software tends to grow from version to version. Therefore, take a look at the available partition space with df before updating. If you suspect you are running short of disk space, secure your data before you update and repartition your system. There is no general rule regarding how much space each partition should have. Space requirements depend on your particular partitioning profile, the software selected, and the version numbers of the system.

12.1.1 Preparations

Before upgrading, copy the old configuration files to a separate medium (such as removable hard disk or USB flash drive) to secure the data. This primarily applies to files stored in /etc as well as some of the directories and files in /var. You may also want to write the user data in /home (the HOME directories) to a backup medium. Back up this data as root. Only root has read permission for all local files.

Before starting your update, make note of the root partition. The command df / lists the device name of the root partition. In Example 12.1, “List with df -h, the root partition to write down is /dev/sda3 (mounted as /).

Example 12.1: List with df -h
Filesystem     Size  Used Avail Use% Mounted on
/dev/sda3       74G   22G   53G  29% /
udev           252M  124K  252M   1% /dev
/dev/sda5      116G  5.8G  111G   5% /home
/dev/sda1       39G  1.6G   37G   4% /windows/C
/dev/sda2      4.6G  2.6G  2.1G  57% /windows/D

12.1.2 Possible Problems

If you upgrade a default system from the previous version to this version, YaST works out the necessary changes and performs them. Depending on your customizations, some steps (or the entire upgrade procedure) may fail and you must resort to copying back your backup data. Check the following issues before starting the system update.

12.1.2.1 Checking passwd and group in /etc

Before upgrading the system, make sure that /etc/passwd and /etc/group do not contain any syntax errors. For this purpose, start the verification utilities pwck and grpck as root to eliminate any reported errors.

12.1.2.2 Shut Down Virtual Machines

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

12.1.2.3 PostgreSQL

Before updating PostgreSQL (postgres), dump the databases. See the manual page of pg_dump. This is only necessary if you actually used PostgreSQL prior to your update.

12.1.3 Upgrading with YaST

Following the preparation procedure outlined in Section 12.1.1, “Preparations”, you can now upgrade your system:

  1. Insert the openSUSE Leap DVD into the drive, then reboot the computer to start the installation program. On machines with a traditional BIOS you will see the graphical boot screen shown below. On machines equipped with UEFI, a slightly different boot screen is used. Secure boot on UEFI machines is supported.

    Use F2 to change the language for the installer. A corresponding keyboard layout is chosen automatically. See Section 2.2.1.1, “The Boot Screen on Machines Equipped with Traditional BIOS” or Section 2.2.1.2, “The Boot Screen on Machines Equipped with UEFI” for more information about changing boot options.

  2. Select Upgrade on the boot screen, then press Enter. This boots the system and loads the openSUSE Leap installer. Do not select Installation.

  3. The Language and Keyboard Layout are initialized with the language settings you have chosen on the boot screen. Change them here, if necessary.

    Read the License Agreement. It is presented in the language you have chosen on the boot screen. License Translations are available. Proceed with Next.

  4. YaST determines if there are multiple root partitions. If there is only one, continue with the next step. If there are several, select the right partition and confirm with Next (/dev/sda3 was selected in the example in Section 12.1.1, “Preparations”). YaST reads the old fstab on this partition to analyze and mount the file systems listed there.

    Tip
    Tip: Release Notes

    From this point on, the Release Notes can be viewed from any screen during the installation process by selecting Release Notes.

  5. YaST shows a list of Previously Used Repositories. Enable all the repositories you want to continue using and from where you want to update third-party software. Click the Toggle Status for every list item, if appropriate.

    If you do not select any repositories but simply leave all in state Removed, the default repositories will be enabled in a later step.

  6. If you selected one or more online repositories, you need to configure an internet connection in the Network Settings. If you prefer to install openSUSE Leap with no network connection, choose No to cancel the configuration. However, configuring the network at this stage is recommended, since it will allow to install the latest updates and security fixes from the online repositories. A working network connection will also give you access to additional software repositories.

    To configure the network, choose a network interface from the list and click Edit to change its settings. Use the tabs to configure DNS and routing. Refer to Book “Reference”, Chapter 13 “Basic Networking”, Section 13.4 “Configuring a Network Connection with YaST” for more details.

  7. If you added repositories during the upgrade procedure as recommended earlier, you now can activate those you are actually interested in. Please enable all repositories you had enable before to ensure all packages get upgraded correctly.

    Refer to Section 2.10, “List Of Online Repositories” for more details.

    After having proceeded with Next, you need to confirm the license agreement for the online repositories with Next.

  8. Use the Installation Settings screen to review and—if necessary—change several proposed installation settings. The current configuration is listed for each setting. To change it, click the headline.

    System

    View detailed hardware information by clicking System. In the resulting screen you can also change Kernel Settings—see Section 2.15.5, “System for more information.

    Update Options

    By default, YaST will update perform full Update with Installation of New Software and Features based on a selection of patterns. Each pattern contains several software packages needed for specific functions (for example, Web and LAMP server or a print server).

    Here you can change the package selection or change the Update Mode to Only Update Installed Packages.

    Packages

    You can further tweak the package selection on the Packages screen. Here you can not only select patterns but also list their contents and search for individual packages. See Chapter 9, Installing or Removing Software for more information.

    If you intend to enhance your system, it is recommended to finish the upgrade first and then install additional software.

    Backup

    You also have the possibility to make backups of various system components. Selecting backups slows down the upgrade process. Use this option if you do not have a recent system backup.

    Language

    This section allows you to change the Primary Languageprimary language and configure addtional Secontry Languages.. Optionally, you can adjust the keyboard layout and timezone to the selected primary language.

    Keyboard Layout

    Here you can change the keyboard layout and adjust additional Expert Keyboard Settings.

    Booting

    This section shows the boot loader configuration. Changing the defaults is only recommended if really needed. Refer to Book “Reference”, Chapter 12 “The Boot Loader GRUB 2” for details.

  9. After you have finalized the system configuration on the Installation Settings screen, click Update. Depending on your software selection you may need to agree to license agreements before the installation confirmation screen pops up. Up to this point no changes have been made to your system. After you click Update a second time, the upgrade process starts.

Once the basic upgrade installation is finished, YaST reboots the system. Finally, YaST updates the remaining software, if any and displays the release notes, if wanted.

12.1.4 Distribution Upgrade with Zypper

With the zypper command line utility you can upgrade to the next version of the distribution. Most importantly, you can initiate the system upgrade process from within the running system.

This feature is attractive for advanced users who want to run remote upgrades or upgrades on many similarly configured systems.

12.1.4.1 Preparing the Upgrade with Zypper

To avoid unexpected errors during the upgrade process using zypper, minimize risky constellations.

  • Quit as many applications and stop unneeded services as possible and log out all regular users.

  • Disable third party repositories before starting the upgrade, or lower the priority of these repositories to make sure packages from the default system repositories will get preference. Enable them again after the upgrade and edit their version string to match the version number of the distribution of the upgraded now running system.

12.1.4.2 The Upgrade Procedure

Warning
Warning: Check Your System Backup

Before actually starting the upgrade procedure, check that your system backup is up-to-date and restorable. This is especially important because you need to enter many of the following steps manually.

The program zypper supports long and short command names. For example, you can abbreviate zypper install as zypper in. In the following text, the short variants are used.

  1. Run the online update to make sure the software management stack is up-to-date. For more information, see Chapter 11, YaST Online Update.

  2. Configure the repositories you want to use as update sources. Getting this right is crucial. Either use YaST (see Section 9.3, “Managing Software Repositories and Services”) or zypper (see Book “Reference”, Chapter 2 “Managing Software with Command Line Tools”, Section 2.1 “Using Zypper”). The name of the repositories used in the following steps may vary depending on your customizations.

    To view your current repositories enter:

    zypper lr -u
    1. Increase the version number of the system repositories from 13.2 to 42.1 and prefix them with leap/. Add the new repositories with commands such as:

      server=http://download.example.org
      zypper ar $server/distribution/leap/42.1/repo/oss/ Leap-42.1-OSS
      zypper ar $server/update/leap/42.1/oss/ Leap-42.1-Update

      And remove the old repositories:

      zypper rr 13.2-OSS
      zypper rr 13.2-Update

      If necessary, repeat these steps for other repositories to ensure a clean upgrade path for all your packages.

    2. Disable third party repositories or other openSUSE Build Server repositories, because zypper dup is guaranteed to work with the default repositories only (replace repo-alias with the name of the repository you want to disable):

      zypper mr -d repo-alias

      Alternatively, you can lower the priority of these repositories.

      Note
      Note: Handling of Unresolved Dependencies

      zypper dup will remove all packages having unresolved dependencies, but it keeps packages of disabled repositories as long as their dependencies are satisfied.

      zypper dup ensures that all installed packages come from one of the available repositories. It does not consider the version, architecture, or vendor of the installed packages; thus it emulates a fresh installation. Packages that are no longer available in the repositories are considered orphaned. Such packages get uninstalled if their dependencies cannot be satisfied. If they can be satisfied, such packages stay installed.

    3. Once done, check your repository configuration with:

      zypper lr -d
  3. Refresh local metadata and repository contents with zypper ref.

  4. Update Zypper and the package management itself with zypper patch --updatestack-only.

  5. Run the actual distribution upgrade with zypper dup. You are asked to confirm the license of SUSE Linux Enterprise and of some packages—depending on the set of installed packages.

  6. Reboot the system with shutdown -r now.

12.1.5 Updating Individual Packages

Regardless of your overall updated environment, you can always update individual packages. From this point on, however, it is your responsibility to ensure that your system remains consistent.

Use the YaST software management tool to update packages as described in Chapter 9, Installing or Removing Software. Select components from the YaST package selection list according to your needs. If a newer version of a package exists, the version numbers of the installed and the available versions are listed in blue color in the Installed (Available) column. If you select a package essential for the overall operation of the system, YaST issues a warning. Such packages should be updated only in the update mode. For example, many packages contain shared libraries. Updating these programs and applications in the running system may lead to system instability.

12.2 For More Information

Problems and special issues of the various versions are published online as they are identified. See the links listed below. Important updates of individual packages can be accessed using the YaST Online Update. For more information, see Chapter 11, YaST Online Update.

Refer to the Product highlights (http://en.opensuse.org/Product_highlights and the Bugs article in the openSUSE wiki at http://en.opensuse.org/openSUSE:Most_annoying_bugs for information about recent changes and issues.

Print this page