Page 1 of 1

How to find the type of database i installed openkm on

PostPosted:Fri Aug 20, 2021 6:00 pm
by akalsteni68
Hi there
I installed openkm 6.3.7 community edition a long time ago and i don't remember what kind of database i used for the installation.
Now i want to know the type of database that my openkm is currently using.
How to find that ?
thanks in advance.

Re: How to find the type of database i installed openkm on

PostPosted:Fri Aug 20, 2021 6:52 pm
by jllort
Take a look at tomcat-XXX/conf/server.xml -> there's set the connection to the database. For example, in case of MySQL should see something like:
Code: Select all
<Resource name="jdbc/OpenKMDS" auth="Container" type="javax.sql.DataSource"
          maxActive="100" maxIdle="30" maxWait="10000" validationQuery="select 1"
          username="openkm" password="*secret*" driverClassName="com.mysql.jdbc.Driver"
          url="jdbc:mysql://localhost:3306/okmdb?autoReconnect=true&amp;useUnicode=true&amp;characterEncoding=UTF8"/>

Re: How to find the type of database i installed openkm on

PostPosted:Wed Oct 06, 2021 2:33 pm
by enpingado
I have the same question. I installed openkm many moons ago on ubuntu 16.

I don't seem to have mysql installed.

The only package i see after grep with sql is: libsqlite3-0:amd64
My server.xml is this:
Code: Select all
<Resource name="jdbc/OpenKMDS" auth="Container" type="javax.sql.DataSource"
          maxActive="100" maxIdle="30" maxWait="10000" validationQuery="select 1 from INFORMATION_SCHEMA.SYSTEM_USERS"
          username="sa" password="" driverClassName="org.hsqldb.jdbcDriver"
          url="jdbc:hsqldb:${catalina.base}/repository/okmdb"/>
I see hsqldb.
I am not familiar with that. Is there a mysql like command line tool to back up the db?

Re: How to find the type of database i installed openkm on

PostPosted:Thu Oct 07, 2021 10:16 am
by bombbie
I have same question after installed openkm-6.3.10 then not sure type database? and how to open database or access ?
attachfile image server.xml from tomcat folder

Re: How to find the type of database i installed openkm on

PostPosted:Sat Oct 09, 2021 6:30 pm
by jllort
hi bombbie, bad news you are using H2 database and this database should not be used in production. If you have data into, should export in the file system ( Administration > tools > repository export ) , switch to mysql or mariadb and then import.

To swich to mysql must:
1- stop openkm
2- create empty database ( https://docs.openkm.com/kcenter/view/ok ... riadb.html )
3- set hibernate.hbml value to "create" in the OpenKM.cfg
4- delete the folder tomcat-XXX/repository
5- start OpenKM

Before doing this action I suggest do a backup of the application in your case is quite easy:
1- stop OpenKM
2- Copy entire tomcat-XXXX folder ( you have everything into because are using H2 database )