Bug 265113 - ports-mgmt/pkg: cannot upgrade 'sudo' with new openldap 2.6 (v1.18.3)
Summary: ports-mgmt/pkg: cannot upgrade 'sudo' with new openldap 2.6 (v1.18.3)
Status: New
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: freebsd-pkg (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-07-09 11:48 UTC by Jimmy Olgeni
Modified: 2022-07-13 11:28 UTC (History)
1 user (show)

See Also:
bugzilla: maintainer-feedback? (pkg)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jimmy Olgeni freebsd_committer freebsd_triage 2022-07-09 11:48:14 UTC
I somehow managed to confuse pkg, perhaps with something in my custom poudriere build: when handling the upgrade of openldap 2.4 to 2.6 it tries to install *both* client packages even though it just removed (correctly) the package for 2.4.

Re-running the upgrade gets it through. The problem is that sudo is left in an unusable state (referencing libs from 2.4) and you have to become root in some other way.

Interesting part at the end:

% sudo pkg upg sudo
Updating bsdkit-extra repository catalogue...
bsdkit-extra repository is up to date.
Updating bsdkit repository catalogue...
Fetching meta.conf: 100%    163 B   0.2kB/s    00:01
Fetching packagesite.pkg: 100%  912 KiB 934.3kB/s    00:01
Processing entries: 100%
bsdkit repository update completed. 3745 packages processed.
All repositories are up to date.
The following 2 package(s) will be affected (of 0 checked):

New packages to be INSTALLED:
	openldap26-client: 2.6.2 [bsdkit]

Installed packages to be REINSTALLED:
	sudo-1.9.11p3 [bsdkit] (direct dependency changed: openldap26-client)

Number of packages to be installed: 1
Number of packages to be reinstalled: 1

The process will require 5 MiB more space.
3 MiB to be downloaded.

Proceed with this action? [y/N]: y
[1/2] Fetching sudo-1.9.11p3.pkg: 100%    2 MiB   1.7MB/s    00:01
[2/2] Fetching openldap26-client-2.6.2.pkg: 100%    1 MiB   1.1MB/s    00:01
Checking integrity... done (1 conflicting)
  - openldap26-client-2.6.2 [bsdkit] conflicts with openldap24-client-2.4.59_4 [installed] on /usr/local/bin/ldapadd
Checking integrity... done (0 conflicting)
Conflicts with the existing packages have been found.
One more solver iteration is needed to resolve them.
The following 4 package(s) will be affected (of 0 checked):

New packages to be INSTALLED:
	openldap26-client: 2.6.2 [bsdkit]

Installed packages to be REINSTALLED:
	sudo-1.9.11p3 [bsdkit] (direct dependency changed: openldap26-client)

Number of packages to be installed: 1
Number of packages to be reinstalled: 1

The process will require 5 MiB more space.

Proceed with this action? [y/N]: y
Fetching openldap24-client-2.4.59_4.pkg: 100%    1 MiB   1.0MB/s    00:01
[1/4] Deinstalling openldap24-client-2.4.59_4...
[1/4] Deleting files for openldap24-client-2.4.59_4: 100%
[2/4] Installing openldap26-client-2.6.2...
[2/4] Extracting openldap26-client-2.6.2: 100%
[2/4] Installing openldap24-client-2.4.59_4...
pkg: openldap24-client-2.4.59_4 conflicts with openldap26-client-2.6.2 (installs files into the same place).  Problematic file: /usr/local/bin/ldapadd
Comment 1 Jimmy Olgeni freebsd_committer freebsd_triage 2022-07-09 11:54:11 UTC
Turns out I added LDAP to my sudo, so the default packages are not affected \o/