[SOLVED] How to get unionDB to write

All Union Platform questions, comments, feature requests, and bug reports.

How to get unionDB to write

Postby Seanx » Tue 25 Mar 2014 21:00

Hello, I am making a union application and decided to run a union server on my own machine.
I have it running and most things are working great, I am now however having problems with creating accounts on the database.
I did not change anything in my code, so I took a look at the derby.log file.
When I start my union server it will only start the unionDB in read only mode.
Here is the derby.log
Code: Select all
Tue Mar 25 21:28:25 CDT 2014:
Booting Derby version The Apache Software Foundation - Apache Derby - 10.8.2.2 - (1181258): instance a816c00e-0144-fc37-957c-0000020eb990
on database directory /var/union/unionDB in READ ONLY mode with class loader sun.misc.Launcher$AppClassLoader@1137792
Loaded from file:/var/union/lib/derby.jar
java.vendor=Oracle Corporation
java.runtime.version=1.7.0_51-b13
user.dir=/var/union
derby.system.home=null
Database Class Loader started - derby.database.classpath=''

I really need to be able to use the DB for my app to function properly. I am sure I am missing a setting somewhere or something simple, but I can't find it.
Any help would be appreciated.
Seanx
 
Posts: 3
Joined: Tue 25 Mar 2014 20:47

Re: How to get unionDB to write

Postby Seanx » Wed 26 Mar 2014 09:33

I did some more research and I think I need to edit my permissions.
I added the following to my java.policy file but still no luck...

Code: Select all
grant codeBase "file:/var/union/lib/derby.jar" {
  permission java.lang.RuntimePermission "createClassLoader";
  permission java.util.PropertyPermission "derby.*", "read";
  permission java.util.PropertyPermission "user.dir", "read";
  permission java.io.FilePermission "${derby.system.home}","read";
  permission java.io.FilePermission "${user.dir}${/}-",
      "read,write,delete";
  permission java.util.PropertyPermission "derby.storage.jvmInstanceId",
      "write";
  permission java.io.FilePermission "directory${/var/union/unionDB}", "read,write,delete"

};


I am still getting the same in my derby.log file:
Code: Select all
Wed Mar 26 10:12:25 CDT 2014:
Booting Derby version The Apache Software Foundation - Apache Derby - 10.8.2.2 -
(1181258): instance a816c00e-0144-fef3-0e7b-0000020f2d98
on database directory /var/union/unionDB in READ ONLY mode with class loader sun
.misc.Launcher$AppClassLoader@1137792
Loaded from file:/var/union/lib/derby.jar
java.vendor=Oracle Corporation
java.runtime.version=1.7.0_51-b13
user.dir=/var/union
derby.system.home=null
Database Class Loader started - derby.database.classpath=''

Does anyone see an error in this? Or am I looking in the wrong places?
Thanks
Seanx
 
Posts: 3
Joined: Tue 25 Mar 2014 20:47

Re: How to get unionDB to write  

Postby Seanx » Thu 27 Mar 2014 12:23

Well I got it working, although am not sure exactly what did it.
If anyone is having this problem here are some links to things I tried:
http://db.apache.org/derby/docs/10.0/manuals/develop/develop122.html
http://db.apache.org/derby/docs/10.7/devguide/cdevcsecure36595.html
http://db.apache.org/derby/docs/10.7/devguide/cdevcsecure865818.html
Sorry I cant be more specific.
Seanx
 
Posts: 3
Joined: Tue 25 Mar 2014 20:47


Return to Union Platform

Online

Users browsing this forum: No registered users and 7 guests