1

I was trying to perform upgrade from Debian 6 to 7.11 (wheezy). I've changed sources.list to:

deb http://ftp.debian.org/debian/ wheezy main contrib non-free

deb-src http://ftp.debian.org/debian/ wheezy main



deb http://security.debian.org/ wheezy/updates main contrib non-free

deb-src http://security.debian.org/ wheezy/updates main



deb http://ftp.debian.org/debian/ wheezy-updates main contrib non-free

deb-src http://ftp.debian.org/debian/ wheezy-updates main



deb http://ftp.debian.org/debian/ wheezy-backports main contrib non-free

And started by apt-get update, then apt-get upgrade and finally apt-get dist-upgrade

After all these steps I've got in file /etc/debian_version value 7.11 but I can't do nothing using apt because of following error:

root@server:~# apt-get dist-upgrade

apt-get: /usr/local/lib/libstdc++.so.6: version `GLIBCXX_3.4.15' not found (required by apt-get)

apt-get: /usr/local/lib/libstdc++.so.6: version `GLIBCXX_3.4.15' not found (required by /usr/lib/x86_64-linux-gnu/libapt-pkg.so.4.12)



root@server:~# apt-get update

apt-get: /usr/local/lib/libstdc++.so.6: version `GLIBCXX_3.4.15' not found (required by apt-get)

apt-get: /usr/local/lib/libstdc++.so.6: version `GLIBCXX_3.4.15' not found (required by /usr/lib/x86_64-linux-gnu/libapt-pkg.so.4.12)
2

You have a copy of libstdc++.so.6 in /usr/local/lib which is being used in preference to the system’s copy (in /usr/lib or one of its sub-directories). To get apt working again, you need to delete it or at least rename it:

sudo mv /usr/local/lib/libstdc++.so.6{,.old}

You should also rename the file libstdc++.so.6 points to; after doing the above, run:

tgt=$(readlink /usr/local/lib/libstdc++.so.6.old)
sudo mv "/usr/local/lib/${tgt}"{,.old}

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.