I would like to be able to run a process that exists on a Linux machine remotely from a JAVA application running on a Windows machine. What is the best way to do this? Or an online resource that can help me? Many thanks.
You can use any of many Java SSH client libraries, such as javassh , as long as the Linux machine starts sshd (and the firewalls are configured to allow ssh traffic), which is likely to happen. There are many possible ways to configure SSH authentication, basically boiling up to sending a password (securely) on the network or using public / private key pairs (RSA or DSA) - the latter is usually preferable, but you will need to familiarize yourself with the system and network administrators about this problem ... this is not a software development problem, but rather a system administration and security one.
In short, use the ssh client.
1: openssh Cygwin.
2: Putty.
( ) .
- . Java- Java (~ webservice), . , , . ? ? , , Java?
ssh ..
String[] cm = { "ssh", "username@hostIP" , "your command" }; try { Process q= Runtime.getRuntime().exec(cm); q.waitFor(); } catch(Exception e) {}
Source: https://habr.com/ru/post/1718732/More articles:Noise from 2.0 to 2.1 (2.2) - javaМожно ли отправить сообщение рычания другому пользователю на том же компьютере в OSX? - macoshttps://translate.googleusercontent.com/translate_c?depth=1&pto=aue&rurl=translate.google.com&sl=ru&sp=nmt4&tl=en&u=https://fooobar.com/questions/1718729/windows-software-to-browse-svn-repository-that-isnt-tortoisesvn&usg=ALkJrhjJbZv9AT20EsgjUF2orjNauxnr7AПоиск ошибок MySQL из LOAD DATA INFILE - sqlRandom name php - phpLinq Combine Left Join Data - c #латексная этикетка newenvironment - latexJava mail send queue - a fixed number of threads sending as many messages as available - javaColdfusion equiv php strtotime ()? - coldfusionC ++ Saving Objects in a File - c ++All Articles