Ubuntu: GLIBCXX_3.4.20 not found, how to fix this error?


Whey I try to run the program Layout Editor (available on this site) on Ubuntu 14.04.1 64-bit LTS I get the following output in the terminal:

$ layout  layout: /usr/lib/x86_64-linux-gnu/libstdc++.so.6: version `GLIBCXX_3.4.20' not found (required by layout)  

I tried the command strings on /usr/lib/x86_64-linux-gnu/libstdc++.so.6 as following and here is the input and the output:

$ strings /usr/lib/x86_64-linux-gnu/libstdc++.so.6 | grep GLIBCXX  GLIBCXX_3.4  GLIBCXX_3.4.1  GLIBCXX_3.4.2  GLIBCXX_3.4.3  GLIBCXX_3.4.4  GLIBCXX_3.4.5  GLIBCXX_3.4.6  GLIBCXX_3.4.7  GLIBCXX_3.4.8  GLIBCXX_3.4.9  GLIBCXX_3.4.10  GLIBCXX_3.4.11  GLIBCXX_3.4.12  GLIBCXX_3.4.13  GLIBCXX_3.4.14  GLIBCXX_3.4.15  GLIBCXX_3.4.16  GLIBCXX_3.4.17  GLIBCXX_3.4.18  GLIBCXX_3.4.19  GLIBCXX_DEBUG_MESSAGE_LENGTH  

How can I resolve this issue I somehow guess that it is related with GCC but cannot figure out how to fix the problem. Furthermore, I have tried a PPA as suggested on How do I use the latest GCC on Ubuntu? and there is a similar question for an older version of Ubuntu at GLIBCXX_3.4.15 not found. However, after I ran sudo update I get numerous warnings and the list I obtained with the strings command did not have new entries after installing gcc 4.9, so I purged the PPA(Toolchains Test Builds) with ppa-purge. Any help, suggestions on how to proceed are greatly appreciated.


I was having the same problem when trying to run other program, and found a solution on StackOverflow.

Basically, just do the following commands: Firstly, install:

sudo apt-get install libstdc++6  

This should already be installed by default, but try it anyway. If it doesn't solve it, just do the following:

sudo add-apt-repository ppa:ubuntu-toolchain-r/test   sudo apt-get update  sudo apt-get upgrade  sudo apt-get dist-upgrade  

I didn't perform the "dist-upgrade" command, but the ones before solved it for me


It happened to me with anaconda 4.0.0 (as @mjp stated), but the fix for me was to run this command in my environment:

conda install libgcc  


I had this issue - it was because Anaconda2 didn't have the GLIBCXX_3.4.20 version of whatever that thing is. Only up to .19, the same as yours.

However, Ubuntu's library did have it. So I just created a softlink/shortcut in the Anaconda library to the actual Linux library containing that GLIBCXX_3.4.20, replacing the previous one, and it worked fine after restarting the python GUI (Spyder).

There should be a folder called libstdc++.so.6 in the Anaconda library, which is here: ~/anaconda2/lib. Within this folder is the versions of the script/library-code-thing, excluding the one that you're missing: GLIBCXX_3.4.20

Follow these steps to solve the issue:

  1. go to the right location and backup your current anaconda2 shortcut (change its name so it isn't overwritten):

    cd ~/anaconda2/lib  mv -vf libstdc++.so.6 libstdc++.so.6.old  
  2. create a new shortcut using the ln command (I am assuming that I am in the previous location ~/anaconda2/lib):

    ln -s /usr/lib/x86_64-linux-gnu/libstdc++.so.6 ./libstdc++.so.6  
  3. restart spyder / other interface you use

It should now work!


I've had that numerous times through out the years with many different packages. It has always been resolved by:

sudo apt-get dist-upgrade  

If your dist is upgradable, it will almost always bring down a new C++ library and reconfig things such as that they work again. The issue is almost always caused by your system not pointing to the right library. In my case, usually caused by pointing to a cross-compiler version of a library.


sudo cp /usr/bin/YourGccVersionLibrary/lib64/libstdc++.so.6 /usr/bin/YourGccVersionLibrary/lib64/libstdc++.so.6.0.20 /usr/lib/x86_64_linux-gnu/  

Note:If u also have question or solution just comment us below or mail us on toontricks1994@gmail.com
Next Post »