[Solved] 1.2.0 Upgrade Problem

Unimus support forum
Confab
Posts: 22
Joined: Thu Sep 14, 2017 7:08 pm

Wed Sep 20, 2017 5:16 pm

Hi,

I just upgraded to 1.2.0 and I'm getting this error :

---------------------------------------------------------------------
Failed to start Unimus

Could not connect to database - invalid encryption key.
Please fix encryption key in configuration file and restart Unimus.
---------------------------------------------------------------------

Screenshot attached.
I've tried restarting the service and rebooting the computer.
Attachments
tvnviewer_2017-09-20_12-58-15.png
tvnviewer_2017-09-20_12-58-15.png (81.74 KiB) Viewed 11451 times
User avatar
Tomas
Posts: 1206
Joined: Sat Jun 25, 2016 12:33 pm

Wed Sep 20, 2017 6:09 pm

Could you please run Unimus in debug mode - to see exact validation fail message.
Please post the resulting log here, or PM it to me.

For Linux:

Code: Select all

service unimus stop
cd /opt/unimus
java -jar Unimus.jar --logging.level.net.unimus.business.database=TRACE
For Windows:
Open 'C:\Program Files\Unimus\Unimus.l4j.ini'
On a new line, place:

Code: Select all

-Dlogging.level.net.unimus.business.database=TRACE
Save .ini file, restart Unimus service.
Logs are in 'C:\ProgramData\Unimus\log'
Confab
Posts: 22
Joined: Thu Sep 14, 2017 7:08 pm

Wed Sep 20, 2017 7:22 pm

Here is the log:

2017-09-20 13:02:41.407 INFO 4840 --- [main] net.unimus.Application : Starting Application v1.2.0 on PC000 with PID 4840 (C:\Program Files\Unimus\Unimus.exe started by PC000$ in C:\Program Files\Unimus)
2017-09-20 13:02:41.438 INFO 4840 --- [main] net.unimus.Application : The following profiles are active: together,win,jar
2017-09-20 13:02:58.172 INFO 4840 --- [main] s.b.c.e.t.TomcatEmbeddedServletContainer : Tomcat initialized with port(s): 9000 (http)
2017-09-20 13:03:20.266 INFO 4840 --- [main] s.b.c.e.t.TomcatEmbeddedServletContainer : Tomcat started on port(s): 9000 (http)
2017-09-20 13:03:20.344 INFO 4840 --- [main] n.u.s.b.boot.LoggingPathAccessibility : Checking logging subsystem
2017-09-20 13:03:20.375 INFO 4840 --- [main] n.u.s.b.boot.DatabaseConnectionCheck : Testing database connection
2017-09-20 13:03:20.641 INFO 4840 --- [main] n.u.s.bootstrap.boot.DatabaseUpdate : Connecting to database HSQL
2017-09-20 13:03:20.657 INFO 4840 --- [main] n.u.s.bootstrap.boot.DatabaseUpdate : Updating database schema
2017-09-20 13:03:23.063 INFO 4840 --- [main] n.u.s.b.boot.EncryptionKeyValidation : Validating database encryption key
2017-09-20 13:03:23.407 ERROR 4840 --- [main] net.unimus.data.crypto.StringCryptor : Decrypting a sensitive database field failed - encryption password error!
2017-09-20 13:03:23.422 WARN 4840 --- [main] n.u.s.b.boot.EncryptionKeyValidation : org.springframework.orm.jpa.JpaSystemException: Error attempting to apply AttributeConverter; nested exception is javax.persistence.PersistenceException: Error attempting to apply AttributeConverter
2017-09-20 13:03:23.422 INFO 4840 --- [main] net.unimus.Application : Started Application in 45.062 seconds (JVM running for 49.152)
2017-09-20 15:20:06.874 INFO 8884 --- [main] net.unimus.Application : Starting Application v1.2.0 on PC000 with PID 8884 (C:\Program Files\Unimus\Unimus.exe started by PC000$ in C:\Program Files\Unimus)
2017-09-20 15:20:06.889 INFO 8884 --- [main] net.unimus.Application : The following profiles are active: together,win,jar
User avatar
Tomas
Posts: 1206
Joined: Sat Jun 25, 2016 12:33 pm

Wed Sep 20, 2017 7:45 pm

The log doesn't contain the debug data :(
We should see DEBUG messages in it, but we see only INFO/WARN/ERROR.

Could you please check if the .ini file contains the proper configuration, and try restarting Unimus again.

We would also be happy to look at this with you directly (TeamViewer or something similar).
Feel free to PM me to work out the details if desired.
ineedbr
Posts: 4
Joined: Fri Mar 17, 2017 9:44 am

Thu Oct 19, 2017 9:22 am

Hi Tomas

I ahve the same issue after upgrading to 1.3.0 today, i think your are in vagas still so i dont expect a fast reply.

Malformed database config - encryption key is missing.
Please fix database encryption key in configuration file and restart Unimus.

I have tried to run debug but i can not get this to run

im happy for your to teamviewer on to the pc and take a look

Adrian
User avatar
Tomas
Posts: 1206
Joined: Sat Jun 25, 2016 12:33 pm

Thu Oct 19, 2017 9:37 am

Hi,

Your issue is a bit different than the one in the original post.

Can you please check the config file, it should continan 'database.encryption.key'.
Is the property there, and is it not empty?

Config file:
Win: 'C:\ProgramData\Unimus\unimus.properties'
Linux: '/etc/unimus/unimus.properties'
ineedbr
Posts: 4
Joined: Fri Mar 17, 2017 9:44 am

Thu Oct 19, 2017 4:33 pm

In the Unimus folder i have

nssm
Unimus.l4j config file
uninstall

Adrian
User avatar
Tomas
Posts: 1206
Joined: Sat Jun 25, 2016 12:33 pm

Thu Oct 19, 2017 4:35 pm

You need to look in 'C:\ProgramData\Unimus\', not in 'C:\Program Files\Unimus' :)
ineedbr
Posts: 4
Joined: Fri Mar 17, 2017 9:44 am

Thu Oct 19, 2017 4:42 pm

found the file and all there. key, licence etc.

Adrian
User avatar
Tomas
Posts: 1206
Joined: Sat Jun 25, 2016 12:33 pm

Thu Oct 19, 2017 4:59 pm

Fastest way would be to look at it directly.

I PMed you with more details.
Post Reply