/boot/initrd.img-3.16.0-4-amd64 エラーを生成する initramfs を更新できません。

/boot/initrd.img-3.16.0-4-amd64 エラーを生成する initramfs を更新できません。

こんにちは、今日私はDebianをアップグレードしました。実際に問題があります。この問題の解決策を探していましたが、何も見つかりませんでした。ここでエラーが発生しました。

Configurando linux-image-3.16.0-4-amd64 (3.16.7-ckt20-1+deb8u4) ...
/etc/kernel/postinst.d/initramfs-tools:
update-initramfs: Generating /boot/initrd.img-3.16.0-4-amd64
cp: no se puede efectuar `stat' sobre «/etc/udev/udev.conf»: No existe el fichero o el directorio
E: /usr/share/initramfs-tools/hooks/udev failed with return 1.
update-initramfs: failed for /boot/initrd.img-3.16.0-4-amd64 with 1.
run-parts: /etc/kernel/postinst.d/initramfs-tools exited with return code 1
Failed to process /etc/kernel/postinst.d at /var/lib/dpkg/info/linux-image-3.16.0-4-amd64.postinst line 634.
dpkg: error al procesar el paquete linux-image-3.16.0-4-amd64 (--configure):
 el subproceso instalado el script post-installation devolvió el código de salida de error 1
Se encontraron errores al procesar:
 linux-image-3.16.0-4-amd64
E: Sub-process /usr/bin/dpkg returned an error code (1)

COMANDに関する新しい質問:

sudo apt-get -o Dpkg::Options::="--force-confmiss" install --reinstall udev

これを持って:

E: Sub-process /usr/bin/dpkg returned an error code (1)
Failed to perform requested operation on package.  Trying to recover:
Configurando udev (215-17+deb8u3) ...
update-initramfs: deferring update (trigger activated)
insserv: fopen(/etc/insserv.conf): No such file or directory
insserv: Service mountkernfs has to be enabled to start service udev
insserv: exiting now!
update-rc.d: error: insserv rejected the script header
dpkg: error al procesar el paquete udev (--configure):
 el subproceso instalado el script post-installation devolvió el código de salida de error 1
Procesando disparadores para initramfs-tools (0.120) ...
update-initramfs: Generating /boot/initrd.img-3.16.0-4-amd64
Se encontraron errores al procesar:
 udev

ベストアンサー1

デフォルト値を復元してみることができますudev.conf。後ろに

mv /etc/udev/udev.conf /etc/udev/udev.conf.broken

(ファイルが存在するがどこにも指しているシンボリックリンクなどの他の理由で読み取れない場合)

apt-get -o Dpkg::Options::="--force-confmiss" install --reinstall udev

(明らかに、一部のパッケージではUCF_FORCE_CONFFMISS = 1プレフィックスを付ける必要がありますが、udevパッケージはucfを使用していないようです)。


ただし、これが1つ以上のファイルに影響を与える事故の場合は、保持したいすべてのアイテムをバックアップしてから、オペレーティングシステム全体を再インストールする方が良いでしょう。

その原因が何であるかは不明です。私は明らかなことを考えることはできません。一度に1つのファイルを回復しようとすると、後で原因がわからないほど破損したいくつかのファイルを見逃す可能性があります。

残念ながら、実行中のシステムにすべてのパッケージを再インストールする簡単な方法はありません。たとえばaptitude reinstall ?installed、次の場合は失敗しますCouldn't configure perl-base, probably a dependency cycle

おすすめ記事