I am developing Web Application in local machine using JSP. I want to execute a Java Program that resides on Unix box from my local JSP file. I have all the credentials of the UNIX box. Can you please advise me.
Asked
Active
Viewed 1,075 times
0
-
Tastes like [RMI](http://download.oracle.com/javase/tutorial/rmi/index.html). – Nishant Feb 25 '11 at 09:48
-
2Don't try to do that kind of stuff from your JSP! JSP is meant to be a pure view technology: it's used to output HTML for the browser to consume. Your logic (including interaction with other hosts) should be in a Servlet (or Action, if you use a framework such as Struts). – Joachim Sauer Feb 25 '11 at 10:03
1 Answers
1
Well there are various ways to execute [instruct remote machine to execute your java program]
Defining your protocol and then Socket server client

jmj
- 237,923
- 42
- 401
- 438
-
Can you please provide me any sample program where I can call remote program from local JSP – Mansi Feb 25 '11 at 09:55
-
1
-
yes. sorry did not find my answer. I am not much into java j2ee. I am just trying to do a POC to execute a java program in UNIX from local JSP. Can you please help me or guide me if I missed something in the hyper link provided by you. – Mansi Feb 25 '11 at 10:03
-
Or simply check this http://stackoverflow.com/questions/1001179/unix-ssh-script-running-commands-on-remote-server – jmj Feb 25 '11 at 10:08