# How to install PyPlot on a server

**URL:** <https://discourse.julialang.org/t/how-to-install-pyplot-on-a-server/131419>\
**Category:** General Usage\
**Tags:** question, package, pyplot\
**Created:** [August 6, 2025, 4:46pm UTC](https://discourse.julialang.org/t/how-to-install-pyplot-on-a-server/131419 "2025-08-06T16:46:15Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![ufechner7](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ufechner7/32/51363_2.png) [@ufechner7](https://discourse.julialang.org/u/ufechner7)\
**Post date:** [August 6, 2025, 4:46pm UTC](https://discourse.julialang.org/t/how-to-install-pyplot-on-a-server/131419/1 "2025-08-06T16:46:15Z")

</div>

When trying to install PyPlot on [DelftBlue](https://www.tudelft.nl/dhpc/system), the supercomputer of TU Delft, running on Red Hat Enterprise Linux 8, I get the following error:

```julia-auto
ImportError("/home/uwefechner/.julia/juliaup/julia-1.11.6+0.x64.linux.gnu/bin/../lib/julia/libstdc++.so.6: version `CXXABI_1.3.15' not found (required by /home/uwefechner/.julia/conda/3/x86_64/lib/python3.12/site-packages/matplotlib/_c_internal_utils.cpython-312-x86_64-linux-gnu.so)")

```

What could be the reason?

To reproduce the error, run the following Bash script:

```bash
module load 2023r1
export PYTHON=""
export PYTHON_EXEC=""
export PYTHON_PATH=""
rm -rf ~/.julia/conda
julia -e 'using Pkg; Pkg.add("PyPlot"); Pkg.build("PyPlot")'
julia -e 'using PyPlot'

```

Further info:

```julia-auto
julia> versioninfo()
Julia Version 1.11.6
Commit 9615af0f269 (2025-07-09 12:58 UTC)
Build Info:
  Official https://julialang.org/ release
Platform Info:
  OS: Linux (x86_64-linux-gnu)
  CPU: 32 × Intel(R) Xeon(R) Gold 6226R CPU @ 2.90GHz
  WORD_SIZE: 64
  LLVM: libLLVM-16.0.6 (ORCJIT, cascadelake)
Threads: 1 default, 0 interactive, 1 GC (on 32 virtual cores)
Environment:
  LD_LIBRARY_PATH = /cm/shared/apps/slurm/current/lib64

```

---

<div class="post-metadata">

**Author:** ![dqeeq](https://avatars.discourse-cdn.com/v4/letter/d/b9e5f3/32.png) [@dqeeq](https://discourse.julialang.org/u/dqeeq)\
**Post date:** [August 6, 2025, 8:48pm UTC](https://discourse.julialang.org/t/how-to-install-pyplot-on-a-server/131419/2 "2025-08-06T20:48:41Z")

</div>

I don’t know if this is related, but can you try

```julia-auto
export LD_LIBRARY_PATH=.

```

---

<div class="post-metadata">

**Author:** ![ufechner7](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ufechner7/32/51363_2.png) [@ufechner7](https://discourse.julialang.org/u/ufechner7)\
**Post date:** [August 7, 2025, 10:01am UTC](https://discourse.julialang.org/t/how-to-install-pyplot-on-a-server/131419/3 "2025-08-07T10:01:54Z")

</div>

I tried your suggestion:

`module load 2023r1`  
`export PYTHON=“”`  
`export PYTHON_EXEC=“”`  
`export PYTHON_PATH=“”`  
`echo “Deleting .julia/conda …”`  
`rm -rf ~/.julia/conda`  
`export LD_LIBRARY_PATH=.`  
`echo “Installing and building PyPlot…”`  
`julia -e ‘using Pkg; Pkg.add(“PyPlot”); Pkg.build(“PyPlot”)’`  
`echo “Using PyPlot…”`  
`julia -e ‘using PyPlot’`

Still the same error:

> PyCall is currently configured to use the Julia-specific Python distributioninstalled by the Conda.jl package. To install the matplotlib module, you canuse pyimport\_conda(“matplotlib”, PKG), where PKG is the Anacondapackage that contains the module matplotlib, or alternatively you can use theConda package directly (via using Conda followed by Conda.add etcetera).
> 
> Alternatively, if you want to use a different Python distribution on yoursystem, such as a system-wide Python (as opposed to the Julia-specific Python),you can re-configure PyCall with that Python. As explained in the PyCalldocumentation, set ENV[“PYTHON”] to the path/name of the python executableyou want to use, run Pkg.build(“PyCall”), and re-launch Julia.
> 
> ) \<class ‘ImportError’\>ImportError(“/home/uwefechner/.julia/juliaup/julia-1.11.6+0.x64.linux.gnu/bin/../lib/julia/libstdc++.so.6: version CXXABI\_1.3.15’ not found (required by /home/uwefechner/.julia/conda/3/x86\_64/lib/python3.12/site-packages/matplotlib/\_c\_internal\_utils.cpython-312-x86\_64-linux-gnu.so)”)File “/home/uwefechner/.julia/conda/3/x86\_64/lib/python3.12/site-packages/matplotlib/init.py”, line 161, in from . import \_api, \_version, cbook, \_docstring, rcsetupFile “/home/uwefechner/.julia/conda/3/x86\_64/lib/python3.12/site-packages/matplotlib/cbook.py”, line 32, in from matplotlib import \_api, \_c\_internal\_utils

UPDATE:  
Some progress:  
`[uwefechner@login02 ~]$ find ~ -name ‘libstdc++.so.6’ 2>/dev/null`  
`/home/uwefechner/.julia/juliaup/julia-1.11.6+0.x64.linux.gnu/lib/julia/libstdc++.so.6`  
`/home/uwefechner/.julia/conda/3/x86_64/lib/libstdc++.so.6`  
`/home/uwefechner/.julia/conda/3/x86_64/pkgs/libstdcxx-15.1.0-h8f9b012_3/lib/libstdc++.so.6`

---

<div class="post-metadata">

**Author:** ![ufechner7](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ufechner7/32/51363_2.png) [@ufechner7](https://discourse.julialang.org/u/ufechner7)\
**Post date:** [August 7, 2025, 11:06am UTC](https://discourse.julialang.org/t/how-to-install-pyplot-on-a-server/131419/4 "2025-08-07T11:06:01Z")

</div>

This works:

```bash
[uwefechner@login03 ~]$ cat install_pyplot 
module load 2023r1
export PYTHON=""
export PYTHON_EXEC=""
export PYTHON_PATH=""
export LD_LIBRARY_PATH=~/.julia/conda/3/x86_64/lib:~/.julia/juliaup/julia-1.11.6+0.x64.linux.gnu/lib/julia
echo "Deleting ~/.julia/conda..."
rm -rf ~/.julia/conda
echo "Installing PyPlot..."
julia -e 'ENV["PYTHON"]=""; using Pkg; Pkg.add("PyPlot"); Pkg.build("PyPlot")'
echo "Using PyPlot"
julia -e 'using PyPlot'

```

And in my .bashrc file I have to do:

```bash
export LD_LIBRARY_PATH=~/.julia/conda/3/x86_64/lib:~/.julia/juliaup/

```
