Hi Boday, thanks for the suggestion. I have few more doubts here.
I have written few simple shell scripts. I am testing exec stuff from camle to call these scripts. I installed cygwin in my system. When I tried running the exec through Camel, was failing with following error. SEVERE: Caused by: [org.apache.camel.component.exec.ExecException - Unable to execute command ExecCommand [args=[], executable=D:/Program Files/Cygwin/bin/bash /tmp/exec/scripts/echo.sh, timeout=9223372036854775807, outFile=null, workingDir=null, useStderrOnEmptyStdout=false]] org.apache.camel.component.exec.ExecException: Unable to execute command ExecCommand [args=[], executable=D:/Program Files/Cygwin/bin/bash /tmp/exec/scripts/echo.sh, timeout=9223372036854775807, outFile=null, workingDir=null, useStderrOnEmptyStdout=false] at org.apache.camel.component.exec.impl.DefaultExecCommandExecutor.execute(DefaultExecCommandExecutor.java:81) at org.apache.camel.component.exec.ExecProducer.process(ExecProducer.java:48) .... .... Caused by: java.io.IOException: Cannot run program "D:\Program Files\Cygwin\bin\bash \tmp\exec\scripts\echo.sh": CreateProcess error=3, The system cannot find the path specified at java.lang.ProcessBuilder.start(ProcessBuilder.java:460) at java.lang.Runtime.exec(Runtime.java:593) .... .... Caused by: java.io.IOException: CreateProcess error=3, The system cannot find the path specified at java.lang.ProcessImpl.create(Native Method) ... ... I have also written a standalone java program, which will directly execute the same command using Runtime.getRuntime().exec() method, where it executed perfectly without any errors/exceptions. Now,I am uncertain, why the similar stuff is failing when I execute through camel. E.g. from("file:/tmp/exec")..to("exec:D:/Program Files/Cygwin/bin/bash /tmp/exec/scripts/echo.sh"); Anyone, please suggest on this. Thanks and Regards, Jeevan Mithyantha. -- View this message in context: http://camel.465427.n5.nabble.com/Calling-shell-script-from-Camel-tp4794335p4798408.html Sent from the Camel - Users mailing list archive at Nabble.com.