
Hi Jan, looks, like you had some fun! Am Samstag, 13. März 2021, 10:31:03 CET schrieb Jan Engelhardt:
Have a good start:
first» cat /etc/os-release NAME="openSUSE Tumbleweed" # VERSION="20181015" ID="opensuse-tumbleweed" ID_LIKE="opensuse suse" VERSION_ID="20181015"
first» zypper dup --download-only
glibc is zstd-compressed, but the newer rpm that can understand the format requires a newer glibc... it all needs to be unpacked with a second machine to break the cycle.
second» sshfs root@first:/ mnt second» cd mnt/var/cache/zypp/packages/base/i586 second» rpm2cpio -diu glibc-2.33-4.1.i586.rpm second» rpm2cpio -diu rpm-4.16.0-4.1.i586.rpm
Then, "%__db_backend bdb" needs to be replaced with ndb. The newer rpm is prone to truncate the entire rpm database if it has to do any writes and that value is still on bdb. (Found out the hard way, but luckily I had /var/adm/backup/rpmdb)
first» vi /usr/lib/rpm/macros <<Replace %__db_backend bdb with %__db_backend ndb>>
first» cd /var/cache/zypp/packages/base/i586 first» ./lib/ld-linux.so.2 --library-path $PWD/lib:$PWD/usr/lib \ ./usr/bin/rpmdb --rebuilddb
Using the unmanaged rpm, install the managed rpm & glibc (and possibly zypper too).
first» ./lib/ld-linux.so.2 --library-path $PWD/lib:$PWD/usr/lib \ ./bin/rpm -Uhv glibc-2.33-4.1.i586.rpm \ glibc-locale-base-2.33-4.1.i586.rpm glibc-locale-2.33-4.1.i586.rpm \ rpm-4.16.0-4.1.i586.rpm
(may need to add a few more, like liblua5_4, libselinux1, libsolv-tools, libzypp, zypper, ..)
Once done, both rpm and glibc are new and it's back to standard business:
first» zypper dup The following product is going to be upgraded: openSUSE Tumbleweed 20181015-0 -> 20210311-0
first» rm -rf /var/cache/zypp/packages
Beware, Linda will propose to you! Wouldn't it make some sense to supply some transition repo, where just the essential packages are available for older distributions, or even statically linked? Guess, this can reduce the amount of manual work to: add transition repo upgrade disable transition repo Cheers, Pete