【Linux】编译常见问题FAQ

1.执行dnf install python3 :bash: /usr/bin/dnf: /usr/bin/python3: bad interpreter: No such file or directory

1
2
3
4
5
6
7
8
#原因,安装其他软件导致python 版本同dnf 配置文件里的python 版本不一致
[root@192 /]# whereis dnf
dnf: /usr/bin/dnf /etc/dnf /usr/share/man/man8/dnf.8.gz
[root@192 /]# vim /usr/bin/dnf
#!/usr/bin/python3.9
# The dnf executable script.
#

  1. error while loading shared libraries: librte_telemetry.so.21: cannot open shared object file: No such file or directory
1
2
3
4
vim /etc/ld.so.conf
#加入so lib path
如/usr/local/daos/prereq/release/spdk/lib
ldconfig 更新一下配置

3.ldd 查看 库 no found

1
2
3
vim /etc/ld.so.conf 

加相应的库路径,如/usr/local/daos/prereq/release/spdk/lib 后ldconfig