Command (.4gl) executed with SSH.NET SshClient.RunCommand fails with “No such file or directory”

后端 未结 2 1073
失恋的感觉
失恋的感觉 2021-01-07 12:29

I have a web service that uses SSH.NET to call a shell script on a Unix box.

If I run the script normally, it works fine, does its work correctly on the Informix DB.

2条回答
  •  谎友^
    谎友^ (楼主)
    2021-01-07 13:13

    Have seen similar questions asked by Informix-4gl developers as they transition to FourJs Genero and using its Web Services functionality. The question I'll put to them is "who owns the fglgo/fglrun process that the Genero Application Server has launched, where is it running from, and what is its environment". If needed, I'll illustrate with a simple program that does something like ...

    MAIN 
        RUN "env > /tmp/myname.txt"
        RUN "who >> /tmp/myname.txt"
        RUN "pwd >> /tmp/myname.txt"
    END MAIN   
    

    ... and say compare with when program is running from command line. It is normally a case like in the earlier answer of configuring so that the environment is set correctly before the 4gl program is executed.

提交回复
热议问题