【发布时间】:2012-12-02 05:01:22
【问题描述】:
我正在设置我的 VPS 以部署我的 rails 应用程序,但我的服务器端不断发生权限被拒绝错误。我不得不重新安装 perl 和 curl,现在我得到以下内容:
deployer@max:~$ rbenv bootstrap-ubuntu-12-04
bash: /usr/bin/python: permission denied
我尝试重新安装 python 但没有成功。我该如何解决?
更新:
root@max:/home/deployer# cd /usr
root@max:/usr# cd bin
root@max:/usr/bin# cd python
bash: cd: python: not a directory
这是否意味着python没有正确安装?
更新:
deployer@max:~$ ls -l 'which python'
total 0
deployer@max:~$ python
bash: /usr/bin/python: permission denied
我认为这意味着 python 没有正确安装,所以我计算了以下
deployer@d:~$ su root
root@d:/home/deployer# apt-get install python
python package is already the latest version
所以我还没找到解决办法。
【问题讨论】:
-
ls -l `which python`输出什么?你能运行python,会发生什么? -
@soulseekah,请检查更新。
-
which python必须反引号而不是引用,照原样复制我的评论。 -
简单的
which python输出什么?也可以试试chmod 755 /usr/bin/python。运行root时which命令输出什么,尤其是带有ls的命令? -
然后
sudo chmod 0755 /usr/bin/python看看是否有帮助。似乎deployer的执行位已关闭。
标签: ruby-on-rails permissions vps