0
$ $CLASSPATH
$ $ source .profile
$ $CLASSPATH
> bash: :/usr/java/connectors/mysql-connector-java-5.1.23-bin.jar: No such file or directory
$ /usr/java/connectors/mysql-connector-java-5.1.23-bin.jar
> no main manifest attribute, in /usr/java/connectors/mysql-connector-java-5.1.23-bin.jar
What I'm having trouble understanding is, when I run it from $CLASSPATH (to see if it has been set) why it's not being detected. Shouldn't it be the same if I type it in? I'm getting two different results.
the connector is 0777 with owner root:root.
What does '$' and '>' at the beginning of the line mean? – None – 2013-03-05T06:06:05.493
$ means "this is something I'm typing as my user (not root)"
So you typed
$CLASSPATH
, then you typed.profile
, then you typedCLASSPATH
(without$
) and got error message? So that isCLASSPATH
command? – None – 2013-03-05T08:24:48.463sorry the third line has $CLASSPATH, it's an environment variable I set in profile... that should also be "$ source profile" I'll edit now. – James Bone – 2013-03-05T11:43:22.400
Are you exporting the CLASSPATH environment variable? Either in your script or on the command line you need: export CLASSPATH – Paul Bone – 2013-03-06T05:59:58.950