Skip to content
Advertisement

Derby: Another instance of Derby may have already booted the database

I would like to use Derby in a Network Server Mode and followed the instructions on their website.

Starting derby:

JavaScript

Connecting with ij:

JavaScript

Connecting to Derby in Java:

JavaScript

The DriverManager.getConnection() is failing with:

JavaScript

Haven’t I just started derby in network server mode? Why am I getting this error?

Advertisement

Answer

Your ij connection did:

JavaScript

which means that it didn’t connect to the Network Server, but rather opened the database directly using the Embedded Driver.

If you had specified:

JavaScript

then both applications (IJ and your program) would have connected via the Client Driver and the second connection would not have been rejected.

Advertisement