{"id":8,"date":"2012-03-13T22:03:55","date_gmt":"2012-03-13T21:03:55","guid":{"rendered":"http:\/\/mscholten.eu\/?p=8"},"modified":"2013-08-30T18:53:08","modified_gmt":"2013-08-30T17:53:08","slug":"debian-upgrade-problems","status":"publish","type":"post","link":"https:\/\/mscholten.eu\/?p=8","title":{"rendered":"Debian upgrade problems"},"content":{"rendered":"<p>The last time I updated a system from Debian Lenny to a more recent Debian version I discovered a problem. This was from Debian Lenny to Debian Squeeze and at the end I upgraded to Debian Wheezy. This was caused by tar being an old version and not the most recent version, this is something that shouldn&#8217;t happen. The solution I used was installing a more recent tar version.<\/p>\n<p>The problem:<\/p>\n<blockquote><p>server:~# apt-get dist-upgrade<br \/>\nReading package lists&#8230; Done<br \/>\nBuilding dependency tree<br \/>\nReading state information&#8230; Done<br \/>\nYou might want to run `apt-get -f install&#8217; to correct these.<br \/>\nThe following packages have unmet dependencies:<br \/>\ndpkg-dev: Depends: base-files (&gt;= 5.0.0) but 5lenny6 is installed<br \/>\nRecommends: libalgorithm-merge-perl but it is not installed<br \/>\nlibc6: Breaks: locales-all (&lt; 2.13) but 2.11.3-2 is installed<br \/>\nlibc6-amd64: Depends: libc6 (= 2.11.3-2) but 2.13-27 is installed<br \/>\nlibc6-i686: PreDepends: libc6 (= 2.11.3-2) but 2.13-27 is installed<br \/>\nlocales-all: Depends: glibc-2.11-1<br \/>\nE: Unmet dependencies. Try using -f.<br \/>\nserver:~# apt-get -f install<br \/>\nReading package lists&#8230; Done<br \/>\nBuilding dependency tree<br \/>\nReading state information&#8230; Done<br \/>\nCorrecting dependencies&#8230; Done<br \/>\nThe following packages were automatically installed and are no longer required:<br \/>\n(&#8230;)<\/p>\n<p>Use &#8216;apt-get autoremove&#8217; to remove them.<br \/>\nThe following extra packages will be installed:<br \/>\nbase-files<br \/>\nThe following packages will be REMOVED:<br \/>\nlib64gcc1 lib64gomp1 libc6-amd64 libc6-i686 locales-all<br \/>\nThe following packages will be upgraded:<br \/>\nbase-files<br \/>\n1 upgraded, 0 newly installed, 5 to remove and 340 not upgraded.<br \/>\n1 not fully installed or removed.<br \/>\nNeed to get 67.5kB of archives.<br \/>\nAfter this operation, 16.7MB disk space will be freed.<br \/>\nDo you want to continue [Y\/n]? y<br \/>\nGet:1 http:\/\/debian.apt-get.eu squeeze\/main base-files 6.0squeeze4 [67.5kB]<br \/>\nFetched 67.5kB in 0s (2072kB\/s)<br \/>\ntar: unrecognized option `&#8211;warning=no-timestamp&#8217;<br \/>\nTry `tar &#8211;help&#8217; or `tar &#8211;usage&#8217; for more information.<br \/>\ndpkg-deb: error: subprocess tar returned error exit status 64<br \/>\ndpkg: error processing \/var\/cache\/apt\/archives\/base-files_6.0squeeze4_i386.deb (&#8211;unpack):<br \/>\nsubprocess dpkg-deb &#8211;control returned error exit status 2<br \/>\nErrors were encountered while processing:<br \/>\n\/var\/cache\/apt\/archives\/base-files_6.0squeeze4_i386.deb<br \/>\nE: Sub-process \/usr\/bin\/dpkg returned an error code (1)<br \/>\nserver:~# aptitude full-upgrade<br \/>\nReading package lists&#8230; Done<br \/>\nBuilding dependency tree<br \/>\nReading state information&#8230; Done<br \/>\nReading extended state information<br \/>\nInitializing package states&#8230; Done<br \/>\nWriting extended state information&#8230; Done<br \/>\nReading task descriptions&#8230; Done<br \/>\nThe following packages are BROKEN:<br \/>\n(&#8230;)<br \/>\nThe following NEW packages will be installed:<br \/>\n(&#8230;)<br \/>\nThe following partially installed packages will be configured:<br \/>\ndpkg-dev<br \/>\nThe following packages are RECOMMENDED but will NOT be installed:<br \/>\n(&#8230;)<\/p>\n<p>334 packages upgraded, 72 newly installed, 24 to remove and 0 not upgraded.<br \/>\nNeed to get 234MB\/234MB of archives. After unpacking 244MB will be used.<br \/>\nThe following packages have unmet dependencies:<br \/>\nlibfont-freetype-perl: Depends: perlapi-5.10.0 which is a virtual package.<br \/>\nlocales-all: Depends: glibc-2.11-1 which is a virtual package.<br \/>\nlibc6-i686: PreDepends: libc6 (= 2.11.3-2) but 2.13-27 is installed.<br \/>\nlibept0: Depends: libapt-pkg-libc6.7-6-4.6 which is a virtual package.<br \/>\nlibuuid-perl: Depends: perlapi-5.10.1 which is a virtual package.<br \/>\nlibcap-dev: Depends: libcap2 (= 1:2.19-3) but 1:2.22-1 is installed.<br \/>\nlibc6-amd64: Depends: libc6 (= 2.11.3-2) but 2.13-27 is installed.<br \/>\nlibmudflap0-dev: Depends: gcc-4.1-base (= 4.1.2-25) but 4.1.2-29 is to be installed.<br \/>\nlibc6: Breaks: locales-all (&lt; 2.13) but 2.11.3-2 is installed.<br \/>\nThe following actions will resolve these dependencies:<\/p>\n<p>Remove the following packages:<br \/>\nlib64gcc1<br \/>\nlib64gomp1<br \/>\nlibc6-amd64<br \/>\nlibc6-i686<br \/>\nlibept0<br \/>\nlibmudflap0-dev<br \/>\nlinux-image-2.6-486<br \/>\nlinux-image-2.6-686-bigmem<br \/>\nlocales-all<\/p>\n<p>Keep the following packages at their current version:<br \/>\nlibcap-dev [1:1.10-14 (now)]<br \/>\nlibfont-freetype-perl [Not Installed]<br \/>\nlibuuid-perl [Not Installed]<br \/>\nlinux-base [Not Installed]<br \/>\nlinux-image-2.6.32-5-486 [Not Installed]<br \/>\nlinux-image-2.6.32-5-686-bigmem [Not Installed]<\/p>\n<p>Leave the following dependencies unresolved:<br \/>\ndefoma recommends libfont-freetype-perl<br \/>\nlinux-image-2.6.26-2-686-bigmem recommends libc6-i686<br \/>\nlibc6 recommends libc6-i686<br \/>\nScore is 190<\/p>\n<p>Accept this solution? [Y\/n\/q\/?]y<br \/>\nThe following NEW packages will be installed:<br \/>\n(&#8230;)<br \/>\nThe following packages will be upgraded:<br \/>\n(&#8230;)<br \/>\nThe following partially installed packages will be configured:<br \/>\ndpkg-dev<br \/>\nThe following packages are RECOMMENDED but will NOT be installed:<br \/>\n(&#8230;)<br \/>\n328 packages upgraded, 66 newly installed, 34 to remove and 1 not upgraded.<br \/>\nNeed to get 178MB\/178MB of archives. After unpacking 61.9MB will be used.<br \/>\nDo you want to continue? [Y\/n\/?] y<\/p>\n<p>(&#8230;)<\/p>\n<p>Fetched 178MB in 12s (14.0MB\/s)<br \/>\nExtracting templates from packages: 100%<br \/>\nPreconfiguring packages &#8230;<br \/>\ntar: unrecognized option `&#8211;warning=no-timestamp&#8217;<br \/>\nTry `tar &#8211;help&#8217; or `tar &#8211;usage&#8217; for more information.<br \/>\ndpkg-deb: error: subprocess tar returned error exit status 64<br \/>\ndpkg: error processing \/var\/cache\/apt\/archives\/patch_2.6-2_i386.deb (&#8211;unpack):<br \/>\nsubprocess dpkg-deb &#8211;control returned error exit status 2<br \/>\ntar: unrecognized option `&#8211;warning=no-timestamp&#8217;<br \/>\nTry `tar &#8211;help&#8217; or `tar &#8211;usage&#8217; for more information.<br \/>\ndpkg-deb: error: subprocess tar returned error exit status 64<br \/>\ndpkg: error processing \/var\/cache\/apt\/archives\/base-files_6.0squeeze4_i386.deb (&#8211;unpack):<br \/>\nsubprocess dpkg-deb &#8211;control returned error exit status 2<br \/>\nErrors were encountered while processing:<br \/>\n\/var\/cache\/apt\/archives\/patch_2.6-2_i386.deb<br \/>\n\/var\/cache\/apt\/archives\/base-files_6.0squeeze4_i386.deb<br \/>\nE: Sub-process \/usr\/bin\/dpkg returned an error code (1)<br \/>\nA package failed to install. \u00a0Trying to recover:<br \/>\ndpkg: dependency problems prevent configuration of dpkg-dev:<br \/>\ndpkg-dev depends on base-files (&gt;= 5.0.0); however:<br \/>\nVersion of base-files on system is 5lenny6.<br \/>\ndpkg: error processing dpkg-dev (&#8211;configure):<br \/>\ndependency problems &#8211; leaving unconfigured<br \/>\nErrors were encountered while processing:<br \/>\ndpkg-dev<br \/>\nReading package lists&#8230; Done<br \/>\nBuilding dependency tree<br \/>\nReading state information&#8230; Done<br \/>\nReading extended state information<br \/>\nInitializing package states&#8230; Done<br \/>\nWriting extended state information&#8230; Done<br \/>\nReading task descriptions&#8230; Done<\/p><\/blockquote>\n<p>Like you can see there was an error while upgrading the Debian system. The first thing I did try didn&#8217;t work:<\/p>\n<blockquote><p>cd \/usr\/bin<\/p>\n<p>mv dpkg dpkg-old<\/p>\n<p>mv dpkg-deb dpkg-deb-old<br \/>\nmv dpkg-divert dpkg-divert-old<br \/>\nmv dpkg-maintscript-helper dpkg-maintscript-helper-old<br \/>\nmv dpkg-split dpkg-split-old<br \/>\nmv dpkg-query dpkg-query-old<br \/>\nmv dpkg-statoverride dpkg-statoverride-old<br \/>\nmv dpkg-trigger dpkg-trigger-old<\/p>\n<p>scp other_server_with_debian_lenny_and_same_kernel:\/usr\/bin\/dpk* .\/<\/p>\n<p>chmod a+x dpk*<\/p><\/blockquote>\n<p>This didn&#8217;t solve the problems. After that I did download and install a newer tar version. This is something you can copy (please change version number\/kernel type when needed):<\/p>\n<blockquote><p>mkdir \/tmp\/tar<\/p>\n<p>cd \/tmp\/tar<\/p>\n<p>wget http:\/\/ftp.br.debian.org\/debian\/pool\/main\/t\/tar\/tar_1.26-4_i386.deb<\/p>\n<p>ar x tar_1.26-4_i386.deb<\/p>\n<p>tar xzf data.tar.gz<\/p>\n<p>cp -p \/bin\/tar \/bin\/tar-old<\/p>\n<p>cp -p bin\/tar \/bin\/tar<\/p><\/blockquote>\n<p>This way tar was installed and upgrading was possible again without really big problems. Below was what I did next.<\/p>\n<blockquote><p>nano \/etc\/apt\/sources.list # Change it to Debian Wheezy<\/p>\n<p>apt-get clean<\/p>\n<p>apt-get update<\/p>\n<p>apt-get install tar<\/p>\n<p>apt-get dist-upgrade # Did give a problem<\/p>\n<p>apt-get -f install # Didn&#8217;t really work<\/p>\n<p>aptitude full-upgrade # Multiple times, till there where no packages to update\/upgrade<\/p><\/blockquote>\n<p>That was how it was solved.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>The last time I updated a system from Debian Lenny to a more recent Debian version I discovered a problem. This was from Debian Lenny to Debian Squeeze and at the end I upgraded to Debian Wheezy. This was caused &hellip; <a href=\"https:\/\/mscholten.eu\/?p=8\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3,4,5,7,6],"tags":[],"class_list":["post-8","post","type-post","status-publish","format-standard","hentry","category-debian","category-lenny","category-squeeze","category-upgrade","category-wheezy"],"_links":{"self":[{"href":"https:\/\/mscholten.eu\/index.php?rest_route=\/wp\/v2\/posts\/8","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/mscholten.eu\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/mscholten.eu\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/mscholten.eu\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/mscholten.eu\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=8"}],"version-history":[{"count":4,"href":"https:\/\/mscholten.eu\/index.php?rest_route=\/wp\/v2\/posts\/8\/revisions"}],"predecessor-version":[{"id":73,"href":"https:\/\/mscholten.eu\/index.php?rest_route=\/wp\/v2\/posts\/8\/revisions\/73"}],"wp:attachment":[{"href":"https:\/\/mscholten.eu\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=8"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/mscholten.eu\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=8"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/mscholten.eu\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=8"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}