Hey, I need to run a shell script on a remote server. I have been trying to use j2ssh's execute command function, but they dont seem to work. I can use some commands like rm and ls and mkdir but when i try to run a shell script it just doesn't work. heres my code:
Java Code:
try {
	                public SessionChannelClient session;
			session = ssh.openSessionChannel();
			session.requestPseudoTerminal("vt100", 80, 24, 0, 0, "");
			session.executeCommand("/start.sh");
			return true;

    		} catch (IOException e) {
    			e.printStackTrace();
    			return false;
    		}
The ssh and everything is set up fine. I know because i can use it to run other commands. So how can i use this to run a .sh on the server, or Is there a different API or some code that will do the job? Any way I can execute this shell will be fine. Thanks!