Ubuntu從15更新到16.04後,鍵盤配置套件中出現錯誤

Ubuntu從15更新到16.04後,鍵盤配置套件中出現錯誤

所以今天早上我剛開始自動升級我的 Ubuntu 發行版,從 15.xx 到新的 16.04,一切都很順利,除了最後出現一個錯誤:某些東西阻止了鍵盤配置包的完整安裝(沒有)無法獲取錯誤的螢幕截圖)。

它還提到,由於安裝無法完成,因此已恢復。我重新啟動計算機,在登入畫面上我立即看到兩件事:

  1. 它使用預設分辨率,沒有增加分辨率的選項(並且僅檢測到我的兩個螢幕之一),這意味著顯示驅動程式可能無法正常工作。

  2. 它顯示它使用的是16.04發行版,所以看起來它畢竟已經更新了。

然後我進入終端嘗試找出為什麼我的顯示器無法正常工作,在安裝最新的 nvidia 驅動程式時,由於鍵盤配置包,我遇到了一堆錯誤。

我嘗試透過執行以下操作刪除它並重新安裝它:

sudo apt-get rempove keyboard-configuration
sudo apt-get install keyboard-configuration

它不起作用,這是我在安裝過程中遇到的錯誤:

Setting up keyboard-configuration (1.142ubuntu2) ...
/usr/local/bin/setupcon: 806: /usr/local/bin/setupcon: /usr/local/bin/ckbcomp: not found
dpkg: error processing package keyboard-configuration (--configure):
 subprocess installed post-installation script returned error exit status 1

我查看了 ckbcomp 檔案是什麼,它似乎來自控制台安裝程式包,但如果我嘗試安裝此程式包,我會得到與上面相同的錯誤,並帶有一些其他失敗的程式包:

$ sudo apt-get install console-setup
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following packages were automatically installed and are no longer required:
  libxatracker2 libxfont1 libxvmc1 xfonts-base xfonts-encodings xfonts-utils xserver-common
Use 'sudo apt autoremove' to remove them.
The following additional packages will be installed:
  console-setup-linux kbd
The following NEW packages will be installed:
  console-setup console-setup-linux kbd
0 upgraded, 3 newly installed, 0 to remove and 0 not upgraded.
1 not fully installed or removed.
Need to get 0 B/1,316 kB of archives.
After this operation, 2,975 kB of additional disk space will be used.
Do you want to continue? [Y/n] Y
Preconfiguring packages ...
Selecting previously unselected package kbd.
(Reading database ... 412842 files and directories currently installed.)
Preparing to unpack .../kbd_2.0.3-2ubuntu1_amd64.deb ...
Unpacking kbd (2.0.3-2ubuntu1) ...
Selecting previously unselected package console-setup-linux.
Preparing to unpack .../console-setup-linux_1.142ubuntu2_all.deb ...
Unpacking console-setup-linux (1.142ubuntu2) ...
Selecting previously unselected package console-setup.
Preparing to unpack .../console-setup_1.142ubuntu2_all.deb ...
Unpacking console-setup (1.142ubuntu2) ...
Processing triggers for doc-base (0.10.7) ...
Processing 1 added doc-base file...
Registering documents with scrollkeeper...
Processing triggers for man-db (2.7.5-1) ...
Processing triggers for systemd (229-5ubuntu1) ...
Processing triggers for ureadahead (0.100.0-19) ...
ureadahead will be reprofiled on next reboot
Setting up keyboard-configuration (1.142ubuntu2) ...
/usr/local/bin/setupcon: 806: /usr/local/bin/setupcon: /usr/local/bin/ckbcomp: not found
dpkg: error processing package keyboard-configuration (--configure):
 subprocess installed post-installation script returned error exit status 1
dpkg: dependency problems prevent configuration of console-setup:
 console-setup depends on keyboard-configuration (= 1.142ubuntu2); however:
  Package keyboard-configuration is not configured yet.

dpkg: error processing package console-setup (--configure):
 dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of kbd:
 kbd depends on console-setup | console-setup-mini; however:
  Package console-setup is not configured yet.
  Package console-setup-mini is not installed.

dpkg: error processing package kbd (--configure):
 dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of console-setup-linux:
 console-setup-linux depends on kbd (>= 1.15-1ubuntu3); however:
  Package kbd is not configured yet.
 console-setup-linux depends on keyboard-configuration (= 1.142ubuntu2); however:
  Package keyboard-configuration is not configured yet.

dpkg: error processing package console-setup-linux (--configure):
 dependency probNo apport report written because the error message indicates its a followup error from a previous failure.
                 No apport report written because the error message indicates its a followup error from a previous failure.
                  No apport report written because MaxReports is reached already
                                                                                lems - leaving unconfigured
Errors were encountered while processing:
 keyboard-configuration
 console-setup
 kbd
 console-setup-linux
E: Sub-process /usr/bin/dpkg returned an error code (1)

有辦法讓這個工作嗎?尋找任何想法,我對 Linux 不太熟悉,所以它可能源自於我做錯的事情。更新之前系統非常穩定,沒有出現任何問題。

相關內容