我试图在我的CentOS 6.3 x64服务器上执行以下命令:
nohup "/usr/local/bin/php -v"
结果是:
nohup: ignoring input and appending output to `nohup.out' nohup: failed to run command `/usr/local/bin/php -v': No such file or directory
这对CentOS 5的作品没有问题。 任何想法我做错了什么?
发生这种情况是因为您没有名为/usr/local/bin/php -v 。 既然你把它放在引号中,整个string被当作参数来对待。
尝试删除引号。
nohup /usr/local/bin/php -v