SDB:System upgrade

Jump to: navigation, search
This guide shows how to use Zypper or opensuse-migration-tool to perform a live distribution upgrade of openSUSE Leap.

Tested on openSUSE

Recommended articles

Icon-manual.png



Upgrade to Leap 16.0

Generally the upgrade should be simply matter of running zypper --releasever $RELEASE dup # e.g. 16.0 However there might be changes in distribution repositories in between major version updates and users might need to do one or more extra steps.

Major changes

General

Leap 16.0 will no longer run on machines that do not support x86_64-v2. If you don't have a x86_64-v2 capable machine please consider using openSUSE Tumbleweed.

SELinux is the new default for fresh Leap 16.0 installations. Leap 16.0 can be still configured with AppArmor.

Most of YaST stack was removed from SLES 16 and therefore Leap. The good news is that we do have a drop-in replacement for YaST Software installation GUI called Myrlyn. The replacement for most of the other YaST modules is Cockpit.

Distribution repositories

The most notable changes compared to Leap 15 include:

  • Removal of dedicated update repositories (backport, update, SLE)
  • Split repositories per architecture to reduce repodata size and improve refresh speed.

Leap 16.0 uses Repository Index Service-based management by default. The openSUSE-repos package automatically manages repository definitions, relieving users from manually updating them. Repository definitions for Leap 16.0 are available in the openSUSE-repos GitHub project.

This mechanism allows seamless migration between various openSUSE distributions.

Leap 16.0 release notes draft

The release notes for Leap 16.0 is being completely revamped. A draft can be found here.

Automatic upgrade using opensuse-migration-tool (preferred)

As part of Hackweek 24, the opensuse-migration-tool was introduced. This tool supports both standard release upgrades and cross-distribution migrations (e.g. from Leap to SLES or Leap to Slowroll or Tumbleweed).

It utilizes openSUSE:Standards_Repository_Index_Service, repository updates are then deployed as part of openSUSE-repos package update.

It installs the appropriate repository definitions from the target release and then executes zypper dup to perform the upgrade.

 sudo zypper in opensuse-migration-tool # Available since 15.6
 sudo opensuse-migration-tool
 sudo reboot # After a successful migration

Systems using btrfs can use snapper for rollback in case of failed migration.


opensuse-migration-tool
opensuse-migration-tool interface

If you experience any issues with the tool or want to help with development of opensuse-migration-tool check [1].

Advantages of performing the upgrade with opensuse-migration-tool:
  • automated addition of correct distribution repositories
  • automated deactivation of no longer existing and 3rd party repositories (can be rejected by user)
  • possibility to perform the automatic switch from AppArmor to SELinux

Manual upgrade (only for experienced users)

Manual upgrade needs modifications of repositories, which is done automatically when using the opensuse-migration-tool. If you do not perform the following described steps, the upgrade will fail with repository errors.

Note on 3rd-party repositories

3rd-party repositories (e.g. OBS, Packman, VLC, ...) can cause issues during migration.

This is a big problem especially early in a Leap development cycle as 3rd repositories may be unavailable or broken. Some repositories might hardcode Leap version instead of using $RELEASEVER variable, leading to unresolved dependencies in outdated software.

We strongly recommend disabling all non-official repositories before migrating.

 zypper lr -u | egrep -v "/distribution/|/update/" # list the 3rd party repos
 zypper modifyrepo -d <REPO_ID> # to disable individual repositories

Distribution repositories

As described above, Leap 16 no longer utilizes update, backport and SLE repositories. Updates are now deployed via the standard oss and non-oss repositories instead.

Prior upgrade to Leap 16, the no longer existing distribution repositories needs to be disabled or removed. If this step is skipped, the upgrade will likely fail due to non existing repository errors.

This is the old set of repositories for Leap 15.6 (without debug and source):

# | Alias                     | URI
--+---------------------------+-------------------------+----------------------------------
1 | openSUSE:repo-non-oss     | http://cdn.opensuse.org/distribution/leap/15.6/repo/non-oss
2 | openSUSE:repo-oss         | http://cdn.opensuse.org/distribution/leap/15.6/repo/oss
3 | openSUSE:repo-openh264    | http://codecs.opensuse.org/openh264/openSUSE_Leap
4 | openSUSE:update-backports | http://cdn.opensuse.org/update/leap/15.6/backports
5 | openSUSE:update-non-oss   | http://cdn.opensuse.org/update/leap/15.6/non-oss
6 | openSUSE:update-oss       | http://cdn.opensuse.org/update/leap/15.6/oss
7 | openSUSE:update-sle       | http://cdn.opensuse.org/update/leap/15.6/sle

This is the new set of repositories for Leap 16.0 (without debug and source):

# | Alias                     | URI
--+---------------------------+-------------------------+----------------------------------
1 | openSUSE:repo-non-oss     | http://cdn.opensuse.org/distribution/leap/16.0/repo/non-oss
2 | openSUSE:repo-oss         | http://cdn.opensuse.org/distribution/leap/16.0/repo/oss
3 | openSUSE:repo-openh264    | http://codecs.opensuse.org/openh264/openSUSE_Leap

Manual upgrade with zypper dup

After you have adjusted your repositories as described above, run the following commands

 sudo zypper --releasever 16.0 dup
 sudo reboot # After a successful migration

Manual upgrade using openSUSE-repos package

Check this news article for basic information about openSUSE-repos

Alternatively, you can manually install the openSUSE-repos package from Leap 16.0 to update repository definitions. Either get it from https://software.opensuse.org/package/openSUSE-repos-Leap.

As long as definitions did not change you can install openSUSE-repos from target release

 sudo zypper --releasever 16.0 install openSUSE-repos-Leap

You can also get the package with osc

 zypper in osc
 osc getbinaries -d /tmp openSUSE:Leap:16.0 openSUSE-repos:openSUSE-repos-Leap standard x86_64
 sudo zypper in /tmp/openSUSE-repos-Leap*.rpm

Once you have Leap 16.0 repository definitions run

 sudo zypper --releasever 16.0 dup
 sudo reboot # After a successful migration