db-derby-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From John Embretsen <John.Embret...@Sun.COM>
Subject Re: PATH (newbie) problems...
Date Thu, 06 Apr 2006 11:01:06 GMT
Hi dan,

dan wrote:

> Yesterday everything was fine but today I cannot start the server using 
> the modified
> scripts (all 8 attached) and either as user dan or root. Please see below.
> /dan

I think you are making this more complicated than it really is. You should
not have to edit all the scripts or run as root in order to e.g. start the
network server (that is what you are trying to achieve, correct?). So let's
start from the beginning and see if things work:

I assume you have downloaded Derby "bin" (zip or tar.gz).
After extracting that archive, you will find a directory called "frameworks".
You find scripts for starting the server and so on in


In order to make the .ksh scripts (I only tried the "startNetworkServer.ksh"
script this time) work in a linux environment, there are only *two* things
you need to do first, since the scripts depend on these settings (unless, of
course you change all the scripts yourself, which obviously complicates
things even more):

1. Set the environment variable DERBY_INSTALL to the directory where you have
installed derby, i.e. the parent directory of the frameworks directory.

Example (1) (bash shell):

$ export DERBY_INSTALL="/home/user/derby/db-derby-"

To check the value of DERBY_INSTALL, do:


2. Set the environment variable JAVA_HOME to the Java installation you want
to use for running Derby (using the scripts).

Example (2) (bash shell):

$ export JAVA_HOME="/usr/java/jdk1.5.0_04"

To check the value of JAVA_HOME, do:

$ echo $JAVA_HOME

Then, in order to start the network server, all you have to do is to execute
the startNetworkServer.ksh script:

$ ${DERBY_INSTALL}/frameworks/NetworkServer/bin/startNetworkServer.ksh

(this works as long as the execute bit is set for the script file)

You can of course cd to that directory before executing the script, or
including the script directory in your PATH for easy access, but I won't get
into that here.

Here is what happens on my machine when I follow the steps above:

Server is ready to accept connections on port 1527.

Please try it if you're still stuck...

So far you have (for instance) been mixing client and server classpath
scripts, so I recommend using unmodified scripts and starting over as
explained above.

Hope it helps!


View raw message