I'm trying to install libncurses (and a few other applications), but I run across these errors:
ghost:/# apt-get install libncurses5-dev
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:
libasound2-plugins: Depends: libavcodec53 (>= 6:0.8.2-2) but it is not going to be installed or
libavcodec-extra-53 (>= 6:0.8.2-2) but it is not going to be installed
Depends: libavutil51 (>= 6:0.8.2-2) but it is not going to be installed
Depends: libpulse0 (>= 0.99.1) but 0.9.21-3 is to be installed
libncurses5-dev: Depends: libtinfo-dev (= 5.9-10) but it is not going to be installed
Depends: ncurses-bin (= 5.9-10) but 5.7+20100313-4 is to be installed
mplayer: Depends: libavcodec53 (>= 6:0.8.3-1~) but it is not going to be installed or
libavcodec-extra-53 (>= 6:0.8.17) but it is not going to be installed
Depends: libavformat53 (>= 6:0.8.3-1~) but it is not going to be installed
Depends: libavutil51 (>= 6:0.8.3-1~) but it is not going to be installed
Depends: libdvdnav4 (>= 4.2.0+20120524) but it is not going to be installed
Depends: libpostproc52 (>= 6:0.8.3-1~) but it is not going to be installed
Depends: libpulse0 (>= 0.99.1) but 0.9.21-3 is to be installed
Depends: libswscale2 (>= 6:0.8.3-1~) but it is not going to be installed
E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).
And then:
ghost:/# 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:
libswscale0 libavutil49 libpostproc51 libavformat52 libavcodec52 libaudio2
Use 'apt-get autoremove' to remove them.
The following extra packages will be installed:
libavcodec53 libavformat53 libavutil51 libdvdnav4 libpostproc52 libpulse0 libswscale2
Suggested packages:
libdvdcss2 pulseaudio
The following NEW packages will be installed:
libavcodec53 libavformat53 libavutil51 libdvdnav4 libpostproc52 libswscale2
The following packages will be upgraded:
libpulse0
1 upgraded, 6 newly installed, 0 to remove and 195 not upgraded.
55 not fully installed or removed.
Need to get 0B/6999kB of archives.
After this operation, 24.5MB of additional disk space will be used.
Do you want to continue [Y/n]? y
And then
WARNING: The following packages cannot be authenticated!
libavutil51 libavcodec53 libpulse0 libavformat53 libdvdnav4 libpostproc52 libswscale2
Install these packages without verification [y/N]? y
Can not write log, openpty() failed (/dev/pts not mounted?)
(Reading database ... 19252 files and directories currently installed.)
Unpacking libavutil51 (from .../libavutil51_6%3a0.8.21-0+deb7u1_armel.deb) ...
dpkg-deb: file `/var/cache/apt/archives/libavutil51_6%3a0.8.21-0+deb7u1_armel.deb' contains ununderstood data member data.tar.xz , giving up
dpkg: error processing /var/cache/apt/archives/libavutil51_6%3a0.8.21-0+deb7u1_armel.deb (--unpack):
subprocess dpkg-deb --fsys-tarfile returned error exit status 2
Unpacking libavcodec53 (from .../libavcodec53_6%3a0.8.21-0+deb7u1_armel.deb) ...
dpkg-deb: file `/var/cache/apt/archives/libavcodec53_6%3a0.8.21-0+deb7u1_armel.deb' contains ununderstood data member data.tar.xz , giving up
dpkg: error processing /var/cache/apt/archives/libavcodec53_6%3a0.8.21-0+deb7u1_armel.deb (--unpack):
subprocess dpkg-deb --fsys-tarfile returned error exit status 2
Preparing to replace libpulse0 0.9.21-3 (using .../libpulse0_2.0-6.1_armel.deb) ...
Unpacking replacement libpulse0 ...
dpkg-deb: file `/var/cache/apt/archives/libpulse0_2.0-6.1_armel.deb' contains ununderstood data member data.tar.xz , giving up
dpkg: error processing /var/cache/apt/archives/libpulse0_2.0-6.1_armel.deb (--unpack):
subprocess dpkg-deb --fsys-tarfile returned error exit status 2
Unpacking libavformat53 (from .../libavformat53_6%3a0.8.21-0+deb7u1_armel.deb) ...
dpkg-deb: file `/var/cache/apt/archives/libavformat53_6%3a0.8.21-0+deb7u1_armel.deb' contains ununderstood data member data.tar.xz , giving up
dpkg: error processing /var/cache/apt/archives/libavformat53_6%3a0.8.21-0+deb7u1_armel.deb (--unpack):
subprocess dpkg-deb --fsys-tarfile returned error exit status 2
Unpacking libdvdnav4 (from .../libdvdnav4_4.2.0+20120524-2_armel.deb) ...
dpkg-deb: file `/var/cache/apt/archives/libdvdnav4_4.2.0+20120524-2_armel.deb' contains ununderstood data member data.tar.xz , giving up
dpkg: error processing /var/cache/apt/archives/libdvdnav4_4.2.0+20120524-2_armel.deb (--unpack):
subprocess dpkg-deb --fsys-tarfile returned error exit status 2
Unpacking libpostproc52 (from .../libpostproc52_6%3a0.8.21-0+deb7u1_armel.deb) ...
dpkg-deb: file `/var/cache/apt/archives/libpostproc52_6%3a0.8.21-0+deb7u1_armel.deb' contains ununderstood data member data.tar.xz , giving up
dpkg: error processing /var/cache/apt/archives/libpostproc52_6%3a0.8.21-0+deb7u1_armel.deb (--unpack):
subprocess dpkg-deb --fsys-tarfile returned error exit status 2
Unpacking libswscale2 (from .../libswscale2_6%3a0.8.21-0+deb7u1_armel.deb) ...
dpkg-deb: file `/var/cache/apt/archives/libswscale2_6%3a0.8.21-0+deb7u1_armel.deb' contains ununderstood data member data.tar.xz , giving up
dpkg: error processing /var/cache/apt/archives/libswscale2_6%3a0.8.21-0+deb7u1_armel.deb (--unpack):
subprocess dpkg-deb --fsys-tarfile returned error exit status 2
Errors were encountered while processing:
/var/cache/apt/archives/libavutil51_6%3a0.8.21-0+deb7u1_armel.deb
/var/cache/apt/archives/libavcodec53_6%3a0.8.21-0+deb7u1_armel.deb
/var/cache/apt/archives/libpulse0_2.0-6.1_armel.deb
/var/cache/apt/archives/libavformat53_6%3a0.8.21-0+deb7u1_armel.deb
/var/cache/apt/archives/libdvdnav4_4.2.0+20120524-2_armel.deb
/var/cache/apt/archives/libpostproc52_6%3a0.8.21-0+deb7u1_armel.deb
/var/cache/apt/archives/libswscale2_6%3a0.8.21-0+deb7u1_armel.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
ghost:/#
It looks like you’re encountering issues because your version of dpkg doesn’t support .xz compressed files, which are used in the newer .deb packages.
If you cannot Update dpkg to a version that supports .xz archives and the issue persists, you might need to manually download and install dpkg from a more recent repository or try updating to a newer distribution if possible. This should enable support for the .xz format and allow the installations to proceed without errors.
Ok. Thank you for your input.
That said, that my current dpkg cannot install .xz archives, how would I upgrade to Debian Jessie with a broken dpkg? I cannot compile a working dpkg, So, how would I go about upgrading?
Install these packages without verification [y/N]? y
Extracting templates from packages: 100%
Preconfiguring packages ...
Can not write log, openpty() failed (/dev/pts not mounted?)
Setting up util-linux (2.20.1-5.3) ...
Can't locate Dpkg.pm in @INC (@INC contains: /etc/perl /usr/local/lib/perl/5.10.1 /usr/local/share/perl/5.10.1 /usr/lib/perl5 /usr/share/perl5 /usr/lib/perl/5.10 /usr/share/perl/5.10 /usr/local/lib/site_perl .) at /usr/sbin/update-alternatives line 16.
BEGIN failed--compilation aborted at /usr/sbin/update-alternatives line 16.
dpkg: error processing util-linux (--configure):
subprocess installed post-installation script returned error exit status 2
Errors were encountered while processing:
util-linux
E: Sub-process /usr/bin/dpkg returned an error code (1)
Thank you for your help! You are indeed The Founder.
It's good if you read your error messages and think about them; what they are, and why you have time (before posting).
The error in your post suggests a missing or broken Perl module, Dpkg.pm, which is essential for dpkg operations.
Specifically, this issue is affecting update-alternatives and preventing dpkg from correctly configuring util-linux.
Normally errors messages are very useful; and when you are running a version of Debian which is 6 years past EOL, you cannot expect any of the automated processes to work flawlessly.
So, you must either (1) upgrade to a new server version running a fully supported version of Debian / Linux, or (2) you will have to (struggle to) fix every error in your obsolete version of Debian one-error-at-a-time, @ignatius
Running unsupported software 6 years past end-of-life is not a good idea, for anyone. If you want an easier life, you need to run your apps on a supported, modern version of Debian or Linux.