Centos7 执行firewall-cmd –permanent –add-service=mysql报错“ModuleNotFoundError: No module named 'gi'”

因为目前环境Python3.x与Python2.x版本并存,所以导致以上问题。

解决方法:

第一步,vim  /usr/bin/firewall-cmd, 将#!/usr/bin/python -Es 改为 #!/usr/bin/python2 -Es

第二步,vim /usr/sbin/firewalld, 将#!/usr/bin/python -Es 改为 #!/usr/bin/python2 -Es

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-06-14
  • 2021-06-30
  • 2021-09-05
  • 2021-07-19
猜你喜欢
  • 2022-12-23
  • 2021-04-06
  • 2021-04-26
  • 2022-12-23
  • 2021-11-24
  • 2021-04-06
  • 2021-05-27
相关资源
相似解决方案