Thanks. I created https://issues.apache.org/jira/browse/DERBY-7122

Art

On Sat, 7 Aug 2021 at 01:06, Rick Hillegas <rick.hille...@gmail.com> wrote:
>
> You can also hack around this problem by starting the server without a
> security manager (see
> https://db.apache.org/derby/docs/10.15/security/tsecnetservopen.html):
>
>    java -jar $DERBY_HOME/lib/derbyrun.jar server start -noSecurityManager
>
> I doubt that the Open JDK team will give this issue much attention,
> given their plan to deprecate the security manager:
> https://openjdk.java.net/jeps/411
>
>
> On 8/6/21 7:52 AM, Rick Hillegas wrote:
> > I agree with Bryan that this looks like a platform-specific Open JDK
> > bug. In your bug report, please include the version numbers for the
> > Derby, Open JDK, and Ubuntu distros which you use to trigger this
> > exception. It would be interesting to know if the bug turns up when
> > you use the latest Open JDK 17 distro.
> >
> > Thanks,
> > -Rick
> >
> > On 8/6/21 7:22 AM, Bryan Pendleton wrote:
> >> That's very interesting! I don't know what it means, but the stack
> >> trace is very explicit and clear and shows us exactly where we are
> >> getting the security exception (which, unfortunately, is deep within
> >> the JDK runtime classes; all we are doing is calling
> >> properties.store() here)
> >>
> >> Could you please report this in the Derby JIRA issue tracker, so we
> >> can collect information about the fix?
> >> https://issues.apache.org/jira/browse/DERBY
> >>
> >> The exact line of code in context is:
> >> https://svn.apache.org/viewvc/db/derby/code/branches/10.15/java/org.apache.derby.engine/org/apache/derby/impl/services/monitor/StorageFactoryService.java?revision=1850575&view=markup#l369
> >>
> >>
> >> Others have had this exact same problem with JDK 11.
> >>
> >> I suspect it may be JDK11 specific; is there any chance you can try a
> >> different JDK version?
> >>
> >> >From this very helpful web page at Chalmers Institute of Technology
> >> (https://chalmers.instructure.com/courses/8915/pages/f-dot-a-q-common-issues),
> >>
> >> here is a simple workaround:
> >>
> >> The solution is to edit `~/.java.policy` or
> >> `[java.home]/lib/security/java.policy` and add the following:
> >>
> >> grant {
> >>      permission java.lang.RuntimePermission
> >> "getenv.SOURCE_DATE_EPOCH", "read";
> >> };
> >>
> >> Thanks again for helping to make Derby better!
> >>
> >> bryan
> >>
> >> On Thu, Aug 5, 2021 at 5:25 PM Art O Cathain <art.h...@gmail.com> wrote:
> >>> Hi
> >>>
> >>> Here goes...
> >>>
> >>> Fri Aug 06 10:14:45 AEST 2021 : Apache Derby Network Server -
> >>> 10.15.2.0 - (1873585) started and ready to accept connections on port
> >>> 1527
> >>> ----------------------------------------------------------------
> >>> Fri Aug 06 10:14:53 AEST 2021:
> >>> Booting Derby version The Apache Software Foundation - Apache Derby -
> >>> 10.15.2.0 - (1873585): instance a816c00e-017b-18cf-ef5d-ffffb7bad466
> >>> on database directory /home/art/src/DERBYTUTOR/seconddb with class
> >>> loader jdk.internal.loader.ClassLoaders$AppClassLoader@277050dc
> >>> Loaded from file:/home/art/src/db-derby-10.15.2.0-bin/lib/derby.jar
> >>> java.vendor=Ubuntu
> >>> user.dir=/home/art/src/DERBYTUTOR
> >>> os.name=Linux
> >>> os.arch=amd64
> >>> os.version=5.11.0-25-lowlatency
> >>> derby.system.home=/home/art/src/DERBYTUTOR
> >>> Database Class Loader started - derby.database.classpath=''
> >>> ----------------------------------------------------------------
> >>> Fri Aug 06 10:14:54 AEST 2021:
> >>> Shutting down instance a816c00e-017b-18cf-ef5d-ffffb7bad466 on
> >>> database directory /home/art/src/DERBYTUTOR/seconddb with class loader
> >>> jdk.internal.loader.ClassLoaders$AppClassLoader@277050dc
> >>> Fri Aug 06 10:14:54 AEST 2021 Thread[DRDAConnThread_2,5,main] Cleanup
> >>> action starting
> >>> ERROR XBM01: Startup failed due to an exception. See next exception
> >>> for details.
> >>>      at
> >>> org.apache.derby.shared.common.error.StandardException.newException(StandardException.java:300)
> >>>      at
> >>> org.apache.derby.iapi.services.monitor.Monitor.exceptionStartingModule(Monitor.java:743)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.BaseMonitor.bootService(BaseMonitor.java:1857)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.BaseMonitor.createPersistentService(BaseMonitor.java:1022)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.FileMonitor.createPersistentService(FileMonitor.java:48)
> >>>      at
> >>> org.apache.derby.iapi.services.monitor.Monitor.createPersistentService(Monitor.java:650)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection$5.run(EmbedConnection.java:4067)
> >>>      at java.base/java.security.AccessController.doPrivileged(Native
> >>> Method)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.createPersistentService(EmbedConnection.java:4061)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.createDatabase(EmbedConnection.java:2654)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.<init>(EmbedConnection.java:435)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver$1.run(InternalDriver.java:660)
> >>>
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver$1.run(InternalDriver.java:656)
> >>>
> >>>      at java.base/java.security.AccessController.doPrivileged(Native
> >>> Method)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver.getNewEmbedConnection(InternalDriver.java:654)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver.connect(InternalDriver.java:300)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver.connect(InternalDriver.java:967)
> >>>      at
> >>> org.apache.derby.jdbc.EmbeddedDriver.connect(EmbeddedDriver.java:125)
> >>>      at
> >>> org.apache.derby.impl.drda.Database.makeConnection(Database.java:253)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.getConnFromDatabaseName(DRDAConnThread.java:1476)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.verifyUserIdPassword(DRDAConnThread.java:1426)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.parseSECCHK(DRDAConnThread.java:3380)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.parseDRDAConnection(DRDAConnThread.java:1210)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.processCommands(DRDAConnThread.java:1010)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.run(DRDAConnThread.java:300)
> >>> Caused by: java.security.AccessControlException: access denied
> >>> ("java.lang.RuntimePermission" "getenv.SOURCE_DATE_EPOCH")
> >>>      at
> >>> java.base/java.security.AccessControlContext.checkPermission(AccessControlContext.java:472)
> >>>      at
> >>> java.base/java.security.AccessController.checkPermission(AccessController.java:897)
> >>>      at
> >>> java.base/java.lang.SecurityManager.checkPermission(SecurityManager.java:322)
> >>>      at java.base/java.lang.System.getenv(System.java:999)
> >>>      at
> >>> java.base/java.util.Properties.getFormattedTimestamp(Properties.java:1590)
> >>>      at java.base/java.util.Properties.store0(Properties.java:932)
> >>>      at java.base/java.util.Properties.store(Properties.java:921)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.StorageFactoryService$5.run(StorageFactoryService.java:369)
> >>>      at java.base/java.security.AccessController.doPrivileged(Native
> >>> Method)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.StorageFactoryService.saveServiceProperties(StorageFactoryService.java:347)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.BaseMonitor.bootService(BaseMonitor.java:1840)
> >>>      ... 22 more
> >>> ============= begin nested exception, level (1) ===========
> >>> java.security.AccessControlException: access denied
> >>> ("java.lang.RuntimePermission" "getenv.SOURCE_DATE_EPOCH")
> >>>      at
> >>> java.base/java.security.AccessControlContext.checkPermission(AccessControlContext.java:472)
> >>>      at
> >>> java.base/java.security.AccessController.checkPermission(AccessController.java:897)
> >>>      at
> >>> java.base/java.lang.SecurityManager.checkPermission(SecurityManager.java:322)
> >>>      at java.base/java.lang.System.getenv(System.java:999)
> >>>      at
> >>> java.base/java.util.Properties.getFormattedTimestamp(Properties.java:1590)
> >>>      at java.base/java.util.Properties.store0(Properties.java:932)
> >>>      at java.base/java.util.Properties.store(Properties.java:921)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.StorageFactoryService$5.run(StorageFactoryService.java:369)
> >>>      at java.base/java.security.AccessController.doPrivileged(Native
> >>> Method)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.StorageFactoryService.saveServiceProperties(StorageFactoryService.java:347)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.BaseMonitor.bootService(BaseMonitor.java:1840)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.BaseMonitor.createPersistentService(BaseMonitor.java:1022)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.FileMonitor.createPersistentService(FileMonitor.java:48)
> >>>      at
> >>> org.apache.derby.iapi.services.monitor.Monitor.createPersistentService(Monitor.java:650)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection$5.run(EmbedConnection.java:4067)
> >>>      at java.base/java.security.AccessController.doPrivileged(Native
> >>> Method)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.createPersistentService(EmbedConnection.java:4061)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.createDatabase(EmbedConnection.java:2654)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.<init>(EmbedConnection.java:435)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver$1.run(InternalDriver.java:660)
> >>>
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver$1.run(InternalDriver.java:656)
> >>>
> >>>      at java.base/java.security.AccessController.doPrivileged(Native
> >>> Method)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver.getNewEmbedConnection(InternalDriver.java:654)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver.connect(InternalDriver.java:300)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver.connect(InternalDriver.java:967)
> >>>      at
> >>> org.apache.derby.jdbc.EmbeddedDriver.connect(EmbeddedDriver.java:125)
> >>>      at
> >>> org.apache.derby.impl.drda.Database.makeConnection(Database.java:253)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.getConnFromDatabaseName(DRDAConnThread.java:1476)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.verifyUserIdPassword(DRDAConnThread.java:1426)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.parseSECCHK(DRDAConnThread.java:3380)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.parseDRDAConnection(DRDAConnThread.java:1210)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.processCommands(DRDAConnThread.java:1010)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.run(DRDAConnThread.java:300)
> >>> ============= end nested exception, level (1) ===========
> >>> Cleanup action completed
> >>> Fri Aug 06 10:14:54 AEST 2021 Thread[DRDAConnThread_2,5,main]
> >>> ERROR XJ001: Java exception: 'access denied
> >>> ("java.lang.RuntimePermission" "getenv.SOURCE_DATE_EPOCH"):
> >>> java.security.AccessControlException'.
> >>> java.sql.SQLException: Java exception: 'access denied
> >>> ("java.lang.RuntimePermission" "getenv.SOURCE_DATE_EPOCH"):
> >>> java.security.AccessControlException'.
> >>>      at
> >>> org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(SQLExceptionFactory.java:115)
> >>>      at
> >>> org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(SQLExceptionFactory.java:141)
> >>>      at org.apache.derby.impl.jdbc.Util.seeNextException(Util.java:252)
> >>>      at org.apache.derby.impl.jdbc.Util.javaException(Util.java:274)
> >>>      at
> >>> org.apache.derby.impl.jdbc.TransactionResourceImpl.wrapInSQLException(TransactionResourceImpl.java:444)
> >>>      at
> >>> org.apache.derby.impl.jdbc.TransactionResourceImpl.wrapInSQLException(TransactionResourceImpl.java:439)
> >>>      at
> >>> org.apache.derby.impl.jdbc.TransactionResourceImpl.handleException(TransactionResourceImpl.java:360)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.handleException(EmbedConnection.java:2405)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.createDatabase(EmbedConnection.java:2662)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.<init>(EmbedConnection.java:435)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver$1.run(InternalDriver.java:660)
> >>>
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver$1.run(InternalDriver.java:656)
> >>>
> >>>      at java.base/java.security.AccessController.doPrivileged(Native
> >>> Method)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver.getNewEmbedConnection(InternalDriver.java:654)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver.connect(InternalDriver.java:300)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver.connect(InternalDriver.java:967)
> >>>      at
> >>> org.apache.derby.jdbc.EmbeddedDriver.connect(EmbeddedDriver.java:125)
> >>>      at
> >>> org.apache.derby.impl.drda.Database.makeConnection(Database.java:253)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.getConnFromDatabaseName(DRDAConnThread.java:1476)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.verifyUserIdPassword(DRDAConnThread.java:1426)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.parseSECCHK(DRDAConnThread.java:3380)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.parseDRDAConnection(DRDAConnThread.java:1210)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.processCommands(DRDAConnThread.java:1010)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.run(DRDAConnThread.java:300)
> >>> Caused by: ERROR XJ001: Java exception: 'access denied
> >>> ("java.lang.RuntimePermission" "getenv.SOURCE_DATE_EPOCH"):
> >>> java.security.AccessControlException'.
> >>>      at
> >>> org.apache.derby.shared.common.error.StandardException.newException(StandardException.java:300)
> >>>      at
> >>> org.apache.derby.impl.jdbc.SQLExceptionFactory.wrapArgsForTransportAcrossDRDA(SQLExceptionFactory.java:170)
> >>>      at
> >>> org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(SQLExceptionFactory.java:75)
> >>>      ... 23 more
> >>> Caused by: java.security.AccessControlException: access denied
> >>> ("java.lang.RuntimePermission" "getenv.SOURCE_DATE_EPOCH")
> >>>      at
> >>> java.base/java.security.AccessControlContext.checkPermission(AccessControlContext.java:472)
> >>>      at
> >>> java.base/java.security.AccessController.checkPermission(AccessController.java:897)
> >>>      at
> >>> java.base/java.lang.SecurityManager.checkPermission(SecurityManager.java:322)
> >>>      at java.base/java.lang.System.getenv(System.java:999)
> >>>      at
> >>> java.base/java.util.Properties.getFormattedTimestamp(Properties.java:1590)
> >>>      at java.base/java.util.Properties.store0(Properties.java:932)
> >>>      at java.base/java.util.Properties.store(Properties.java:921)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.StorageFactoryService$5.run(StorageFactoryService.java:369)
> >>>      at java.base/java.security.AccessController.doPrivileged(Native
> >>> Method)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.StorageFactoryService.saveServiceProperties(StorageFactoryService.java:347)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.BaseMonitor.bootService(BaseMonitor.java:1840)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.BaseMonitor.createPersistentService(BaseMonitor.java:1022)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.FileMonitor.createPersistentService(FileMonitor.java:48)
> >>>      at
> >>> org.apache.derby.iapi.services.monitor.Monitor.createPersistentService(Monitor.java:650)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection$5.run(EmbedConnection.java:4067)
> >>>      at java.base/java.security.AccessController.doPrivileged(Native
> >>> Method)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.createPersistentService(EmbedConnection.java:4061)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.createDatabase(EmbedConnection.java:2654)
> >>>      ... 15 more
> >>> ============= begin nested exception, level (1) ===========
> >>> ERROR XJ001: Java exception: 'access denied
> >>> ("java.lang.RuntimePermission" "getenv.SOURCE_DATE_EPOCH"):
> >>> java.security.AccessControlException'.
> >>>      at
> >>> org.apache.derby.shared.common.error.StandardException.newException(StandardException.java:300)
> >>>      at
> >>> org.apache.derby.impl.jdbc.SQLExceptionFactory.wrapArgsForTransportAcrossDRDA(SQLExceptionFactory.java:170)
> >>>      at
> >>> org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(SQLExceptionFactory.java:75)
> >>>      at
> >>> org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(SQLExceptionFactory.java:141)
> >>>      at org.apache.derby.impl.jdbc.Util.seeNextException(Util.java:252)
> >>>      at org.apache.derby.impl.jdbc.Util.javaException(Util.java:274)
> >>>      at
> >>> org.apache.derby.impl.jdbc.TransactionResourceImpl.wrapInSQLException(TransactionResourceImpl.java:444)
> >>>      at
> >>> org.apache.derby.impl.jdbc.TransactionResourceImpl.wrapInSQLException(TransactionResourceImpl.java:439)
> >>>      at
> >>> org.apache.derby.impl.jdbc.TransactionResourceImpl.handleException(TransactionResourceImpl.java:360)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.handleException(EmbedConnection.java:2405)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.createDatabase(EmbedConnection.java:2662)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.<init>(EmbedConnection.java:435)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver$1.run(InternalDriver.java:660)
> >>>
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver$1.run(InternalDriver.java:656)
> >>>
> >>>      at java.base/java.security.AccessController.doPrivileged(Native
> >>> Method)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver.getNewEmbedConnection(InternalDriver.java:654)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver.connect(InternalDriver.java:300)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver.connect(InternalDriver.java:967)
> >>>      at
> >>> org.apache.derby.jdbc.EmbeddedDriver.connect(EmbeddedDriver.java:125)
> >>>      at
> >>> org.apache.derby.impl.drda.Database.makeConnection(Database.java:253)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.getConnFromDatabaseName(DRDAConnThread.java:1476)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.verifyUserIdPassword(DRDAConnThread.java:1426)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.parseSECCHK(DRDAConnThread.java:3380)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.parseDRDAConnection(DRDAConnThread.java:1210)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.processCommands(DRDAConnThread.java:1010)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.run(DRDAConnThread.java:300)
> >>> Caused by: java.security.AccessControlException: access denied
> >>> ("java.lang.RuntimePermission" "getenv.SOURCE_DATE_EPOCH")
> >>>      at
> >>> java.base/java.security.AccessControlContext.checkPermission(AccessControlContext.java:472)
> >>>      at
> >>> java.base/java.security.AccessController.checkPermission(AccessController.java:897)
> >>>      at
> >>> java.base/java.lang.SecurityManager.checkPermission(SecurityManager.java:322)
> >>>      at java.base/java.lang.System.getenv(System.java:999)
> >>>      at
> >>> java.base/java.util.Properties.getFormattedTimestamp(Properties.java:1590)
> >>>      at java.base/java.util.Properties.store0(Properties.java:932)
> >>>      at java.base/java.util.Properties.store(Properties.java:921)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.StorageFactoryService$5.run(StorageFactoryService.java:369)
> >>>      at java.base/java.security.AccessController.doPrivileged(Native
> >>> Method)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.StorageFactoryService.saveServiceProperties(StorageFactoryService.java:347)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.BaseMonitor.bootService(BaseMonitor.java:1840)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.BaseMonitor.createPersistentService(BaseMonitor.java:1022)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.FileMonitor.createPersistentService(FileMonitor.java:48)
> >>>      at
> >>> org.apache.derby.iapi.services.monitor.Monitor.createPersistentService(Monitor.java:650)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection$5.run(EmbedConnection.java:4067)
> >>>      at java.base/java.security.AccessController.doPrivileged(Native
> >>> Method)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.createPersistentService(EmbedConnection.java:4061)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.createDatabase(EmbedConnection.java:2654)
> >>>      ... 15 more
> >>> ============= end nested exception, level (1) ===========
> >>> ============= begin nested exception, level (2) ===========
> >>> java.security.AccessControlException: access denied
> >>> ("java.lang.RuntimePermission" "getenv.SOURCE_DATE_EPOCH")
> >>>      at
> >>> java.base/java.security.AccessControlContext.checkPermission(AccessControlContext.java:472)
> >>>      at
> >>> java.base/java.security.AccessController.checkPermission(AccessController.java:897)
> >>>      at
> >>> java.base/java.lang.SecurityManager.checkPermission(SecurityManager.java:322)
> >>>      at java.base/java.lang.System.getenv(System.java:999)
> >>>      at
> >>> java.base/java.util.Properties.getFormattedTimestamp(Properties.java:1590)
> >>>      at java.base/java.util.Properties.store0(Properties.java:932)
> >>>      at java.base/java.util.Properties.store(Properties.java:921)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.StorageFactoryService$5.run(StorageFactoryService.java:369)
> >>>      at java.base/java.security.AccessController.doPrivileged(Native
> >>> Method)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.StorageFactoryService.saveServiceProperties(StorageFactoryService.java:347)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.BaseMonitor.bootService(BaseMonitor.java:1840)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.BaseMonitor.createPersistentService(BaseMonitor.java:1022)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.FileMonitor.createPersistentService(FileMonitor.java:48)
> >>>      at
> >>> org.apache.derby.iapi.services.monitor.Monitor.createPersistentService(Monitor.java:650)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection$5.run(EmbedConnection.java:4067)
> >>>      at java.base/java.security.AccessController.doPrivileged(Native
> >>> Method)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.createPersistentService(EmbedConnection.java:4061)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.createDatabase(EmbedConnection.java:2654)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.<init>(EmbedConnection.java:435)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver$1.run(InternalDriver.java:660)
> >>>
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver$1.run(InternalDriver.java:656)
> >>>
> >>>      at java.base/java.security.AccessController.doPrivileged(Native
> >>> Method)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver.getNewEmbedConnection(InternalDriver.java:654)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver.connect(InternalDriver.java:300)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver.connect(InternalDriver.java:967)
> >>>      at
> >>> org.apache.derby.jdbc.EmbeddedDriver.connect(EmbeddedDriver.java:125)
> >>>      at
> >>> org.apache.derby.impl.drda.Database.makeConnection(Database.java:253)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.getConnFromDatabaseName(DRDAConnThread.java:1476)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.verifyUserIdPassword(DRDAConnThread.java:1426)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.parseSECCHK(DRDAConnThread.java:3380)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.parseDRDAConnection(DRDAConnThread.java:1210)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.processCommands(DRDAConnThread.java:1010)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.run(DRDAConnThread.java:300)
> >>> ============= end nested exception, level (2) ===========
> >>> Fri Aug 06 10:14:54 AEST 2021 Thread[DRDAConnThread_2,5,main] Cleanup
> >>> action starting
> >>> java.sql.SQLException: Failed to create database 'seconddb', see the
> >>> next exception for details.
> >>>      at
> >>> org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(SQLExceptionFactory.java:115)
> >>>      at
> >>> org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(SQLExceptionFactory.java:141)
> >>>      at org.apache.derby.impl.jdbc.Util.seeNextException(Util.java:252)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.createDatabase(EmbedConnection.java:2661)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.<init>(EmbedConnection.java:435)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver$1.run(InternalDriver.java:660)
> >>>
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver$1.run(InternalDriver.java:656)
> >>>
> >>>      at java.base/java.security.AccessController.doPrivileged(Native
> >>> Method)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver.getNewEmbedConnection(InternalDriver.java:654)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver.connect(InternalDriver.java:300)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver.connect(InternalDriver.java:967)
> >>>      at
> >>> org.apache.derby.jdbc.EmbeddedDriver.connect(EmbeddedDriver.java:125)
> >>>      at
> >>> org.apache.derby.impl.drda.Database.makeConnection(Database.java:253)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.getConnFromDatabaseName(DRDAConnThread.java:1476)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.verifyUserIdPassword(DRDAConnThread.java:1426)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.parseSECCHK(DRDAConnThread.java:3380)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.parseDRDAConnection(DRDAConnThread.java:1210)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.processCommands(DRDAConnThread.java:1010)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.run(DRDAConnThread.java:300)
> >>> Caused by: ERROR XJ041: Failed to create database 'seconddb', see the
> >>> next exception for details.
> >>>      at
> >>> org.apache.derby.shared.common.error.StandardException.newException(StandardException.java:300)
> >>>      at
> >>> org.apache.derby.impl.jdbc.SQLExceptionFactory.wrapArgsForTransportAcrossDRDA(SQLExceptionFactory.java:170)
> >>>      at
> >>> org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(SQLExceptionFactory.java:75)
> >>>      ... 18 more
> >>> Caused by: ERROR XBM01: Startup failed due to an exception. See next
> >>> exception for details.
> >>>      at
> >>> org.apache.derby.shared.common.error.StandardException.newException(StandardException.java:300)
> >>>      at
> >>> org.apache.derby.iapi.services.monitor.Monitor.exceptionStartingModule(Monitor.java:743)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.BaseMonitor.bootService(BaseMonitor.java:1857)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.BaseMonitor.createPersistentService(BaseMonitor.java:1022)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.FileMonitor.createPersistentService(FileMonitor.java:48)
> >>>      at
> >>> org.apache.derby.iapi.services.monitor.Monitor.createPersistentService(Monitor.java:650)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection$5.run(EmbedConnection.java:4067)
> >>>      at java.base/java.security.AccessController.doPrivileged(Native
> >>> Method)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.createPersistentService(EmbedConnection.java:4061)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.createDatabase(EmbedConnection.java:2654)
> >>>      ... 15 more
> >>> Caused by: java.security.AccessControlException: access denied
> >>> ("java.lang.RuntimePermission" "getenv.SOURCE_DATE_EPOCH")
> >>>      at
> >>> java.base/java.security.AccessControlContext.checkPermission(AccessControlContext.java:472)
> >>>      at
> >>> java.base/java.security.AccessController.checkPermission(AccessController.java:897)
> >>>      at
> >>> java.base/java.lang.SecurityManager.checkPermission(SecurityManager.java:322)
> >>>      at java.base/java.lang.System.getenv(System.java:999)
> >>>      at
> >>> java.base/java.util.Properties.getFormattedTimestamp(Properties.java:1590)
> >>>      at java.base/java.util.Properties.store0(Properties.java:932)
> >>>      at java.base/java.util.Properties.store(Properties.java:921)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.StorageFactoryService$5.run(StorageFactoryService.java:369)
> >>>      at java.base/java.security.AccessController.doPrivileged(Native
> >>> Method)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.StorageFactoryService.saveServiceProperties(StorageFactoryService.java:347)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.BaseMonitor.bootService(BaseMonitor.java:1840)
> >>>      ... 22 more
> >>> ============= begin nested exception, level (1) ===========
> >>> java.sql.SQLException: Startup failed due to an exception. See next
> >>> exception for details.
> >>>      at
> >>> org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(SQLExceptionFactory.java:115)
> >>>      at
> >>> org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(SQLExceptionFactory.java:141)
> >>>      at org.apache.derby.impl.jdbc.Util.seeNextException(Util.java:252)
> >>>      at
> >>> org.apache.derby.impl.jdbc.TransactionResourceImpl.wrapInSQLException(TransactionResourceImpl.java:438)
> >>>      at
> >>> org.apache.derby.impl.jdbc.TransactionResourceImpl.handleException(TransactionResourceImpl.java:360)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.handleException(EmbedConnection.java:2405)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.createDatabase(EmbedConnection.java:2662)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.<init>(EmbedConnection.java:435)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver$1.run(InternalDriver.java:660)
> >>>
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver$1.run(InternalDriver.java:656)
> >>>
> >>>      at java.base/java.security.AccessController.doPrivileged(Native
> >>> Method)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver.getNewEmbedConnection(InternalDriver.java:654)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver.connect(InternalDriver.java:300)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver.connect(InternalDriver.java:967)
> >>>      at
> >>> org.apache.derby.jdbc.EmbeddedDriver.connect(EmbeddedDriver.java:125)
> >>>      at
> >>> org.apache.derby.impl.drda.Database.makeConnection(Database.java:253)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.getConnFromDatabaseName(DRDAConnThread.java:1476)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.verifyUserIdPassword(DRDAConnThread.java:1426)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.parseSECCHK(DRDAConnThread.java:3380)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.parseDRDAConnection(DRDAConnThread.java:1210)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.processCommands(DRDAConnThread.java:1010)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.run(DRDAConnThread.java:300)
> >>> Caused by: ERROR XBM01: Startup failed due to an exception. See next
> >>> exception for details.
> >>>      at
> >>> org.apache.derby.shared.common.error.StandardException.newException(StandardException.java:300)
> >>>      at
> >>> org.apache.derby.impl.jdbc.SQLExceptionFactory.wrapArgsForTransportAcrossDRDA(SQLExceptionFactory.java:170)
> >>>      at
> >>> org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(SQLExceptionFactory.java:75)
> >>>      ... 21 more
> >>> Caused by: java.security.AccessControlException: access denied
> >>> ("java.lang.RuntimePermission" "getenv.SOURCE_DATE_EPOCH")
> >>>      at
> >>> java.base/java.security.AccessControlContext.checkPermission(AccessControlContext.java:472)
> >>>      at
> >>> java.base/java.security.AccessController.checkPermission(AccessController.java:897)
> >>>      at
> >>> java.base/java.lang.SecurityManager.checkPermission(SecurityManager.java:322)
> >>>      at java.base/java.lang.System.getenv(System.java:999)
> >>>      at
> >>> java.base/java.util.Properties.getFormattedTimestamp(Properties.java:1590)
> >>>      at java.base/java.util.Properties.store0(Properties.java:932)
> >>>      at java.base/java.util.Properties.store(Properties.java:921)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.StorageFactoryService$5.run(StorageFactoryService.java:369)
> >>>      at java.base/java.security.AccessController.doPrivileged(Native
> >>> Method)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.StorageFactoryService.saveServiceProperties(StorageFactoryService.java:347)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.BaseMonitor.bootService(BaseMonitor.java:1840)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.BaseMonitor.createPersistentService(BaseMonitor.java:1022)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.FileMonitor.createPersistentService(FileMonitor.java:48)
> >>>      at
> >>> org.apache.derby.iapi.services.monitor.Monitor.createPersistentService(Monitor.java:650)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection$5.run(EmbedConnection.java:4067)
> >>>      at java.base/java.security.AccessController.doPrivileged(Native
> >>> Method)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.createPersistentService(EmbedConnection.java:4061)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.createDatabase(EmbedConnection.java:2654)
> >>>      ... 15 more
> >>> ============= end nested exception, level (1) ===========
> >>> ============= begin nested exception, level (2) ===========
> >>> java.sql.SQLException: Java exception: 'access denied
> >>> ("java.lang.RuntimePermission" "getenv.SOURCE_DATE_EPOCH"):
> >>> java.security.AccessControlException'.
> >>>      at
> >>> org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(SQLExceptionFactory.java:115)
> >>>      at
> >>> org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(SQLExceptionFactory.java:141)
> >>>      at org.apache.derby.impl.jdbc.Util.seeNextException(Util.java:252)
> >>>      at org.apache.derby.impl.jdbc.Util.javaException(Util.java:274)
> >>>      at
> >>> org.apache.derby.impl.jdbc.TransactionResourceImpl.wrapInSQLException(TransactionResourceImpl.java:444)
> >>>      at
> >>> org.apache.derby.impl.jdbc.TransactionResourceImpl.wrapInSQLException(TransactionResourceImpl.java:439)
> >>>      at
> >>> org.apache.derby.impl.jdbc.TransactionResourceImpl.handleException(TransactionResourceImpl.java:360)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.handleException(EmbedConnection.java:2405)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.createDatabase(EmbedConnection.java:2662)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.<init>(EmbedConnection.java:435)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver$1.run(InternalDriver.java:660)
> >>>
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver$1.run(InternalDriver.java:656)
> >>>
> >>>      at java.base/java.security.AccessController.doPrivileged(Native
> >>> Method)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver.getNewEmbedConnection(InternalDriver.java:654)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver.connect(InternalDriver.java:300)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver.connect(InternalDriver.java:967)
> >>>      at
> >>> org.apache.derby.jdbc.EmbeddedDriver.connect(EmbeddedDriver.java:125)
> >>>      at
> >>> org.apache.derby.impl.drda.Database.makeConnection(Database.java:253)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.getConnFromDatabaseName(DRDAConnThread.java:1476)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.verifyUserIdPassword(DRDAConnThread.java:1426)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.parseSECCHK(DRDAConnThread.java:3380)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.parseDRDAConnection(DRDAConnThread.java:1210)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.processCommands(DRDAConnThread.java:1010)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.run(DRDAConnThread.java:300)
> >>> Caused by: ERROR XJ001: Java exception: 'access denied
> >>> ("java.lang.RuntimePermission" "getenv.SOURCE_DATE_EPOCH"):
> >>> java.security.AccessControlException'.
> >>>      at
> >>> org.apache.derby.shared.common.error.StandardException.newException(StandardException.java:300)
> >>>      at
> >>> org.apache.derby.impl.jdbc.SQLExceptionFactory.wrapArgsForTransportAcrossDRDA(SQLExceptionFactory.java:170)
> >>>      at
> >>> org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(SQLExceptionFactory.java:75)
> >>>      ... 23 more
> >>> Caused by: java.security.AccessControlException: access denied
> >>> ("java.lang.RuntimePermission" "getenv.SOURCE_DATE_EPOCH")
> >>>      at
> >>> java.base/java.security.AccessControlContext.checkPermission(AccessControlContext.java:472)
> >>>      at
> >>> java.base/java.security.AccessController.checkPermission(AccessController.java:897)
> >>>      at
> >>> java.base/java.lang.SecurityManager.checkPermission(SecurityManager.java:322)
> >>>      at java.base/java.lang.System.getenv(System.java:999)
> >>>      at
> >>> java.base/java.util.Properties.getFormattedTimestamp(Properties.java:1590)
> >>>      at java.base/java.util.Properties.store0(Properties.java:932)
> >>>      at java.base/java.util.Properties.store(Properties.java:921)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.StorageFactoryService$5.run(StorageFactoryService.java:369)
> >>>      at java.base/java.security.AccessController.doPrivileged(Native
> >>> Method)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.StorageFactoryService.saveServiceProperties(StorageFactoryService.java:347)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.BaseMonitor.bootService(BaseMonitor.java:1840)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.BaseMonitor.createPersistentService(BaseMonitor.java:1022)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.FileMonitor.createPersistentService(FileMonitor.java:48)
> >>>      at
> >>> org.apache.derby.iapi.services.monitor.Monitor.createPersistentService(Monitor.java:650)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection$5.run(EmbedConnection.java:4067)
> >>>      at java.base/java.security.AccessController.doPrivileged(Native
> >>> Method)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.createPersistentService(EmbedConnection.java:4061)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.createDatabase(EmbedConnection.java:2654)
> >>>      ... 15 more
> >>> ============= end nested exception, level (2) ===========
> >>> ============= begin nested exception, level (3) ===========
> >>> ERROR XJ001: Java exception: 'access denied
> >>> ("java.lang.RuntimePermission" "getenv.SOURCE_DATE_EPOCH"):
> >>> java.security.AccessControlException'.
> >>>      at
> >>> org.apache.derby.shared.common.error.StandardException.newException(StandardException.java:300)
> >>>      at
> >>> org.apache.derby.impl.jdbc.SQLExceptionFactory.wrapArgsForTransportAcrossDRDA(SQLExceptionFactory.java:170)
> >>>      at
> >>> org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(SQLExceptionFactory.java:75)
> >>>      at
> >>> org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(SQLExceptionFactory.java:141)
> >>>      at org.apache.derby.impl.jdbc.Util.seeNextException(Util.java:252)
> >>>      at org.apache.derby.impl.jdbc.Util.javaException(Util.java:274)
> >>>      at
> >>> org.apache.derby.impl.jdbc.TransactionResourceImpl.wrapInSQLException(TransactionResourceImpl.java:444)
> >>>      at
> >>> org.apache.derby.impl.jdbc.TransactionResourceImpl.wrapInSQLException(TransactionResourceImpl.java:439)
> >>>      at
> >>> org.apache.derby.impl.jdbc.TransactionResourceImpl.handleException(TransactionResourceImpl.java:360)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.handleException(EmbedConnection.java:2405)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.createDatabase(EmbedConnection.java:2662)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.<init>(EmbedConnection.java:435)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver$1.run(InternalDriver.java:660)
> >>>
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver$1.run(InternalDriver.java:656)
> >>>
> >>>      at java.base/java.security.AccessController.doPrivileged(Native
> >>> Method)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver.getNewEmbedConnection(InternalDriver.java:654)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver.connect(InternalDriver.java:300)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver.connect(InternalDriver.java:967)
> >>>      at
> >>> org.apache.derby.jdbc.EmbeddedDriver.connect(EmbeddedDriver.java:125)
> >>>      at
> >>> org.apache.derby.impl.drda.Database.makeConnection(Database.java:253)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.getConnFromDatabaseName(DRDAConnThread.java:1476)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.verifyUserIdPassword(DRDAConnThread.java:1426)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.parseSECCHK(DRDAConnThread.java:3380)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.parseDRDAConnection(DRDAConnThread.java:1210)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.processCommands(DRDAConnThread.java:1010)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.run(DRDAConnThread.java:300)
> >>> Caused by: java.security.AccessControlException: access denied
> >>> ("java.lang.RuntimePermission" "getenv.SOURCE_DATE_EPOCH")
> >>>      at
> >>> java.base/java.security.AccessControlContext.checkPermission(AccessControlContext.java:472)
> >>>      at
> >>> java.base/java.security.AccessController.checkPermission(AccessController.java:897)
> >>>      at
> >>> java.base/java.lang.SecurityManager.checkPermission(SecurityManager.java:322)
> >>>      at java.base/java.lang.System.getenv(System.java:999)
> >>>      at
> >>> java.base/java.util.Properties.getFormattedTimestamp(Properties.java:1590)
> >>>      at java.base/java.util.Properties.store0(Properties.java:932)
> >>>      at java.base/java.util.Properties.store(Properties.java:921)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.StorageFactoryService$5.run(StorageFactoryService.java:369)
> >>>      at java.base/java.security.AccessController.doPrivileged(Native
> >>> Method)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.StorageFactoryService.saveServiceProperties(StorageFactoryService.java:347)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.BaseMonitor.bootService(BaseMonitor.java:1840)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.BaseMonitor.createPersistentService(BaseMonitor.java:1022)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.FileMonitor.createPersistentService(FileMonitor.java:48)
> >>>      at
> >>> org.apache.derby.iapi.services.monitor.Monitor.createPersistentService(Monitor.java:650)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection$5.run(EmbedConnection.java:4067)
> >>>      at java.base/java.security.AccessController.doPrivileged(Native
> >>> Method)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.createPersistentService(EmbedConnection.java:4061)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.createDatabase(EmbedConnection.java:2654)
> >>>      ... 15 more
> >>> ============= end nested exception, level (3) ===========
> >>> ============= begin nested exception, level (4) ===========
> >>> java.security.AccessControlException: access denied
> >>> ("java.lang.RuntimePermission" "getenv.SOURCE_DATE_EPOCH")
> >>>      at
> >>> java.base/java.security.AccessControlContext.checkPermission(AccessControlContext.java:472)
> >>>      at
> >>> java.base/java.security.AccessController.checkPermission(AccessController.java:897)
> >>>      at
> >>> java.base/java.lang.SecurityManager.checkPermission(SecurityManager.java:322)
> >>>      at java.base/java.lang.System.getenv(System.java:999)
> >>>      at
> >>> java.base/java.util.Properties.getFormattedTimestamp(Properties.java:1590)
> >>>      at java.base/java.util.Properties.store0(Properties.java:932)
> >>>      at java.base/java.util.Properties.store(Properties.java:921)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.StorageFactoryService$5.run(StorageFactoryService.java:369)
> >>>      at java.base/java.security.AccessController.doPrivileged(Native
> >>> Method)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.StorageFactoryService.saveServiceProperties(StorageFactoryService.java:347)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.BaseMonitor.bootService(BaseMonitor.java:1840)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.BaseMonitor.createPersistentService(BaseMonitor.java:1022)
> >>>      at
> >>> org.apache.derby.impl.services.monitor.FileMonitor.createPersistentService(FileMonitor.java:48)
> >>>      at
> >>> org.apache.derby.iapi.services.monitor.Monitor.createPersistentService(Monitor.java:650)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection$5.run(EmbedConnection.java:4067)
> >>>      at java.base/java.security.AccessController.doPrivileged(Native
> >>> Method)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.createPersistentService(EmbedConnection.java:4061)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.createDatabase(EmbedConnection.java:2654)
> >>>      at
> >>> org.apache.derby.impl.jdbc.EmbedConnection.<init>(EmbedConnection.java:435)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver$1.run(InternalDriver.java:660)
> >>>
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver$1.run(InternalDriver.java:656)
> >>>
> >>>      at java.base/java.security.AccessController.doPrivileged(Native
> >>> Method)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver.getNewEmbedConnection(InternalDriver.java:654)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver.connect(InternalDriver.java:300)
> >>>      at
> >>> org.apache.derby.iapi.jdbc.InternalDriver.connect(InternalDriver.java:967)
> >>>      at
> >>> org.apache.derby.jdbc.EmbeddedDriver.connect(EmbeddedDriver.java:125)
> >>>      at
> >>> org.apache.derby.impl.drda.Database.makeConnection(Database.java:253)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.getConnFromDatabaseName(DRDAConnThread.java:1476)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.verifyUserIdPassword(DRDAConnThread.java:1426)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.parseSECCHK(DRDAConnThread.java:3380)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.parseDRDAConnection(DRDAConnThread.java:1210)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.processCommands(DRDAConnThread.java:1010)
> >>>      at
> >>> org.apache.derby.impl.drda.DRDAConnThread.run(DRDAConnThread.java:300)
> >>> ============= end nested exception, level (4) ===========
> >>> Cleanup action completed
> >>> Fri Aug 06 10:14:54 AEST 2021 Thread[DRDAConnThread_2,5,main]
> >>> (DATABASE = seconddb), (DRDAID = {1}), Failed to create database
> >>> 'seconddb', see the next exception for details.
> >>> Fri Aug 06 10:14:54 AEST 2021 Thread[DRDAConnThread_2,5,main]
> >>> (DATABASE = seconddb), (DRDAID = {1}), Startup failed due to an
> >>> exception. See next exception for details.
> >>> Fri Aug 06 10:14:54 AEST 2021 Thread[DRDAConnThread_2,5,main]
> >>> (DATABASE = seconddb), (DRDAID = {1}), Java exception: 'access denied
> >>> ("java.lang.RuntimePermission" "getenv.SOURCE_DATE_EPOCH"):
> >>> java.security.AccessControlException'.
> >>>
> >>> On Fri, 6 Aug 2021 at 02:55, Rick Hillegas <rick.hille...@gmail.com>
> >>> wrote:
> >>>> That does look like the problem discussed in the email thread you
> >>>> cited:
> >>>> http://apache-database.10148.n7.nabble.com/Derby-newbie-error-seen-creating-seconddb-thru-ij-for-network-server-Derby-td150684.html
> >>>>
> >>>>
> >>>> Can you post the stack trace?
> >>>>
> >>>> Thanks,
> >>>> -Rick
> >>>>
> >>>> On 8/5/21 7:51 AM, Art O Cathain wrote:
> >>>>> Hi
> >>>>>
> >>>>> There is a very long stack trace, and the last few lines of the
> >>>>> log file are
> >>>>>
> >>>>> Cleanup action completed
> >>>>> Fri Aug 06 00:47:55 AEST 2021 Thread[DRDAConnThread_2,5,main]
> >>>>> (DATABASE = seconddb), (DRDAID = {1}), Failed to create database
> >>>>> 'seconddb', see the next exception for details.
> >>>>> Fri Aug 06 00:47:55 AEST 2021 Thread[DRDAConnThread_2,5,main]
> >>>>> (DATABASE = seconddb), (DRDAID = {1}), Startup failed due to an
> >>>>> exception. See next exception for details.
> >>>>> Fri Aug 06 00:47:55 AEST 2021 Thread[DRDAConnThread_2,5,main]
> >>>>> (DATABASE = seconddb), (DRDAID = {1}), Java exception: 'access denied
> >>>>> ("java.lang.RuntimePermission" "getenv.SOURCE_DATE_EPOCH"):
> >>>>> java.security.AccessControlException'.
> >>>>>
> >>>>> I'll post the stack trace too if you need it.
> >>>>>
> >>>>> Thanks
> >>>>>
> >>>>> Art
> >>>>>
> >>>>> On Fri, 6 Aug 2021 at 00:36, Rick Hillegas
> >>>>> <rick.hille...@gmail.com> wrote:
> >>>>>> Using Derby 10.15.2.0 and Open JDK 11 (build 11+28) on Mac OSX
> >>>>>> 11.2.3, I
> >>>>>> get good, expected results from activity 2 at
> >>>>>> https://db.apache.org/derby/docs/10.15/getstart/twwdactivity2.html
> >>>>>>
> >>>>>> Can you tell us what you see in derby.log when you run activity 2
> >>>>>> and
> >>>>>> start up the server with the following additional system properties:
> >>>>>>
> >>>>>>      -Dderby.language.logStatementText=true
> >>>>>> -Dderby.stream.error.logSeverityLevel=0
> >>>>>>
> >>>>>> Thanks,
> >>>>>> -Rick
> >>>>>>
> >>>>>>
> >>>>>> On 8/4/21 7:49 PM, Art O Cathain wrote:
> >>>>>>> I've followed the self-study tutorial in the documentation. I'm
> >>>>>>> impressed by the emphasis on getting your environment set up
> >>>>>>> correctly, clearly something that beginners would struggle with.
> >>>>>>> In Activity 2, you get the following error:
> >>>>>>>
> >>>>>>> Failed to create database 'seconddb', see the next exception for
> >>>>>>> details
> >>>>>>>
> >>>>>>> This is with Derby 10.15 and Java 11 on Ubuntu. I also tried 10.14
> >>>>>>> with the same results.
> >>>>>>>
> >>>>>>> The error can be fixed if you start the server with a permissive
> >>>>>>> security policy, for example adding the following to the startup
> >>>>>>> command
> >>>>>>>
> >>>>>>> -Djava.security.manager -Djava.security.policy=<(echo 'grant {
> >>>>>>> permission java.security.AllPermission; };')
> >>>>>>>
> >>>>>>> Interestingly, once the database has been created, you can restart
> >>>>>>> Derby without that, and it appears to work. So it might be
> >>>>>>> related to
> >>>>>>> filesystem creation permissions.
> >>>>>>>
> >>>>>>> Should the documentation be updated to add the extra argument,
> >>>>>>> or is
> >>>>>>> there a bug here?
> >>>>>>>
> >>>>>>> Art
> >>>>>>>
> >>>>>>> PS Someone else had this problem too and some solutions were
> >>>>>>> suggested:
> >>>>>>> http://apache-database.10148.n7.nabble.com/Derby-newbie-error-seen-creating-seconddb-thru-ij-for-network-server-Derby-td150684.html
> >>>>>>> - but I think someone following a getting started guide
> >>>>>>> shouldn't have
> >>>>>>> to delve into the details of security permissions.
> >
> >
>

Reply via email to