Questions about switching system packages to non-default repositories

In the few months since I moved to openSUSE, I’ve been running software from both the official repositories as well as repositories I added manually. I got the hang of that, but today I did something more unusual which I have some confusion about. I decided to upgrade to KDE 4.9.5 on my openSUSE 12.2 machine, by adding a custom repository from openSUSE providing this version. I noticed however in Yast that simply updating packages to that repository wouldn’t do anything. Instead, I had to click a special link saying “Switch system packages to the versions in this repository”. The upgrade was then successful.

Firstly, what’s different between using “All in This List” -> “Update if newer version available” (which didn’t find new versions for the KDE packages) and using “Switch system packages to the versions in this repository” (which worked)? Are system packages under a special regime? If so, what is it exactly and how does that work?

The most important question however is if this will affect what happens when openSUSE 12.3 comes out, and I’ll be using its DVD to upgrade my installation. Since I switched some system packages to another repository, will that cause distro upgrades to risk going wrong and breaking? In my case with KDE: openSUSE 12.2 offers KDE 4.8 in its latest Update repository, and openSUSE 12.3 will have KDE 4.10 that it will upgrade to. But since I upgraded to 4.9 along the way and switched KDE packets to another repository, can that cause the 12.3 installer to no longer put 4.10 in and even leave me with a broken system? Or will it undo my repository change and switch system packages back to the official openSUSE repos (in which case I can manually switch them to the next version of KDE again if needed)?

There is an optional (and enabled by default) policy to group packages by their ‘vendor’. Which is where they are installed from. By default this means that if you add a new repository packages will not be updated from it, even if they are higher versions. This is very handy for managing a lot of different repositories where you may or may not want everything from them.

Update if newer version available will only update packages conforming to the current vendor, so it is safe to use. It is equivalent to zypper up.

‘Switch system packages’ on the other hand essentially changes the vendor to that repository and runs a zypper dup. Though only for that repository. Not the entire system. This is potentially an unsafe operation unless switching all of the packages to the new repository is desired. To use your example, the KDE repository needs to upgrade all of the packages from it. This is to ensure that the new version of KDE works correctly and has all dependencies satisfied. Use zypper dup (or switch to) with caution though it is safe when you need everything from a certain repository.

The most important question however is if this will affect what happens when openSUSE 12.3 comes out, and I’ll be using its DVD to upgrade my installation. Since I switched some system packages to another repository, will that cause distro upgrades to risk going wrong and breaking?

I am not quite sure actually. I have never done anything other than a simple zypper dup to factory, so I have no experience in upgrading a system with lots of third party repositories. I would be interested as well in hearing the opinion of someone experienced on this. I plan on doing a dvd upgrade to 12.3 as well.

Thank you, that explains a lot. I didn’t know about vendors… looking now I can see that the KDE packages belong to another vendor. Though Yast - Install Software doesn’t seem to offer an easy way to change the vendor of packages. Not that I need to on a general basis of course, just curious how it’s done.

But yes, I’m very interested if this risks breaking an upgrade with the 12.3 DVD once it will be out. And if the distro upgrade will reset all KDE packages to the opensuse vendor. If not I’ll have a big problem when it comes to the upgrade.

On 2013-01-11 20:06, MirceaKitsune wrote:
>
> In the few months since I moved to openSUSE, I’ve been running software
> from both the official repositories as well as repositories I added
> manually. I got the hang of that, but today I did something more unusual
> which I have some confusion about. I decided to upgrade to KDE 4.9.5 on
> my openSUSE 12.2 machine, by adding a custom repository from openSUSE
> providing this version. I noticed however in Yast that simply updating
> packages to that repository wouldn’t do anything. Instead, I had to
> click a special link saying “Switch system packages to the versions in
> this repository”. The upgrade was then successful.

This is intentional.

When you say “update if newer” nothing will be updated because all those
packages already installed are from a different repo. YaST does not
change installed packages from one repo to another automatically, and
this is good.

You can select the version tab and go package by package selecting the
exact version you want installed, from that repo or another. Next time
“update if newer” will work with the repo you selected for each package.

Or you can switch all packages displayed to the ones on that repo -
which you may want or not.

You have to use your judgement and do what is appropriate…

> The most important question however is if this will affect what happens
> when openSUSE 12.3 comes out, and I’ll be using its DVD to upgrade my
> installation. Since I switched some system packages to another
> repository, will that cause distro upgrades to risk going wrong and
> breaking?

All your packages will be switched to the version on the DVD. If there
is none in the DVD, possible actions are removal of the package or leave
it alone - this is mentioned in the wiki page for the offline upgrade
(which I wrote) -. If there are conflicts the upgrader asks.

It is possible to activate external repos during the upgrade, but that
is uncharted territory.


Cheers/Saludos
Carlos E. R. (12.1 test at Minas-Anor)

Might look more into switching package versions tomorrow, for learning purposes only. And if the DVD sets them back during an upgrade it’s all good then. Thanks for all the useful info.