Tx for your reply.

Found out that a simple line separator iso a space seperates different
commands...

In my case I create a StringBuilder with the different commands with the
separator:

sb.append("config:edit MyPID");
sb.append(System.getProperty("line.separator"));
sb.append("config:propset MyProperty MyValue");
sb.append(System.getProperty("line.separator"));
sb.append("config:update");

and use this to create the ssh channel:

channel = session.createChannel("exec", sb.toString());




--
View this message in context: 
http://karaf.922171.n3.nabble.com/multiple-ssh-commands-programatically-tp3644509p3647352.html
Sent from the Karaf - User mailing list archive at Nabble.com.

Reply via email to