You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-user@hadoop.apache.org by Deepak Diwakar <dd...@gmail.com> on 2008/10/20 18:43:12 UTC

mysql in hadoop

Hi all,

I am sure someone must have tried mysql connection using hadoop. But I am
getting problem.
Basically I am not getting how to inlcude classpath of jar of jdbc connector
in the run command of hadoop or is there any other way so that we can
incorporate  jdbc connector jar into the main jar which we run using
$hadoop-home/bin/hadoop?

plz help me .

Thanks in advance,

Re: mysql in hadoop

Posted by "Amit k. Saha" <am...@gmail.com>.
Hi Deepak,

On Mon, Oct 20, 2008 at 10:13 PM, Deepak Diwakar <dd...@gmail.com> wrote:
> Hi all,
>
> I am sure someone must have tried mysql connection using hadoop. But I am
> getting problem.
> Basically I am not getting how to inlcude classpath of jar of jdbc connector
> in the run command of hadoop or is there any other way so that we can
> incorporate  jdbc connector jar into the main jar which we run using
> $hadoop-home/bin/hadoop?
>
> plz help me .
>
> Thanks in advance,

Just inquisitive: What application on Hadoop are you working on which
uses MySQL?

Thanks,
Amit
>



-- 
Amit Kumar Saha
http://blogs.sun.com/amitsaha/
http://amitsaha.in.googlepages.com/
Skype: amitkumarsaha

Re: mysql in hadoop

Posted by Deepak Diwakar <dd...@gmail.com>.
Thanks for the solution u guys provided.

actually  i got one solution ..
If we add the path of any external jar into classpath of hadoop which in
$hadoop_home/hadoop-$version/conf/hadoop-env.sh , It will do.

thanks for solution

2008/10/20 Gerardo Velez <jg...@gmail.com>

> Hi!
>
> Actually I got same problem and temporally I've solved it including jdbc
> dependecies inside main jar.
>
> Actually another solution I've found is you can place all jar dependencias
> inside hadoop/lib directory.
>
>
> Hope it helps.
>
>
> -- Gerardo
>
>
> On Mon, Oct 20, 2008 at 9:43 AM, Deepak Diwakar <dd...@gmail.com>
> wrote:
>
> > Hi all,
> >
> > I am sure someone must have tried mysql connection using hadoop. But I am
> > getting problem.
> > Basically I am not getting how to inlcude classpath of jar of jdbc
> > connector
> > in the run command of hadoop or is there any other way so that we can
> > incorporate  jdbc connector jar into the main jar which we run using
> > $hadoop-home/bin/hadoop?
> >
> > plz help me .
> >
> > Thanks in advance,
> >
>



-- 
- Deepak Diwakar,
Associate Software Eng.,
Pubmatic, pune
Contact: +919960930405

Re: mysql in hadoop

Posted by Gerardo Velez <jg...@gmail.com>.
Hi!

Actually I got same problem and temporally I've solved it including jdbc
dependecies inside main jar.

Actually another solution I've found is you can place all jar dependencias
inside hadoop/lib directory.


Hope it helps.


-- Gerardo


On Mon, Oct 20, 2008 at 9:43 AM, Deepak Diwakar <dd...@gmail.com> wrote:

> Hi all,
>
> I am sure someone must have tried mysql connection using hadoop. But I am
> getting problem.
> Basically I am not getting how to inlcude classpath of jar of jdbc
> connector
> in the run command of hadoop or is there any other way so that we can
> incorporate  jdbc connector jar into the main jar which we run using
> $hadoop-home/bin/hadoop?
>
> plz help me .
>
> Thanks in advance,
>

Re: mysql in hadoop

Posted by Sandeep Dey <sd...@yahoo-inc.com>.
Hi Deepak,

I can suggest a crude solution :) that might work . you can extract the 
jdbc connecter jar and copy the classes from there to ur class/build directory.
this way the jdbc driver classes are included in the final jar.

Hope that helps,
sandeep


On Mon, 20 Oct 2008, Deepak Diwakar wrote:

> Hi all,
>
> I am sure someone must have tried mysql connection using hadoop. But I am
> getting problem.
> Basically I am not getting how to inlcude classpath of jar of jdbc connector
> in the run command of hadoop or is there any other way so that we can
> incorporate  jdbc connector jar into the main jar which we run using
> $hadoop-home/bin/hadoop?
>
> plz help me .
>
> Thanks in advance,
>