2012-03-28 70 views
-1

我試圖通過PuTTY使用SSH命令重新啓動一個名爲site_checker.rb的守護進程。該文件位於:重新啓動內置於Ruby on Rails的守護進程

/home/MYUSERNAME/web/current/lib/daemons 

登錄到我的網站,它是使用Ruby構建on Rails的後,我看到下面的屏幕:

[[email protected] ~]$ 

從這裏,我進入

[[email protected] ~]$ cd web 

然後

[[email protected] ~/web]$ script/daemons start 

但是,我得到一個錯誤:

-bash: script/daemons: No such file or directory 

回答

0

您嘗試,而你要求你的腳本實際上是/home/MYUSERNAME/web/current/lib/daemons開始/home/MYUSERNAME/web/lib/daemons。您錯過了current

+0

@Holger_Just,非常感謝您的回覆! '[MyUserName輸入@名爲myUsername〜] $ CD網/ current' 然後 '[MyUserName輸入@名爲myUsername:你會具體是什麼我後'[MyUserName輸入@名爲myUsername〜] $' 我想打字澄清〜/ web/current] $ script/daemons start' 但收到相同的錯誤。 – KDP 2012-03-28 22:19:48

+0

更新:我通過執行'su -'並輸入密碼來更改爲root。然後,我使用命令'/home/USERNAME/web/current/lib/daemons/site_checker.rb start'並收到以下響應: '/ bin/sh:第1行:/ home/USERNAME/web/current/lib /daemons/site_checker.rb:不能執行[Permission denied]'我很困惑。怎麼可能「根」被拒絕?有沒有更好的方法來獲取這個site_checker.rb重新啓動? – KDP 2012-03-30 19:22:07