Executing shell script with system() returns 256. What does that mean?

前端 未结 4 1136
一向
一向 2020-12-01 11:08

I\'ve written a shell script to soft-restart HAProxy (reverse proxy). Executing the script from the shell works. But I want a daemon to execute the script. That doesn\'t wor

4条回答
  •  無奈伤痛
    2020-12-01 11:42

    A code of 256 probably means that the system command cannot locate the binary to run it. Remember that it may not be calling bash and that it may not have paths setup. Try again with full paths to the binaries!

提交回复
热议问题