Reading a little bit the "grid-proxy-init -help" output, I solved my problem as follow:

// Code written in groovy
def x1 = "echo grid".execute()
def x2 = "grid-proxy-init -pwstdin".execute()
x1 | x2
println x2.waitFor()

happy weekend for all :-)

John Sanabria wrote:
Hi,

I'm developing a Java module in charge of executes remote grid tasks. Some of those tasks take more than twelve hours to be finished.

When, a certificate expires then the module can not execute more tasks then throwing a GSSException.

One solution is run the grid-proxy-init command along with "-valid" parameter. I think, it's a temporary solution.

Then, I tested ExpectJ and expect4j Java libraries for "automating" the credential renewal process. Both libraries have a expect(String) method and a send(String) method. (ExpectJ -> expectErr).

I invoke them as follow:
<instance_class>.expect("Enter GRID pass phrase for this identity:")
<instance_class>.send(<mypassphrase>)
and nothing happens. Looks like the <instance_class> can not catch this "Enter GRID pass phrase for this identity:".

Has the grid-proxy-init command some hack for avoiding this kind of non-interactive update certificates procedure? If it is, how to overcome that?

Thanks, happy weekend ;-)



Reply via email to