[Bug 1977493] Re: Upgrade from Ubuntu 21.10 to 22.04 fails - unmet dependencies: libpam-modules

Steve Langasek 1977493 at bugs.launchpad.net
Wed Aug 3 05:13:29 UTC 2022


SRU verification:

$ lxc launch ubuntu:focal lp1977493
Creating lp1977493
Starting lp1977493
$ lxc exec lp1977493 bash
root at lp1977493:~# echo -e "auth\trequired\tpam_tally.so" >> /etc/pam.d/login
root at lp1977493:~# cd /tmp/
root at lp1977493:/tmp# wget -q http://archive.ubuntu.com/ubuntu/dists/jammy-proposed/main/dist-upgrader-all/current/jammy.tar.gz
root at lp1977493:/tmp# tar xf jammy.tar.gz 
root at lp1977493:/tmp# ./jammy
[...]
Reading package lists... Done    
Building dependency tree          
Reading state information... Done

You are using pam_tally or pam_tally2 in your configuration.

The pam_tally and pam_tally2 modules have been removed from PAM. You 
are using one of these modules in your PAM configuration in 
/etc/pam.d. You must remove the uses of these modules before PAM can 
be upgraded; including these modules in your PAM configuration after 
the upgrade will stop users from being able to log into the system. 

Consider the pam_faillock module as a replacement for pam_tally.


Restoring original system state

Aborting
Reading package lists... Done    
Building dependency tree          
Reading state information... Done
=== Command terminated with exit status 1 (Wed Aug  3 04:43:30 2022) ===
[screen is terminating]
root at lp1977493:/tmp# sed -i -e'/pam_tally/d' /etc/pam.d/login
root at lp1977493:/tmp# ./jammy 
[...]

Reading package lists... Done    
Building dependency tree          
Reading state information... Done

Calculating the changes

Calculating the changes

Do you want to start the upgrade?


4 packages are going to be removed. 85 new packages are going to be 
installed. 538 packages are going to be upgraded. 

You have to download a total of 188 M. This download will take about 
37 seconds with a 40Mbit connection and about 5 minutes with a 5Mbit 
connection. 

Fetching and installing the upgrade can take several hours. Once the 
download has finished, the process cannot be canceled. 

 Continue [yN]  Details [d]y
[...]
Searching for obsolete software
Reading state information... Done

Remove obsolete packages?


72 packages are going to be removed. 

 Continue [yN]  Details [d]y
[...]
System upgrade is complete.

Restart required

To finish the upgrade, a restart is required. 
If you select 'y' the system will be restarted. 

Continue [yN] 
[screen is terminating]
root at lp1977493:/tmp# halt -p
$ lxc delete lp1977493
$ lxc launch ubuntu:impish lp1977493
Creating lp1977493
Starting lp1977493
$ lxc exec lp1977493 bash
root at lp1977493:~# echo -e "auth\trequired\tpam_tally.so" >> /etc/pam.d/login
root at lp1977493:~# do-release-upgrade -p
Checking for a new Ubuntu release
Your Ubuntu release is not supported anymore.
For upgrade information, please visit:
http://www.ubuntu.com/releaseendoflife
[...]
Continue [yN] y
[...]
Reading package lists... Done    
Building dependency tree... Done 
Reading state information... Done

You are using pam_tally or pam_tally2 in your configuration.

The pam_tally and pam_tally2 modules have been removed from PAM. You 
are using one of these modules in your PAM configuration in 
/etc/pam.d. You must remove the uses of these modules before PAM can 
be upgraded; including these modules in your PAM configuration after 
the upgrade will stop users from being able to log into the system. 

Consider the pam_faillock module as a replacement for pam_tally.


Restoring original system state

Aborting
Reading package lists... Done    
Building dependency tree... Done 
Reading state information... Done
=== Command terminated with exit status 1 (Wed Aug  3 05:02:28 2022) ===
[screen is terminating]
root at lp1977493:~# sed -i -e'/pam_tally/d' /etc/pam.d/login
root at lp1977493:~# do-release-upgrade -p
hecking for a new Ubuntu release
Your Ubuntu release is not supported anymore.
For upgrade information, please visit:
http://www.ubuntu.com/releaseendoflife
[...]
Continue [yN] y
[...]
Reading package lists... Done    
Building dependency tree... Done 
Reading state information... Done

Calculating the changes

Calculating the changes

Do you want to start the upgrade?


3 packages are going to be removed. 30 new packages are going to be 
installed. 510 packages are going to be upgraded. 

You have to download a total of 183 M. This download will take about 
48 seconds with your connection. 

Installing the upgrade can take several hours. Once the download has 
finished, the process cannot be canceled. 

 Continue [yN]  Details [d]y
[...]
Searching for obsolete software
Reading state information... Done

Remove obsolete packages?


22 packages are going to be removed. 

 Continue [yN]  Details [d]y
[...]
System upgrade is complete.

Restart required

To finish the upgrade, a restart is required. 
If you select 'y' the system will be restarted. 

Continue [yN] 
=== Command detached from window (Wed Aug  3 05:13:00 2022) ===
[screen is terminating]
root at lp1977493:~# halt -p
$ lxc delete lp1977493
$

** Tags removed: verification-needed verification-needed-jammy
** Tags added: verification-done-jammy

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to ubuntu-release-upgrader in
Ubuntu.
https://bugs.launchpad.net/bugs/1977493

Title:
  Upgrade from Ubuntu 21.10 to 22.04 fails - unmet dependencies: libpam-
  modules

Status in Ubuntu on IBM z Systems:
  Triaged
Status in ubuntu-release-upgrader package in Ubuntu:
  Invalid
Status in ubuntu-release-upgrader source package in Jammy:
  Fix Committed

Bug description:
  [Impact]
  Upgrade from Ubuntu 21.10 to 22.4 fails if pam_tally is present in the system's PAM config

  I run do-release-upgrade and I got a message upgrade completed with
  errors. I rebooted the server and it is now in an undefined state
  between 21.10 and 22.04. Not all packages have been installed. I
  attach apt log and output of some commands:

  root at tuxmaker:~# cat /etc/os-release
  PRETTY_NAME="Ubuntu 21.10"
  NAME="Ubuntu"
  VERSION_ID="21.10"
  VERSION="21.10 (Impish Indri)"
  VERSION_CODENAME=impish
  ID=ubuntu
  ID_LIKE=debian
  HOME_URL="https://www.ubuntu.com/"
  SUPPORT_URL="https://help.ubuntu.com/"
  BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/"
  PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"
  UBUNTU_CODENAME=impish

  root at tuxmaker:~# do-release-upgrade
  Checking for a new Ubuntu release
  Please install all available updates for your release before upgrading.

  root at tuxmaker:~# apt dist-upgrade
  Reading package lists... Done
  Building dependency tree... Done
  Reading state information... Done
  You might want to run 'apt --fix-broken install' to correct these.
  The following packages have unmet dependencies:
   libpam-modules : PreDepends: libpam-modules-bin (= 1.3.1-5ubuntu11) but 1.4.0-11ubuntu2 is installed
                    Recommends: update-motd but it is not installed
  E: Unmet dependencies. Try 'apt --fix-broken install' with no packages (or specify a solution).

  root at tuxmaker:~# apt --fix-broken install
  Reading package lists... Done
  Building dependency tree... Done
  Reading state information... Done
  Correcting dependencies... Done
  The following additional packages will be installed:
    libpam-modules
  The following packages will be upgraded:
    libpam-modules
  1 upgraded, 0 newly installed, 0 to remove and 1208 not upgraded.
  4 not fully installed or removed.
  Need to get 0 B/279 kB of archives.
  After this operation, 1,024 B disk space will be freed.
  Do you want to continue? [Y/n] y
  Preconfiguring packages ...
  (Reading database ... 401827 files and directories currently installed.)
  Preparing to unpack .../libpam-modules_1.4.0-11ubuntu2_s390x.deb ...
  dpkg: error processing archive /var/cache/apt/archives/libpam-modules_1.4.0-11ubuntu2_s390x.deb (--unpack):
   new libpam-modules:s390x package pre-installation script subprocess returned error exit status 2
  Errors were encountered while processing:
   /var/cache/apt/archives/libpam-modules_1.4.0-11ubuntu2_s390x.deb
  E: Sub-process /usr/bin/dpkg returned an error code (1)

  Contact Information = ppohl at de.ibm.com

  [Test plan]
  Test 1
  ------ 
  The pre-build.sh script run prior to generation of the upload tarball runs the test suite which includes an added test for this quirk to verify its correct operation.

  Test 2
  ------
  Using the dist-upgrader tarball from http://archive.ubuntu.com/ubuntu/dists/jammy-proposed/main/dist-upgrader-all/current/ on an Ubuntu 20.04 LTS system upgrade to Ubuntu 22.04 LTS. (Using the tarball is necessary because one cannot use 'do-release-upgrade -d and -p' simultaneously.) The tarball should be manually extracted into /tmp/ and the file (or symlink) named 'jammy' should be executed.

  Verify that the upgrade completes successfully with the addition of
  the new quirk, which should have no effect on a default install.

  Test 3
  ------
  On an impish system, run 'do-release-upgrade -p' to use the tarball from -proposed.  Verify that the upgrade completes successfully.

  
  [Where problems could occur]
  The addition of a quirk could prevent some users from upgrading, in which case a further SRU will be necessary.  The new code is run very early in the upgrader and it should not be possible for the new code to leave the system in an inconsistent state mid-upgrade.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu-z-systems/+bug/1977493/+subscriptions




More information about the foundations-bugs mailing list