среда, 5 октября 2016 г.

Быстрофикс: E: Sub-process /usr/bin/dpkg returned an error code (1)

Бывают такие дни, когда важнее побыстрее избавиться от проблемы, а не разбираться и думать почему так получилось. Для таких дней эта заметка =)

И так, если вдруг все плохо:
$ sudo apt-get install SOMETHING
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:
 kde-telepathy-minimal : Depends: kde-config-telepathy-accounts (>= 15.04.0) but it is not going to be installed
E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).
И даже предложенный способ фейлится:
$ 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:
  linux-image-4.2.0-41-generic linux-image-extra-4.2.0-41-generic
Use 'apt-get autoremove' to remove them.
The following extra packages will be installed:
  kde-config-telepathy-accounts
The following NEW packages will be installed:
  kde-config-telepathy-accounts
0 upgraded, 1 newly installed, 0 to remove and 4 not upgraded.
2 not fully installed or removed.
Need to get 0 B/138 kB of archives.
After this operation, 828 kB of additional disk space will be used.
Do you want to continue? [Y/n]
(Reading database ... 555580 files and directories currently installed.)
Preparing to unpack .../kde-config-telepathy-accounts_4%3a15.08.2-0ubuntu1_amd64.deb ...
Unpacking kde-config-telepathy-accounts (4:15.08.2-0ubuntu1) ...
dpkg: error processing archive /var/cache/apt/archives/kde-config-telepathy-accounts_4%3a15.08.2-0ubuntu1_amd64.deb (--unpack):
 trying to overwrite '/usr/share/accounts/services/google-im.service', which is also in package account-plugin-google 0.12+15.10.20150723-0ubuntu1
dpkg-deb: error: subprocess paste was killed by signal (Broken pipe)
Errors were encountered while processing:
 /var/cache/apt/archives/kde-config-telepathy-accounts_4%3a15.08.2-0ubuntu1_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
Быстрофикс: 
Идем в 
/var/lib/dpkg/info
и удаляем оттуда все что связано с проблемным пакетом:
$ rm account-plugin-google.* 
Проверяем результат:
$ 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:
  linux-image-4.2.0-41-generic linux-image-extra-4.2.0-41-generic
Use 'apt-get autoremove' to remove them.
The following extra packages will be installed:
  kde-config-telepathy-accounts
The following NEW packages will be installed:
  kde-config-telepathy-accounts
0 upgraded, 1 newly installed, 0 to remove and 4 not upgraded.
2 not fully installed or removed.
Need to get 0 B/138 kB of archives.
After this operation, 828 kB of additional disk space will be used.
Do you want to continue? [Y/n]
dpkg: warning: files list file for package 'account-plugin-google' missing; assuming package has no files currently installed
(Reading database ... 555570 files and directories currently installed.)
Preparing to unpack .../kde-config-telepathy-accounts_4%3a15.08.2-0ubuntu1_amd64.deb ...
Unpacking kde-config-telepathy-accounts (4:15.08.2-0ubuntu1) ...
Setting up kde-config-telepathy-accounts (4:15.08.2-0ubuntu1) ...
Setting up kde-telepathy-minimal (15.04.20ubuntu1) ...
Setting up kde-telepathy (15.04.20ubuntu1) ...
Processing triggers for libc-bin (2.21-0ubuntu4.3) ...
$

Все работает. 
А дальше уже разбор полетов по желанию в свободное время.

Комментариев нет:

Отправить комментарий