Comment 14 for bug 2039279

Revision history for this message
Aleksandr (aleksbazer) wrote : Re: [Bug 2039279] Re: file conflict when installing libsgutils-2-1.46-2 when upgrading from lunar to mantic

Thanks brother, but I think it will be difficult for me to do this. There
is still one problem when loading it gives an error. It’s easier for me to
tear it down and reinstall it on my computer.

вт, 21 лист. 2023 р. о 17:37 andy cao <email address hidden> пише:

> #2 can fix this issue,i has been tested,it works.
> thanks bro.
>
> --
> You received this bug notification because you are subscribed to a
> duplicate bug report (2043489).
> https://bugs.launchpad.net/bugs/2039279
>
> Title:
> file conflict when installing libsgutils-2-1.46-2 when upgrading from
> lunar to mantic
>
> Status in sg3-utils package in Ubuntu:
> Fix Released
> Status in sg3-utils source package in Mantic:
> Fix Committed
> Status in sg3-utils source package in Noble:
> Fix Released
>
> Bug description:
> [ Impact ]
>
> A release upgrade from lunar to mantic, or jammy to mantic when lunar
> goes EOL, will encounter a file conflict in the libgsutils2 library.
>
> This is what the library package is named, and the library it ships,
> in each relevant ubuntu release:
>
> Jammy: 1.46-1build1
> package: libsgutils2-2
> ships: libsgutils2-1.46.so.2 and libsgutils2-1.46.so.2.0.0
>
> Lunar: 1.46-1ubuntu0.23.04.1
> package: libsgutils2-2
> ships: libsgutils2-1.46.so.2 and libsgutils2-1.46.so.2.0.0
>
> Mantic and Noble: 1.46-3ubuntu2
> package: libsgutils2-1.46-2
> ships: libsgutils2-1.46.so.2 and libsgutils2-1.46.so.2.0.0
>
> The problem is that in the jammy and lunar versions the file that
> libgsutils2-2 ships conflicts with mantic, where the package was
> renamed to libgsutils2-1.46-2.
>
> This update corrects the version of the existing breaks/replaces in
> the mantic package to avoid this conflict.
>
> Note that, if the upgrade is done with do-release-upgrade, the
> conflict does not cause an abort, because dpkg is called with --force
> (see comment #3 down below).
>
> [ Test Plan ]
>
> Perform a release upgrade from lunar to mantic, with mantic-proposed
> enabled (I'm not yet sure how to have mantic-proposed enabled for do-
> release-upgrade: I'll come back to this once the package is in
> proposed). Check the upgrade logs in /var/log/dist-upgrade/apt-
> term.log and look for the part where libsgutils2 is being unpacked.
>
> For example, this shows the problem:
> Preparing to unpack .../125-libsgutils2-1.46-2_1.46-3ubuntu2_amd64.deb
> ...^M
> Unpacking libsgutils2-1.46-2:amd64 (1.46-3ubuntu2) ...^M
> dpkg: warning: overriding problem because --force enabled:^M
> dpkg: warning: trying to overwrite
> '/usr/lib/x86_64-linux-gnu/libsgutils2-1.46.so.2.0.0', which is also in
> package libsgutils2-2:amd64 1.46-1ubuntu0.23.04.1^M
> dpkg: warning: overriding problem because --force enabled:^M
> dpkg: warning: trying to overwrite
> '/usr/lib/x86_64-linux-gnu/libsgutils2-1.46.so.2', which is also in package
> libsgutils2-2:amd64 1.46-1ubuntu0.23.04.1^M
>
> This grep command can also be used:
> $ grep "trying to overwrite" /var/log/dist-upgrade/apt-term.log
> dpkg: warning: trying to overwrite
> '/usr/lib/x86_64-linux-gnu/libsgutils2-1.46.so.2.0.0', which is also in
> package libsgutils2-2:amd64 1.46-1ubuntu0.23.04.1
> dpkg: warning: trying to overwrite
> '/usr/lib/x86_64-linux-gnu/libsgutils2-1.46.so.2', which is also in package
> libsgutils2-2:amd64 1.46-1ubuntu0.23.04.1
>
> With the fixed version, there will be no such dpkg warning when
> unpacking libsgutils2 (example with a PPA, since the package is not
> yet in proposed, but the file to check, and grep command, are the
> same):
>
> $ grep "trying to overwrite" /var/log/dist-upgrade/apt-term.log
> $ # empty result, no hits
>
> Locating the unpacking section in that log, we see that the
> conflicting package is removed before (took the example from a ppa
> build):
>
> Removing libsgutils2-2:amd64 (1.46-1ubuntu0.23.04.1) ...^M
> Selecting previously unselected package libsgutils2-1.46-2:amd64.^M
> (Reading database ... ^M(Reading database ... 5%^M(Reading database ...
> 10%^M(Reading database ... 15%^M(Reading database ... 20%^M(Reading
> database ... 25%^M(Reading databas
> Preparing to unpack
> .../libsgutils2-1.46-2_1.46-3ubuntu2.1~ppa3_amd64.deb ...^M
> Unpacking libsgutils2-1.46-2:amd64 (1.46-3ubuntu2.1~ppa3) ...^M
>
> [ Where problems could occur ]
> Should this package ever get a version bump in an SRU, then the
> breaks/replaces version might need a bump, which can easily be forgotten.
> Something similar happened to a samba security update[1] a while ago.
> Looking at the history of sg3-utils in SRUs, however, shows that such a
> bump was never done, so it's unlikely. But if it happens, then this bug
> will resurface.
>
> 1. https://bugs.launchpad.net/bugs/2024663
>
> [ Other Info ]
>
> N/A
>
> [Original Description]
>
> While upgrading from lunar to mantic dpkg aborted with this error:
>
> ```
> Preparing to unpack .../libsgutils2-1.46-2_1.46-3ubuntu2_amd64.deb ...
> Unpacking libsgutils2-1.46-2:amd64 (1.46-3ubuntu2) ...
> dpkg: error processing archive
> /var/cache/apt/archives/libsgutils2-1.46-2_1.46-3ubuntu2_amd64.deb
> (--unpack):
> trying to overwrite
> '/usr/lib/x86_64-linux-gnu/libsgutils2-1.46.so.2.0.0', which is also in
> package libsgutils2-2:amd64 1.46-1ubuntu0.22.04.1
> ```
>
> ProblemType: Bug
> DistroRelease: Ubuntu 23.10
> Package: libsgutils2-2 1.46-1ubuntu0.22.04.1
> ProcVersionSignature: Ubuntu 6.2.0-33.33-generic 6.2.16
> Uname: Linux 6.2.0-33-generic x86_64
> NonfreeKernelModules: vboxnetadp vboxnetflt vboxdrv amddrm_ttm_helper
> amdttm amdxcp amddrm_buddy amd_sched amdkcl
> ApportVersion: 2.27.0-0ubuntu5
> Architecture: amd64
> CasperMD5CheckResult: unknown
> CurrentDesktop: GNOME
> Date: Fri Oct 13 15:29:48 2023
> RebootRequiredPkgs: Error: path contained symlinks.
> SourcePackage: sg3-utils
> UpgradeStatus: No upgrade log present (probably fresh install)
> modified.conffile..etc.default.apport: [modified]
> mtime.conffile..etc.default.apport: 2018-06-16T17:39:00.798346
>
> To manage notifications about this bug go to:
>
> https://bugs.launchpad.net/ubuntu/+source/sg3-utils/+bug/2039279/+subscriptions
>
>