使用 sudo do-release-upgrade 升级 Ubuntu 失败,缺少 pam.d

使用 sudo do-release-upgrade 升级 Ubuntu 失败,缺少 pam.d

将 ubuntu 从 20.04.6 升级到 22.04.3

我得到输出:

Checking for a new Ubuntu release
Get:1 Upgrade tool signature [819 B]                                           
Get:2 Upgrade tool [1,260 kB]                                                  
Fetched 1,261 kB in 0s (0 B/s)                                                 
authenticate 'jammy.tar.gz' against 'jammy.tar.gz.gpg' 
extracting 'jammy.tar.gz'

Reading cache

Checking package manager
Reading package lists... Done
Building dependency tree        
Reading state information... Done
Hit http://hk.archive.ubuntu.com/ubuntu focal InRelease                        
Hit http://hk.archive.ubuntu.com/ubuntu focal-updates InRelease                
Hit http://hk.archive.ubuntu.com/ubuntu focal-backports InRelease              
Hit https://dl.google.com/linux/chrome/deb stable InRelease                    
Hit http://security.ubuntu.com/ubuntu focal-security InRelease                 
Fetched 0 B in 0s (0 B/s)                                                      
Reading package lists... Done    
Building dependency tree          
Reading state information... Done

Traceback (most recent call last):
  File "/tmp/ubuntu-release-upgrader-bq_2blh0/jammy", line 8, in <module>
    sys.exit(main())
  File "/tmp/ubuntu-release-upgrader-bq_2blh0/DistUpgrade/DistUpgradeMain.py", line 241, in main
    if app.run():
  File "/tmp/ubuntu-release-upgrader-bq_2blh0/DistUpgrade/DistUpgradeController.py", line 2042, in run
    return self.fullUpgrade()
  File "/tmp/ubuntu-release-upgrader-bq_2blh0/DistUpgrade/DistUpgradeController.py", line 1873, in fullUpgrade
    if not self.doPostInitialUpdate():
  File "/tmp/ubuntu-release-upgrader-bq_2blh0/DistUpgrade/DistUpgradeController.py", line 906, in doPostInitialUpdate
    self.quirks.run("PostInitialUpdate")
  File "/tmp/ubuntu-release-upgrader-bq_2blh0/DistUpgrade/DistUpgradeQuirks.py", line 99, in run
    func()
  File "/tmp/ubuntu-release-upgrader-bq_2blh0/DistUpgrade/DistUpgradeQuirks.py", line 122, in jammyPostInitialUpdate
    self._test_and_fail_on_pam_tally()
  File "/tmp/ubuntu-release-upgrader-bq_2blh0/DistUpgrade/DistUpgradeQuirks.py", line 394, in _test_and_fail_on_pam_tally
    with open(os.path.join('/etc/pam.d', f)) as f:
FileNotFoundError: [Errno 2] No such file or directory: '/etc/pam.d/pam.d'

相关内容