Como resolver - erro do dpkg: o antigo script de pré-remoção retornou o status de saída do erro 102

0

Não consigo instalar ou remover um pacote no meu Ubuntu 10.04 devido ao seguinte erro.

$ sudo apt-get autoremove
Password: 
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following packages will be REMOVED:
  busybox
0 upgraded, 0 newly installed, 1 to remove and 9 not upgraded.
1 not fully installed or removed.
Need to get 0B/212kB of archives.
After this operation, 627kB disk space will be freed.
Do you want to continue [Y/n]? y
Selecting previously deselected package nscd.
(Reading database ... 235651 files and directories currently installed.)
Preparing to replace nscd 2.11.1-0ubuntu7.8 (using .../nscd_2.11.1-0ubuntu7.8_amd64.deb) ...
invoke-rc.d: not a symlink: /etc/rc2.d/S76nscd
dpkg: warning: old pre-removal script returned error exit status 102
dpkg - trying script from the new package instead ...
invoke-rc.d: not a symlink: /etc/rc2.d/S76nscd
dpkg: error processing /var/cache/apt/archives/nscd_2.11.1-0ubuntu7.8_amd64.deb (--unpack):
 subprocess new pre-removal script returned error exit status 102
update-rc.d: warning: /etc/rc2.d/S76nscd is not a symbolic link

invoke-rc.d: not a symlink: /etc/rc2.d/S76nscd
dpkg: error while cleaning up:
 subprocess installed post-installation script returned error exit status 102
Errors were encountered while processing:
 /var/cache/apt/archives/nscd_2.11.1-0ubuntu7.8_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

O que devo fazer para resolver esse erro?

Eu tentei

sudo dpkg --remove --force-remove-reinstreq nscd

mas não funcionou.

    
por SPV 11.06.2012 / 12:18

1 resposta

2

Substitua o arquivo /etc/rc2.d/S76nscd por um link simbólico apontando para /etc/init.d/nscd .

    
por Florian Diesch 11.06.2012 / 12:58