db-derby-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Kerry <karaf-u...@avionicengineers.com>
Subject Re: Derby newbie - error seen creating 'seconddb' thru ij for network-server Derby
Date Fri, 08 Nov 2019 10:10:03 GMT
1. If you don't have $DERBY_HOME set then I do believe Derby will take it's bike from whichever
directory it has been started from.
2. Your Derby log confirms it's a permissions error. A *CRUDE* fix for this is:

Locate the file 'java.policy'. it's probably located in /etc/java-11-openjdk/security.
Add the following immediately above other permissions within that file:

permission java.security.AllPermission;

This however should not be a long term fix and you should investigate a more secure solution.
Maybe others on this mailing list might have a more informed solution.


⁣Sent from BlueMail ​

On 8 Nov 2019, 09:40, at 09:40, Banibrata Dutta <banibrata.dutta@gmail.com> wrote:
>Thanks Kerry. Finally found 'derby.log' which was in my $HOME (not in
>$DERBY_HOME), perhaps because that's where I started derby network
>The log file has following 3 entries towards the end, and indeed it
>to be permission problem:
>Fri Nov 08 12:34:46 IST 2019 Thread[DRDAConnThread_4,5,main] (DATABASE
>seconddb), (DRDAID = {5}), Failed to create database 'seconddb', see
>next exception for details.
>Fri Nov 08 12:34:46 IST 2019 Thread[DRDAConnThread_4,5,main] (DATABASE
>seconddb), (DRDAID = {5}), Startup failed due to an exception. See next
>exception for details.
>Fri Nov 08 12:34:46 IST 2019 Thread[DRDAConnThread_4,5,main] (DATABASE
>seconddb), (DRDAID = {5}), Java exception: 'access denied
>("java.lang.RuntimePermission" "getenv.SOURCE_DATE_EPOCH"):
>What should be done to provide permissions ? Is the permission going to
>Derby specific ?
>On Fri, Nov 8, 2019 at 2:44 PM Kerry <karaf-user@avionicengineers.com>
>> Hi,
>> This sounds like it might be a Java permissions error as you are
>> Open JDK 11. If you look in the derby.log file located in $DERBY_HOME
>> will give an indication. Post the content of it here.
>> Kerry
>> Sent from BlueMail <http://www.bluemail.me/r?b=15726>
>> On 8 Nov 2019, at 07:29, Banibrata Dutta <banibrata.dutta@gmail.com>
>> wrote:
>>> Hi Folk,
>>> Trying to use Derby for the first time. I am not an expert Java
>>> but dabbling for learning me some. I followed the official Derby
>>> instructions for installing the latest Derby on my freshly minted
>>> (lighter Ubuntu using LXDE) 64-bit 18.04.3 setup, with OpenJDK11
>>> Have started Derby in network server mode like this:
>>> $ java -jar $DERBY_HOME/lib/derbyrun.jar server start
>>> And then trying to using ij to create the database like this:
>>> $ ij
>>> ij version 10.15
>>> ij> CONNECT 'jdbc:derby://localhost:1527/seconddb;create=true';
>>> ERROR XJ041: DERBY SQL error: ERRORCODE: 40000, SQLSTATE: XJ041,
>>> SQLERRMC: Failed to create database 'seconddb', see the next
>exception for
>>> details.::SQLSTATE: XBM01::SQLSTATE: XJ001
>>> ij>
>>> Trying to read around, there are suggestions to look into derby.log
>>> but I found none so far. What gives ? How to proceed ? Didn't find
>>> general troubleshooting instructions in the docs. Tried the FAQ, but
>>> obvious clues.
>>> cheers,
>>> B

View raw message