【发布时间】:2019-05-15 19:53:24
【问题描述】:
我正在尝试在 centos7 上使用 '#! /usr/bin/python3' 但因为我不得不
通过以下方式安装 Python3:
Yum install centos-release-scl
Yum install rh-python36
scl enable rh-python36 bash
Python3 不在/usr/bin/python3
我尝试使用:
#! /opt/rh/rh-python36
我在尝试运行 python 脚本时遇到这些错误
bash: ./pw.py: /opt/rh/rh-python36: bad interpreter: Permission denied
./pw.py: /opt/rh/rh-python36: bad interpreter: Permission denied
【问题讨论】:
-
请不要运行 sudo chmod -R 755 /opt/rh/rh-python36/ 它将删除使 sudo 命令不可用
标签: python-3.x centos7