It's not a secret anymore!
The moose likes Linux / UNIX and the fly likes Configuring Linux to load mysql driviers Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » Linux / UNIX
Bookmark "Configuring Linux to load mysql driviers" Watch "Configuring Linux to load mysql driviers" New topic

Configuring Linux to load mysql driviers

Rahul Mahindrakar
Ranch Hand

Joined: Jul 28, 2000
Posts: 1868
I am trying to use JDBC on Linux with mysql as the database. the driver is on the classpath and the classfiles compile fine. However on runtime i get the error no classdeffoundError org/gjit/mm/mysql/Driver
Any suggestions??
Josh Lipschutz

Joined: Sep 10, 2000
Posts: 2
I wish I had an answer for you but I am experiencing similar problems. I am a little new to this environment. How can I see what classpath the driver is on?
Many thanks.
George Brown
Ranch Hand

Joined: Sep 26, 2000
Posts: 919
first, it may be more appropriate to post this to the JDBC forum. There are probably loads of JDBC boffins there. But anyway, assuming you're using Linux or UNIX, type the following:
echo ${CLASSPATH} | tr ':' '\n'
That should output what paths are currently in your classpath.
If your driver is in /home/josh/classes the full path for the driver class (using Rahul's driver example) would be:
(alternatively, your Driver may be in a '.jar' file in which case, you can specify the full path of the jar file as a part of the classpath).
The path /home/josh/classes would have to be one of the paths on your classpath.
There's no tool that I know of that will tell you where your JDBC drivers are. That part is for you to decide according to the system you are putting together. Put them wherever you consider it appropriate to put JDBC drivers.
I hope that helps.
Srikanth Remani

Joined: Jun 08, 2001
Posts: 4
I am also planning to install and work JDBC on Linux.
I think by placing the driver (in jar or zip form) in

I have never used the class path stuff (not kidding, coz it never worked well 4 me).
this should work......
I agree. Here's the link:
subject: Configuring Linux to load mysql driviers
It's not a secret anymore!