On Monday 04 June 2007 15:52:59 Dave Howorth wrote: > Patrick Shanahan wrote: > > * Dave Howorth <[EMAIL PROTECTED]> [06-04-07 06:46]: > >> I'm trying to run a Java program from a cron job and have discovered > >> that JAVA_HOME and friends aren't set. What's the best way to set them > >> for cron jobs? > >> > >> I'm presently on 9.3 but will be moving to 10.2 shortly. > > > > add: JAVA_HOME=<location/you/desire> > > Thanks. I was trying to avoid hardwiring and instead would like to make > use of the Suse-defined Java configuration mechanisms if I can. > > i.e. <location/you/desire> is not something I invent, it's something the > system invents, but it fails to let cron know. > > Cheers, Dave
Since we switched to jpackage-style packaging, the currently used JRE is always located at: /usr/lib/jre (/usr/lib64/jre on x86_64 and ppc64) and the JDK at: /usr/lib/jvm/java (/usr/lib64/jvm/java on x86_64 and ppc64) those are symbolic links to the chosen JRE/JDK and changed by calling: update-alternatives --config java and update-alternatives --config javac ... so setting them is not a big problem, since they should always work. Best, Daniel -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
