DPKG: не может обновить из-за синтаксической ошибки в триггерном файле

Я просто пробовал к ugrade/update, и я столкнулся с некоторыми проблемами из-за невстреченных зависимостей:

anonymous@anonymous:~$ sudo apt-get upgrade 
Reading package lists... Done
Building dependency tree       
Reading state information... Done
You might want to run 'apt --fix-broken install' to correct these.
The following packages have unmet dependencies:
 bind9-host : Depends: libbind9-160 (= 1:9.11.3+dfsg-1ubuntu1.1) but 1:9.11.3+dfsg-1ubuntu1 is installed
              Depends: libdns1100 (= 1:9.11.3+dfsg-1ubuntu1.1) but 1:9.11.3+dfsg-1ubuntu1 is installed
              Depends: libisc169 (= 1:9.11.3+dfsg-1ubuntu1.1) but 1:9.11.3+dfsg-1ubuntu1 is installed
              Depends: libisccfg160 (= 1:9.11.3+dfsg-1ubuntu1.1) but 1:9.11.3+dfsg-1ubuntu1 is installed
              Depends: liblwres160 (= 1:9.11.3+dfsg-1ubuntu1.1) but 1:9.11.3+dfsg-1ubuntu1 is installed
 dnsutils : Depends: libbind9-160 (= 1:9.11.3+dfsg-1ubuntu1.1) but 1:9.11.3+dfsg-1ubuntu1 is installed
            Depends: libdns1100 (= 1:9.11.3+dfsg-1ubuntu1.1) but 1:9.11.3+dfsg-1ubuntu1 is installed
            Depends: libisc169 (= 1:9.11.3+dfsg-1ubuntu1.1) but 1:9.11.3+dfsg-1ubuntu1 is installed
            Depends: libisccfg160 (= 1:9.11.3+dfsg-1ubuntu1.1) but 1:9.11.3+dfsg-1ubuntu1 is installed
            Depends: liblwres160 (= 1:9.11.3+dfsg-1ubuntu1.1) but 1:9.11.3+dfsg-1ubuntu1 is installed
E: Unmet dependencies. Try 'apt --fix-broken install' with no packages (or specify a solution).

Так некоторая проблема с bind9 в зависимости от версии 1.1, но у меня есть 1,0 установленных. Таким образом, я пробую поврежденный фиксацией:

anonymous@anonymous:~$ sudo apt-get  --fix-broken 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:

# Набор пакетов больше не требуется

Use 'sudo apt autoremove' to remove them.
The following additional packages will be installed:
  libbind9-160 libdns1100 libirs160 libisc169 libisccc160 libisccfg160 liblwres160
The following packages will be upgraded:
  libbind9-160 libdns1100 libirs160 libisc169 libisccc160 libisccfg160 liblwres160
7 upgraded, 0 newly installed, 0 to remove and 251 not upgraded.
27 not fully installed or removed.
Need to get 0 B/1,349 kB of archives.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] y
dpkg: error: syntax error in file triggers file '/var/lib/dpkg/triggers/File'
E: Sub-process /usr/bin/dpkg returned an error code (2)

Хм.... так не настолько полезный. Если я пробую, автоудаляют, я получаю первое сообщение об ошибке. Вот содержание триггерного файла, упомянутого dpkg:

  GNU nano 2.9.3                 /var/lib/dpkg/triggers/File                           

/.
/etc
/etc/gnome
/etc/gnome/defaults.list
/usr
/usr/bin
/usr/bin/desktop-file-install
/usr/bin/desktop-file-validate
/usr/bin/update-desktop-database
/usr/share
/usr/share/applications
/usr/share/doc
/usr/share/doc/desktop-file-utils
/usr/share/doc/desktop-file-utils/NEWS.gz
/usr/share/doc/desktop-file-utils/README
/usr/share/doc/desktop-file-utils/changelog.Debian.gz
/usr/share/doc/desktop-file-utils/copyright
/usr/share/emacs
/usr/share/emacs/site-lisp
/usr/share/emacs/site-lisp/desktop-entry-mode.el
/usr/share/lintian
/usr/share/lintian/overrides
/usr/share/lintian/overrides/desktop-file-utils
/usr/share/man
/usr/share/man/man1
/usr/share/man/man1/desktop-file-install.1.gz
/usr/share/man/man1/desktop-file-validate.1.gz
/usr/share/man/man1/update-desktop-database.1.gz
/usr/bin/desktop-file-edit
/usr/share/applications/defaults.list
/usr/share/man/man1/desktop-file-edit.1.gz
1
задан 4 August 2018 в 21:59

2 ответа

Одна опция: Я переименовал рассматриваемый триггерный файл (таким образом, это не будет найдено dpkg). Я затем повторно выполнил обновление, автоудалите и т.д.

Это, кажется, работало, в том смысле, что я мог возобновить обновления. Однако я все еще хотел бы знать то, на что мой триггерный файл, как предполагается, похож и как/если я могу восстановить его до некоторой степени...

0
ответ дан 7 December 2019 в 23:57

Проверьте, что у Вас есть все еще строки security.ubuntu.com в Вашем sources.list

deb http://security.ubuntu.com/ubuntu bionic-security main restricted
deb http://security.ubuntu.com/ubuntu bionic-security universe
deb http://security.ubuntu.com/ubuntu bionic-security multiverse

bind9 имеет обновление системы защиты в 1:9.11.3+dfsg-1ubuntu1.1, но только доступный через security.ubuntu.com. Я узнал мой, репозитории были отключены одним сценарием или другим.

0
ответ дан 7 December 2019 в 23:57

Другие вопросы по тегам:

Похожие вопросы: