use of com.sun.enterprise.util.cluster.windows.process.WindowsRemoteScripter in project Payara by payara.
the class ValidateDcom method testRemoteScript.
private boolean testRemoteScript() {
String scriptOut = null;
try {
WindowsRemoteScripter scripter = new WindowsRemoteScripter(creds);
scriptOut = scripter.run(scriptFullPath);
script.delete();
} catch (WindowsException ex) {
setError(ex, Strings.get("dcom.no.run", host));
return false;
}
out.append(Strings.get("dcom.run.ok", host, crunch(12, scriptOut))).append('\n');
return true;
}
use of com.sun.enterprise.util.cluster.windows.process.WindowsRemoteScripter in project Payara by payara.
the class ValidateDcom method testJdkAvailable.
private boolean testJdkAvailable() {
try {
script = new WindowsRemoteFile(wrf, SCRIPT_NAME);
script.copyFrom("javac -version \r\n");
WindowsRemoteScripter scripter = new WindowsRemoteScripter(creds);
// javac and jar write to stderr NOT stdout
scripter.wantStdErr();
String scriptOut = scripter.run(scriptFullPath);
script.delete();
out.append(Strings.get("dcom.yes.jdk", host, scriptOut));
out.append('\n');
return true;
} catch (WindowsException ex) {
setError(ex, Strings.get("dcom.no.jdk", host));
return false;
}
}
use of com.sun.enterprise.util.cluster.windows.process.WindowsRemoteScripter in project Payara by payara.
the class InstallNodeDcomCommand method unpackOnHosts.
private void unpackOnHosts(String host, String remotePassword, String unpackScript) throws WindowsException, CommandException {
String domain = windowsDomain;
if (!ok(domain))
domain = host;
WindowsCredentials bonafides = new WindowsCredentials(host, domain, getRemoteUser(), remotePassword);
WindowsRemoteScripter scripter = new WindowsRemoteScripter(bonafides);
String out = scripter.run(unpackScript);
if (out == null || out.length() < 50)
throw new CommandException(Strings.get("dcom.error.unpacking", unpackScript, out));
if (logger.isLoggable(Level.FINE))
logger.fine("Output from Windows Unpacker:\n" + out);
}
Aggregations