Hey Divya:
I guess that Abe means you could write a script like
[root@server-654 test]# cat mysqoop.sh
export JAVA_HOME="your_java_home"
./sqoop.sh $*
And run mysqoop.sh just like sqoop
Mysqoop.sh import --connect jdbc:mysql:// --username XXX --password YYY --table
test …
Regards
Richard
From: Divya Ravichandran [mailto:[email protected]]
Sent: Friday, May 29, 2015 2:53 AM
To: Abraham Elmahrek
Cc: [email protected]
Subject: Re: Issue with setting JAVA_HOME
What parameter do we need to set in the wrapper script to make sqoop use jdk.
We know setting $JAVA_HOME system property will change it for the entire
system. We don’t want to do that since we have other hadoop services running on
the same node, and we don’t want them to run on jdk. The other solution would
be to set JAVA_HOME variable to point to jdk in hadoop_env.sh, but even this
solution would make all the other hadoop services to use jdk. So is there
another variable which I can set which will be only sqoop specific and make
only sqoop use jdk while other hadoop services on the node still use jre.
And we have sqoop client written in java. Is there anything that needs to be
set programmatically?
-Divya
On May 28, 2015 2:02 PM, "Abraham Elmahrek"
<[email protected]<mailto:[email protected]>> wrote:
Sqoop1 is a CLI tool. You should be able to just write a wrapper script that
sets them and calls sqoop.
On Thu, May 28, 2015 at 6:24 AM, Divya Ravichandran
<[email protected]<mailto:[email protected]>> wrote:
sqoop-sys.sh doesn't exist in sqoop1.
Is there a similar work around in sqoop1?
Thanks,
Divya
On May 28, 2015 3:03 AM, "Abraham Elmahrek"
<[email protected]<mailto:[email protected]>> wrote:
Work around might be to set those variables in sqoop-sys.sh.
On Thu, May 21, 2015 at 6:49 AM, Divya Ravichandran
<[email protected]<mailto:[email protected]>> wrote:
Hello,
I am trying to run sqoop and yarn on the same machine.
Sqoop needs JAVA_HOME be set to JDK whereas yarn requires JRE(which is the
recommended setting).
Can this setting be changed dynamically so it can pick up JDK for sqoop and JRE
for yarn?
Or any workarounds possible?
Please let me know!
Thanks,
Divya