Tentando atualizar o kernel, espaço insuficiente, o sudo apt-get -f instala falhando também

0

Eu pesquisei on-line e segui as sugestões no Terminal, mas nenhuma delas funcionou para mim. Abaixo está o problema que estou tendo. Parece que o código para limpar kernels antigos está quebrado, mas para consertá-lo eu preciso ter mais espaço, o que é todo o meu propósito para começar. Eu sou muito novo no Linux e não sou um programador, então, por favor, seja claro comigo.

$ sudo apt autoremove
Reading package lists... Done
Building dependency tree
Reading state information... Done
You might want to run 'apt-get -f install' to correct these.
The following packages have unmet dependencies:
    linux-image-extra-4.13.0-36-generic : Depends: linux-image-4.13.0-36-generic but it is not installed
    linux-image-generic-hwe-16.04 : Depends: linux-image-4.13.0-36-generic but it is not installed
    linux-signed-image-4.13.0-36-generic : Depends: linux-image-4.13.0-36-generic (= 4.13.0-36.40~16.04.1) but it is not installed
E: Unmet dependencies. Try using -f.
hunter@hunter-Satellite-C55-C:~$ apt-get -f install
E: Could not open lock file /var/lib/dpkg/lock - open (13: Permission denied)
E: Unable to lock the administration directory (/var/lib/dpkg/), are you root?

$ sudo apt-get -f install
Reading package lists... Done
Building dependency tree
Reading state information... Done
Correcting dependencies... Done
The following packages were automatically installed and are no longer required:
    libllvm4.0 linux-headers-4.10.0-35 linux-headers-4.10.0-35-generic
    linux-headers-4.10.0-37 linux-headers-4.10.0-37-generic
    linux-headers-4.10.0-40 linux-headers-4.10.0-40-generic
    linux-headers-4.10.0-42 linux-headers-4.10.0-42-generic
    linux-headers-4.13.0-26 linux-headers-4.13.0-26-generic
    linux-image-4.10.0-35-generic linux-image-4.10.0-37-generic
    linux-image-4.10.0-40-generic linux-image-4.10.0-42-generic
    linux-image-4.13.0-26-generic linux-image-extra-4.10.0-35-generic
    linux-image-extra-4.10.0-37-generic linux-image-extra-4.10.0-40-generic
    linux-image-extra-4.10.0-42-generic linux-image-extra-4.13.0-26-generic
    linux-signed-image-4.10.0-35-generic linux-signed-image-4.10.0-37-generic
    linux-signed-image-4.10.0-40-generic linux-signed-image-4.10.0-42-generic
    linux-signed-image-4.13.0-26-generic
Use 'sudo apt autoremove' to remove them.
The following additional packages will be installed:
    linux-image-4.13.0-36-generic
Suggested packages:
    fdutils linux-tools
The following NEW packages will be installed:
    linux-image-4.13.0-36-generic
0 upgraded, 1 newly installed, 0 to remove and 110 not upgraded.
78 not fully installed or removed.
Need to get 0 B/21.0 MB of archives.
After this operation, 72.6 MB of additional disk space will be used.
Do you want to continue? [Y/n] y
(Reading database ... 452182 files and directories currently installed.)
Preparing to unpack .../linux-image-4.13.0-36-generic_4.13.0-36.40~16.04.1_amd64.deb ...
Examining /etc/kernel/preinst.d/
run-parts: executing /etc/kernel/preinst.d/intel-microcode 4.13.0-36-generic /boot/vmlinuz-4.13.0-36-generic
Done.
Unpacking linux-image-4.13.0-36-generic (4.13.0-36.40~16.04.1) ...
dpkg: error processing archive /var/cache/apt/archives/linux-image-4.13.0-36-generic_4.13.0-36.40~16.04.1_amd64.deb (--unpack):
    cannot copy extracted data for './boot/System.map-4.13.0-36-generic' to '/boot/System.map-4.13.0-36-generic.dpkg-new': failed to write (No space left on device)
No apport report written because the error message indicates a disk full error
dpkg-deb: error: subprocess paste was killed by signal (Broken pipe)
Examining /etc/kernel/postrm.d .
run-parts: executing /etc/kernel/postrm.d/initramfs-tools 4.13.0-36-generic /boot/vmlinuz-4.13.0-36-generic
run-parts: executing /etc/kernel/postrm.d/zz-update-grub 4.13.0-36-generic /boot/vmlinuz-4.13.0-36-generic
Errors were encountered while processing:
    /var/cache/apt/archives/linux-image-4.13.0-36-  generic_4.13.0-36.40~16.04.1_amd64.deb
        E: Sub-process /usr/bin/dpkg returned an error code (1)
    
por Hunter 04.03.2018 / 17:39

1 resposta

1

Desde que você tenha ficado sem espaço, o apt não será executado; e assim, qualquer correção automatizada também falhará. Você precisa liberar manualmente algum espaço no diretório / boot /. Uma maneira de fazer isso é excluir os mapas do sistema para os kernels que você irá remover. Se isso não der espaço suficiente, exclua o initrd de alguns dos kernels. Nota: você precisará de priveligia de root para remover arquivos em / boot /.

    
por ravery 04.03.2018 / 17:52