peacock 是moose中的一个GUI界面,可以帮助判断模型的输入。有一天打开软件发现peacock的时候发生错误报错内容
libGL error: MESA-LOADER: failed to open r600: /home/zhaohaowang/miniconda3/envs/moose/lib/python3.7/site-packages/PyQt5/../../../libstdc++.so.6: version `GLIBCXX_3.4.29' not found (required by /usr/lib/dri/r600_dri.so) (search paths /usr/lib/dri)
libGL error: failed to load driver: r600
libGL error: MESA-LOADER: failed to open r600: /home/zhaohaowang/miniconda3/envs/moose/lib/python3.7/site-packages/PyQt5/../../../libstdc++.so.6: version `GLIBCXX_3.4.29' not found (required by /usr/lib/dri/r600_dri.so) (search paths /usr/lib/dri)
libGL error: failed to load driver: r600
libGL error: MESA-LOADER: failed to open swrast: /home/zhaohaowang/miniconda3/envs/moose/lib/python3.7/site-packages/PyQt5/../../../libstdc++.so.6: version `GLIBCXX_3.4.29' not found (required by /usr/lib/dri/swrast_dri.so) (search paths /usr/lib/dri)
参考网上的说法:
matlab遇到这种问题
发现是peacock的libstdc++库没有和系统库匹配
解决问题
首先查找libstdc++的位置
sudo find / -name "libstdc++.so.6*"
得到
find: ‘/proc/83730/task/83730/net’: 无效的参数
find: ‘/proc/83730/net’: 无效的参数
find: ‘/run/user/1000/gvfs’: 权限不够
/home/zhaohaowang/miniconda3/pkgs/libstdcxx-ng-9.3.0-h6de172a_19/lib/libstdc++.so.6.0.28
/home/zhaohaowang/miniconda3/pkgs/libstdcxx-ng-9.3.0-h6de172a_19/lib/libstdc++.so.6
/home/zhaohaowang/miniconda3/pkgs/gcc_impl_linux-64-9.3.0-h28f5a38_17/x86_64-conda-linux-gnu/sysroot/lib64/libstdc++.so.6.0.28
/home/zhaohaowang/miniconda3/pkgs/gcc_impl_linux-64-9.3.0-h28f5a38_17/x86_64-conda-linux-gnu/sysroot/lib64/libstdc++.so.6
/home/zhaohaowang/miniconda3/pkgs/libstdcxx-ng-9.1.0-hdf63c60_0/lib/libstdc++.so.6.0.26
/home/zhaohaowang/miniconda3/pkgs/libstdcxx-ng-9.1.0-hdf63c60_0/lib/libstdc++.so.6
/home/zhaohaowang/miniconda3/pkgs/libstdcxx-ng-9.1.0-hdf63c60_0/x86_64-conda_cos6-linux-gnu/sysroot/lib/libstdc++.so.6.0.26
/home/zhaohaowang/miniconda3/pkgs/libstdcxx-ng-9.1.0-hdf63c60_0/x86_64-conda_cos6-linux-gnu/sysroot/lib/libstdc++.so.6
/home/zhaohaowang/miniconda3/pkgs/libstdcxx-devel_linux-64-9.3.0-h4084dd6_17/x86_64-conda-linux-gnu/lib/libstdc++.so.6.0.28
/home/zhaohaowang/miniconda3/pkgs/libstdcxx-devel_linux-64-9.3.0-h4084dd6_17/x86_64-conda-linux-gnu/lib/libstdc++.so.6
/home/zhaohaowang/miniconda3/lib/libstdc++.so.6.0.26
/home/zhaohaowang/miniconda3/lib/libstdc++.so.6.0.29
/home/zhaohaowang/miniconda3/lib/libstdc++.so.6.0.2
/home/zhaohaowang/miniconda3/envs/moose/x86_64-conda-linux-gnu/sysroot/lib64/libstdc++.so.6.0.28
/home/zhaohaowang/miniconda3/envs/moose/x86_64-conda-linux-gnu/sysroot/lib64/libstdc++.so.6
/home/zhaohaowang/miniconda3/envs/moose/x86_64-conda-linux-gnu/lib/libstdc++.so.6.0.28
/home/zhaohaowang/miniconda3/envs/moose/x86_64-conda-linux-gnu/lib/libstdc++.so.6
/home/zhaohaowang/miniconda3/envs/moose/lib/libstdc++.so.6.0.28
/home/zhaohaowang/miniconda3/envs/moose/lib/libstdc++.so.6
/home/zhaohaowang/miniconda3/envs/moose/lib/libstdc++.so.6.0.29
/home/zhaohaowang/miniconda3/x86_64-conda_cos6-linux-gnu/sysroot/lib/libstdc++.so.6.0.26
/home/zhaohaowang/miniconda3/x86_64-conda_cos6-linux-gnu/sysroot/lib/libstdc++.so.6
/home/zhaohaowang/.local/share/RecentDocuments/libstdc++.so.6.0.26.desktop
/usr/lib/dri/libstdc++.so.6
/usr/lib/libstdc++.so.6
/usr/lib/libstdc++.so.6.0.29
/usr/lib32/libstdc++.so.6
/usr/lib32/libstdc++.so.6.0.29
/usr/share/gdb/auto-load/usr/lib/libstdc++.so.6.0.29-gdb.py
把lib/libstdc++.so.6链接到peacock的libstdc++中
ln -sf /usr/lib/libstdc++.so.6 /home/zhaohaowang/miniconda3/envs/moose/lib/python3.7/site-packages/PyQt5/../../../libstdc++.so.6
然后就可以辣!