title: Anaconda ImportError: /usr/lib64/libstdc++.so.6: version `GLIBCXX_3.4.21' not found
body: <p>I am getting the following import error when I am trying to run a Python script in a conda environment</p>
  <pre><code>(squad) azada@scholar-fe00:~/Desktop/Toy-Problem-Team-2 $ python3 train.py 
  Traceback (most recent call last):
    File &quot;train.py&quot;, line 21, in &lt;module&gt;
      from tensorboardX import SummaryWriter
    File &quot;/home/azada/miniconda3/envs/squad/lib/python3.6/site-packages/tensorboardX/__init__.py&quot;, line 5, in &lt;module&gt;
      from .torchvis import TorchVis
    File &quot;/home/azada/miniconda3/envs/squad/lib/python3.6/site-packages/tensorboardX/torchvis.py&quot;, line 11, in &lt;module&gt;
      from .writer import SummaryWriter
    File &quot;/home/azada/miniconda3/envs/squad/lib/python3.6/site-packages/tensorboardX/writer.py&quot;, line 15, in &lt;module&gt;
      from .event_file_writer import EventFileWriter
    File &quot;/home/azada/miniconda3/envs/squad/lib/python3.6/site-packages/tensorboardX/event_file_writer.py&quot;, line 28, in &lt;module&gt;
      from .proto import event_pb2
    File &quot;/home/azada/miniconda3/envs/squad/lib/python3.6/site-packages/tensorboardX/proto/event_pb2.py&quot;, line 7, in &lt;module&gt;
      from google.protobuf import descriptor as _descriptor
    File &quot;/home/azada/miniconda3/envs/squad/lib/python3.6/site-packages/google/protobuf/descriptor.py&quot;, line 47, in &lt;module&gt;
      from google.protobuf.pyext import _message
  ImportError: /usr/lib64/libstdc++.so.6: version `GLIBCXX_3.4.21' not found (required by /home/azada/miniconda3/envs/squad/lib/python3.6/site-packages/google/protobuf/pyext/_message.cpython-36m-x86_64-linux-gnu.so)
  </code></pre>
  <p>Writing the <code>strings /usr/lib64/libstdc++.so.6 | grep GLIBCXX</code> command has the following output</p>
  <pre><code>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
  </code></pre>
  <p>As you can see the required <code>libgcc</code> version is not present. But I am unable to understand why python is looking for <code>GLIBCXX</code> in the <code>/usr</code> directory?</p>
  <p>Running the same command on the <code>libstdc++.so.6</code> of my anaconda environment shows that the required version is present in the file.</p>
  <p>I am using my university's computing cluster so I don't have the admin rights.</p>
  <p>Is there any way that I can make Python use the <code>libstdc++</code> of my conda environment instead of the one in the <code>/usr</code> directory?</p>