“sudo apt-get -f install” não funciona e está causando muitos problemas!

1

Recentemente, consertei meu driver sem fio para meu laptop que está executando o 14.04 LTS, mas agora a conexão continua caindo. Então eu olhei em volta e descobri que você poderia tentar atualizar seu kernel, o que eu tentei fazer. Quando apareceu no centro de software, disse que as dependências não foram atendidas ou algo assim.

Então, decidi usar o atualizador de software para ver se isso resolveria o problema. É aí que tudo deu errado. Quando fui ao centro de software, disse algo sobre a reparação por causa de alguns problemas. Eu cliquei em reparo e isso me deu um erro. Depois disso, o Firefox não estava abrindo. E tentar baixar outro navegador também não funcionava desde que o centro de software tinha, mais um problema ... Eu cliquei na pequena coisa vermelha e ele disse para rodar "sudo apt-get -f install"

Quando eu executo o comando que recebo,

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:
  account-plugin-windows-live libupstart1
Use 'apt-get autoremove' to remove them.
The following extra packages will be installed:
  unity
The following packages will be upgraded:
  unity
1 upgraded, 0 newly installed, 0 to remove and 10 not upgraded.
Need to get 0 B/1,510 kB of archives.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] y
(Reading database ... 200381 files and directories currently installed.)
Preparing to unpack .../unity_7.2.5+14.04.20150521.1-0ubuntu1_amd64.deb ...
Unpacking unity (7.2.5+14.04.20150521.1-0ubuntu1) over (7.2.4+14.04.20141217-0ubuntu1) ...
dpkg-deb (subprocess): cannot copy archive member from '/var/cache/apt/archives/unity_7.2.5+14.04.20150521.1-0ubuntu1_amd64.deb' to decompressor pipe: failed to read (Input/output error)
dpkg-deb (subprocess): decompressing archive member: lzma error: unexpected end of input
dpkg-deb: error: subprocess <decompress> returned error exit status 2
dpkg: error processing archive /var/cache/apt/archives/unity_7.2.5+14.04.20150521.1-0ubuntu1_amd64.deb (--unpack):
 cannot copy extracted data for './usr/lib/compiz/libunityshell.so' to '/usr/lib/compiz/libunityshell.so.dpkg-new': unexpected end of file or stream
E: Sub-process /usr/bin/dpkg returned an error code (1)
kong@kong-Satellite-C75D-B:~$ sudo apt-get check
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:
 unity : Depends: libunity-core-6.0-9 (= 7.2.4+14.04.20141217-0ubuntu1) but 7.2.5+14.04.20150521.1-0ubuntu1 is installed
E: Unmet dependencies. Try using -f.
kong@kong-Satellite-C75D-B:~$ -f
-f: command not found
kong@kong-Satellite-C75D-B:~$ 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?
kong@kong-Satellite-C75D-B:~$ 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:
  account-plugin-windows-live libupstart1
Use 'apt-get autoremove' to remove them.
The following extra packages will be installed:
  unity
The following packages will be upgraded:
  unity
1 upgraded, 0 newly installed, 0 to remove and 10 not upgraded.
Need to get 0 B/1,510 kB of archives.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] y
(Reading database ... 200381 files and directories currently installed.)
Preparing to unpack .../unity_7.2.5+14.04.20150521.1-0ubuntu1_amd64.deb ...
Unpacking unity (7.2.5+14.04.20150521.1-0ubuntu1) over (7.2.4+14.04.20141217-0ubuntu1) ...
dpkg-deb (subprocess): cannot copy archive member from '/var/cache/apt/archives/unity_7.2.5+14.04.20150521.1-0ubuntu1_amd64.deb' to decompressor pipe: failed to read (Input/output error)
dpkg-deb (subprocess): decompressing archive member: lzma error: unexpected end of input
dpkg-deb: error: subprocess <decompress> returned error exit status 2
dpkg: error processing archive /var/cache/apt/archives/unity_7.2.5+14.04.20150521.1-0ubuntu1_amd64.deb (--unpack):
 cannot copy extracted data for './usr/lib/compiz/libunityshell.so' to '/usr/lib/compiz/libunityshell.so.dpkg-new': unexpected end of file or stream
Errors were encountered while processing:
 /var/cache/apt/archives/unity_7.2.5+14.04.20150521.1-0ubuntu1_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

Alguém sabe o que devo fazer? E devo apenas instalar uma versão diferente do ubuntu, pois parece que esta está cheia de problemas para o meu PC.

    
por Kong Chang 01.06.2015 / 20:44

2 respostas

0

Eu olhei em volta e descobri que precisava excluir o pacote anterior. Quando eu corri de novo, funcionou perfeitamente.

    
por Kong Chang 05.06.2015 / 00:35
1

Teste isso:

Ligue o seu computador.

Pressione e mantenha pressionada a tecla Shift, que exibirá o Grub menu .

Selecione a linha que começa com Advanced options .

Selecione a linha que termina com recovery mode

O seu PC deve exibir um menu com várias opções.

Selecione nesta ordem: Network - Drop to root shell prompt .

Na execução do terminal:

    mount -o remount,rw /
    mount --all
    rm /var/cache/apt/archives/*.deb
    apt-get update
    apt-get remove --purge libunity-core-6.0-9
    apt-get install --reinstall unity 
    apt-get dist-upgrade
    apt-get -f install
    reboot

Fonte

    
por kyodake 02.06.2015 / 00:31