M
mwmann
Hi everyone,
My problem is, A have created a simple tool to run a shell scipt
located on a remote unix server via a ssh2 session (using ganymed-ssh2
library).
The output from this script when run from my java tool differs to the
output when the shell script is run directly on the server, some of the
output is not displayed, it seems so far that output generated in
functions contained in the shell script, or generated in loops in the
shell script are not displayed when run from my java tool.
As an attempted work around I created a wrapper sell script which was
suppossed to redirect the out put from the script into a tmp file, and
the java task read directly from that file- The strange thing is that,
I get the same problem, when I run the wrapper from unix, correct
output in tmp file is generated, when I run the warpper from my java
tool, not all output is generated in tmp file.
This seems like really strange behaviour to me, as anyone experienced
something like this before?
Basically the reason for the tool , is that we can not allow certain
junior employees to log onto client machines, however we need them to
be able to run certain scripts already located on the server. -
Any help or ideas would be greatly appreciated.
My problem is, A have created a simple tool to run a shell scipt
located on a remote unix server via a ssh2 session (using ganymed-ssh2
library).
The output from this script when run from my java tool differs to the
output when the shell script is run directly on the server, some of the
output is not displayed, it seems so far that output generated in
functions contained in the shell script, or generated in loops in the
shell script are not displayed when run from my java tool.
As an attempted work around I created a wrapper sell script which was
suppossed to redirect the out put from the script into a tmp file, and
the java task read directly from that file- The strange thing is that,
I get the same problem, when I run the wrapper from unix, correct
output in tmp file is generated, when I run the warpper from my java
tool, not all output is generated in tmp file.
This seems like really strange behaviour to me, as anyone experienced
something like this before?
Basically the reason for the tool , is that we can not allow certain
junior employees to log onto client machines, however we need them to
be able to run certain scripts already located on the server. -
Any help or ideas would be greatly appreciated.