On 2013-11-30 13:56, wolfi323 wrote:
>
> robin_listas;2603824 Wrote:
>> Careful, because you have to disable all the other repos, like packman.
>> As it is, it can be dangerous.
>>
> Correct, and that’s exactly the main problem.
> How should any automatic distribution upgrade tool know, which of the
> 1000s of repos are safe and which are not.
Removing all of them, then adding the four that are needed
> I merely wanted to demontrate that it is not hard and painful to do the
> actual upgrade.
Right.
> A safer version of the script:
>
> Code:
> --------------------
> #!/bin/bash
> zypper mr -da
> zypper ar http://download.opensuse.org/distribution/13.1/repo/oss/ repo-oss
> zypper ar http://download.opensuse.org/distribution/13.1/repo/non-oss/ repo-non-oss
> zypper ar http://download.opensuse.org/update/13.1/ repo-update
> zypper ar http://download.opensuse.org/update/13.1-non-oss/ repo-update-non-oss
> zypper dup
>
> --------------------
>
> This diables all repos and adds the 4 standard ones for the new
> version.
That’s right.
> Now change that to take the new version as parameter and you have a
> minimal universal upgrade script…
You would have to consider that some versions back, there was only one
update repo. It may be possible that some future version adds or remove
something else. So you would have to do a long “case” and do the
specific changes for each release.
Also you would need the user to read and accept the release notes of
each release, because each time you have to do something different,
something else.
Also, there is the recommendation to update the zypper stack first,
separately. Another one is to ensure you are in runlevel 3, or
alternatively using tmux (and what to do if X crashes and not recover,
how to attach again in text mode to the tmux session)
Another recommendation is to download everything in advance, which also
has to ensure you have the required disk space. If there is not, then
you can not download in advance, but as needed, which is more dangerous
(network stack could crash).
Not rocket science, but if you say that you can do the upgrade
automatically, you really need to consider everything. >:-))
–
Cheers / Saludos,
Carlos E. R.
(from 12.3 x86_64 “Dartmouth” at Telcontar)