标准软件更新程序提示软件包系统已损坏。它在安装更新时。
当我这样做时sudo apt-get upgrade
,我得到以下信息:
Setting up linux-image-4.8.0-52-generic (4.8.0-52.55~16.04.1) ...
Running depmod.
update-initramfs: deferring update (hook will be called later)
initrd.img(/boot/initrd.img-4.8.0-52-generic
) points to /boot/initrd.img-4.8.0-52-generic
(/boot/initrd.img-4.8.0-52-generic) -- doing nothing at /var/lib/dpkg/info/linux-image-4.8.0-52-generic.postinst line 491.
vmlinuz(/boot/vmlinuz-4.8.0-52-generic
) points to /boot/vmlinuz-4.8.0-52-generic
(/boot/vmlinuz-4.8.0-52-generic) -- doing nothing at /var/lib/dpkg/info/linux-image-4.8.0-52-generic.postinst line 491.
Examining /etc/kernel/postinst.d.
run-parts: executing /etc/kernel/postinst.d/apt-auto-removal 4.8.0-52-generic /boot/vmlinuz-4.8.0-52-generic
run-parts: executing /etc/kernel/postinst.d/dkms 4.8.0-52-generic /boot/vmlinuz-4.8.0-52-generic
run-parts: executing /etc/kernel/postinst.d/initramfs-tools 4.8.0-52-generic /boot/vmlinuz-4.8.0-52-generic
update-initramfs: Generating /boot/initrd.img-4.8.0-52-generic
W: Possible missing firmware /lib/firmware/i915/kbl_dmc_ver1_01.bin for module i915
run-parts: executing /etc/kernel/postinst.d/pm-utils 4.8.0-52-generic /boot/vmlinuz-4.8.0-52-generic
run-parts: executing /etc/kernel/postinst.d/unattended-upgrades 4.8.0-52-generic /boot/vmlinuz-4.8.0-52-generic
run-parts: executing /etc/kernel/postinst.d/update-notifier 4.8.0-52-generic /boot/vmlinuz-4.8.0-52-generic
run-parts: executing /etc/kernel/postinst.d/zz-update-grub 4.8.0-52-generic /boot/vmlinuz-4.8.0-52-generic
/usr/sbin/grub-mkconfig: 13: /etc/default/grub: intel_idle.max_cstate=1: not found
run-parts: /etc/kernel/postinst.d/zz-update-grub exited with return code 127
Failed to process /etc/kernel/postinst.d at /var/lib/dpkg/info/linux-image-4.8.0-52-generic.postinst line 1052.
dpkg: error processing package linux-image-4.8.0-52-generic (--configure):
subprocess installed post-installation script returned error exit status 2
dpkg: dependency problems prevent configuration of linux-image-extra-4.8.0-52-generic:
linux-image-extra-4.8.0-52-generic depends on linux-image-4.8.0-52-generic; however:
Package linux-image-4.8.0-52-generic is not configured yet.
dpkg: error processing package linux-image-extra-4.8.0-52-generic (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of linux-signed-image-4.8.0-52-generic:
linux-signed-image-4.8.0-52-generic depends on linux-image-4.8.0-52-generic (= 4.8.0-52.55~16.04.1); however:
Package linux-image-4.8.0-52-generic is not configured yet.
dpkg: error processing package linux-signed-image-4.8.0-52-generic (--configure):
dependency problems - leaving unconfigured
No 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.
Errors were encountered while processing:
linux-image-4.8.0-52-generic
linux-image-extra-4.8.0-52-generic
linux-signed-image-4.8.0-52-generic
E: Sub-process /usr/bin/dpkg returned an error code (1)
apt-get -f install
并dpkg --configure -a
产生相同的结果。
我该怎么办?我没有安装 Synaptic,现在无法安装任何东西。
其内容/etc/default/grub
为:
# If you change this file, run 'update-grub' afterwards to update
# /boot/grub/grub.cfg.
# For full documentation of the options in this file, see:
# info -f grub -n 'Simple configuration'
GRUB_DEFAULT=0
GRUB_HIDDEN_TIMEOUT=0
GRUB_HIDDEN_TIMEOUT_QUIET=true
GRUB_TIMEOUT=10
GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian`
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"
GRUB_CMDLINE_LINUX=""
intel_idle.max_cstate=1 acpi_backlight=vendor
# Uncomment to enable BadRAM filtering, modify to suit your needs
# This works with Linux (no patch required) and with any kernel that obtains
# the memory map information from GRUB (GNU Mach, kernel of FreeBSD ...)
#GRUB_BADRAM="0x01234567,0xfefefefe,0x89abcdef,0xefefefef"
# Uncomment to disable graphical terminal (grub-pc only)
#GRUB_TERMINAL=console
# The resolution used on graphical terminal
# note that you can use only modes which your graphic card supports via VBE
# you can see them in real GRUB with the command `vbeinfo'
#GRUB_GFXMODE=640x480
# Uncomment if you don't want GRUB to pass "root=UUID=xxx" parameter to Linux
#GRUB_DISABLE_LINUX_UUID=true
# Uncomment to disable generation of recovery mode menu entries
#GRUB_DISABLE_RECOVERY="true"
# Uncomment to get a beep at grub start
#GRUB_INIT_TUNE="480 440 1"
答案1
的第 13 行有错误/etc/default/grub
。它的内容似乎应该GRUB_CMDLINE_LINUX
在上一行中赋值。以下是正确操作方法:
将第 12 行和第 13 行替换为:
GRUB_CMDLINE_LINUX="intel_idle.max_cstate=1 acpi_backlight=vendor"
使用以下命令完成半安装软件包的安装:
sudo apt install -f
这还将根据步骤 1 中的更改更新 Grub 配置(这就是它首先失败的原因),因此无需
update-grub
再次运行。