Start Remote Derby server.

cd <DERBY_INSTALL>/frameworks/NetworkServer/bin

$  ./NetworkServerControl.ksh start -h hostname.domain.name -p PORT#

This host name must be accessed from client machine. You may also use IP address in place of hostname.domain.name

To check if this server is running, run the following command in a new command terminal.

$  ./NetworkServerControl.ksh sysinfo -h hostname.domain.name -p PORT#

Check for the following value in output

...

derby.drda.portNumber=PORT#

...

...

derby.drda.host=hostname.domain.name

...

 

Start Netbeans on client machine.

In runtime tab select

Databases->Java DB(Net) -> right click -> Select "Connect Using..."

You will see a connect dialog.

Enter the following values in Database URL :  jdbc:derby://<hostname.domain.name>:<PORT#>/sample;create=true

User Name : app

Password : app

Click on "OK" button.

Observe a new database connection node is added to Databases tree.

Comments:

Post a Comment:
  • HTML Syntax: NOT allowed

This blog copyright 2009 by pcmreddy