Error setting up Sakai

114 views
Skip to first unread message

Dan Filcek

unread,
Oct 24, 2018, 5:38:41 PM10/24/18
to Sakai Development
I am following the instructions to set up Sakai located here:


Everything checks out until I get to the startup. Tomcat comes up fine, but the portal throws a 404 error.

Looking through the logs this is the first error I see:


ERROR [main] com.zaxxer.hikari.pool.HikariPool.throwPoolInitializationException sakai - Exception during pool initialization.


java.sql.SQLException: Access denied for user 'sakaiuser'@'localhost' (using password: YES)


I set up the sakai.properties as instructed like the

## MySQL settings
username@javax
.sql.BaseDataSource=sakaiuser
password@javax
.sql.BaseDataSource=sakaipassword

# use your sakaidatabase name in the URI that starts u...@javax.sql.BaseDataSource= , below.

vendor@org
.sakaiproject.db.api.SqlService=mysql
driverClassName@javax
.sql.BaseDataSource=com.mysql.jdbc.Driver
hibernate
.dialect=org.hibernate.dialect.MySQL5InnoDBDialect
url@javax
.sql.BaseDataSource=jdbc:mysql://127.0.0.1:3306/sakaidatabase?useUnicode=true&characterEncoding=UTF-8
validationQuery@javax
.sql.BaseDataSource=select 1 from DUAL
defaultTransactionIsolationString@javax
.sql.BaseDataSource=TRANSACTION_READ_COMMITTED

Any assistance would be appreciated.

Attached is the whole catalina.out file

catalina.out

Robert Long

unread,
Oct 24, 2018, 5:55:22 PM10/24/18
to Dan Filcek, Sakai Development
Dan,

Sounds like you didn’t setup your MySQL database correctly. Ensure you follow these steps: https://confluence.sakaiproject.org/pages/viewpage.action?pageId=107906475#Sakai12installguide(source)-3.1Configuredatabase

Hope this helps!

—Bob

----
Robert E. Long
Software Engineer
Unicon, Inc.

-- 
You received this message because you are subscribed to the Google Groups "Sakai Development" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sakai-dev+...@apereo.org.
To post to this group, send email to saka...@apereo.org.
Visit this group at https://groups.google.com/a/apereo.org/group/sakai-dev/.
<catalina.out>

Dan Filcek

unread,
Oct 24, 2018, 6:11:07 PM10/24/18
to Sakai Development, dr....@gmail.com
Bob,

Thanks for the link, those are the same instructions as the link I posted above, and I setup my database according to what is listed there.

mysql> select DISTINCT User, Host from mysql.user;
+------------------+-----------+
| User             | Host      |
+------------------+-----------+
| sakaiuser        | 127.0.0.1 |
| debian-sys-maint | localhost |
| mysql.session    | localhost |
| mysql.sys        | localhost |
| root             | localhost |
| sakaiuser        | localhost |
+------------------+-----------+


Robert Long

unread,
Oct 24, 2018, 6:17:45 PM10/24/18
to Dan Filcek, Sakai Development
Dan,

Are you able to connect to the "sakaidatabase” database with “sakaiuser” & “sakaipassword" credentials on localhost via the command line?

—Bob

----
Robert E. Long
Software Engineer
Unicon, Inc.

Dan Filcek

unread,
Oct 24, 2018, 6:20:43 PM10/24/18
to Sakai Development, dr....@gmail.com
sudo mysql -u sakaiuser -p
Enter password:
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 30
Server version: 5.7.24-0ubuntu0.18.10.1 (Ubuntu)

Copyright (c) 2000, 2018, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates
. Other names may be trademarks of their respective
owners
.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql
> SHOW Databases;
+--------------------+
| Database           |
+--------------------+
| information_schema |
| sakaidatabase      |
+--------------------+
2 rows in set (0.00 sec)

Dan Filcek

unread,
Oct 24, 2018, 6:21:31 PM10/24/18
to Sakai Development, dr....@gmail.com
Yes, it looks like that is fine.

Robert Long

unread,
Oct 24, 2018, 6:29:56 PM10/24/18
to Dan Filcek, Sakai Development
Dan,

Total shot in the dark here, but it appears you have trailing whitespace at the end of the password line:

pass...@javax.sql.BaseDataSource=sakaipassword

Would you mind removing that and rebooting Tomcat?

—Bob

----
Robert E. Long
Software Engineer
Unicon, Inc.

Dan Filcek

unread,
Oct 24, 2018, 7:10:18 PM10/24/18
to Sakai Development
Bob,

Thank you, removing the whitespace, did help, however, the same process
threw another error about the PDT timezone not being correct. I followed
the instruction here: https://gist.github.com/Sharabaddin/9d3ba65785e89624068cc99877a7f2c5
, hoping that it would fix that error, now I have a third error from the
same process:


ERROR [main] com.zaxxer.hikari.pool.HikariPool.throwPoolInitializationException
sakai - Exception during pool initialization.

com.mysql.cj.jdbc.exceptions.CommunicationsException: Communications link
failure



trying to restart mysql gives this error:
sudo service mysql restart
Job for mysql.service failed because the control process exited with error
code.
See "systemctl status mysql.service" and "journalctl -xe" for details.

systemctl status mysql.service
● mysql.service - MySQL Community Server
Loaded: loaded (/lib/systemd/system/mysql.service; enabled; vendor preset
:
Active: deactivating (stop-sigterm) (Result: exit-code) since Wed 2018-10
-
Process: 48037 ExecStart=/usr/sbin/mysqld --daemonize --pid-file=/run/
mysql
Process: 48013 ExecStartPre=/usr/share/mysql/mysql-systemd-start pre (code
=
Main PID: 4716 (code=exited, status=0/SUCCESS)
Tasks: 1 (limit: 3356)
Memory: 12.3M
CGroup: /system.slice/mysql.service
└─48039 [mysqld]

Oct 24 16:06:16 muj0-pc systemd[1]: Starting MySQL Community Server...
Oct 24 16:06:17 muj0-pc mysqld[48037]: Initialization of mysqld failed: 0
Oct 24 16:06:17 muj0-pc systemd[1]: mysql.service: Control process exited,
co
Oct 24 16:06:18 muj0-pc systemd[1]: mysql.service: Failed with result
'exit-c
Oct 24 16:06:18 muj0-pc systemd[1]: Failed to start MySQL Community Server.






Dan Filcek

unread,
Oct 25, 2018, 11:23:48 AM10/25/18
to Sakai Development
I fixed this last error by following this website:


Thank you again for your assistance.

Dan Filcek

Robert Long

unread,
Oct 25, 2018, 11:41:17 AM10/25/18
to Dan Filcek, Sakai Development
Dan,

I’m glad to hear you got it all sorted!

I looped the Sakai Dev list back in, just in case someone runs into your second issue.

—Bob

----
Robert E. Long
Software Engineer
Unicon, Inc.

Sanghyun Jeon

unread,
Mar 27, 2019, 4:06:13 PM3/27/19
to Dan Filcek, Sakai Development
Hello Dan and Sakai developers,

We are using Sakai 12.x, mysql 5.7.25 with mysql-connector-java-8.0.15 and openjdk 1.8.0_201

We had a similar issue about the PDT timezone not being correct. so I added America/Los_Angeles in my.cnf.
Now the error is gone. My server timezone is correct and mysql timezone is also correct.
However, I notice that SAKAI_SESSION and SAKAI_EVENT table timezone are using UTC rather than our local time.

However, SAKAI_EVENT and SESSION timestamp are not changed.

This is new thing to us. This is our first time using openjdk. 
All other servers with java, mysql 5.6, mysql-connector-java-5.1.43 are working fine. 
I am about to revert to lowever version of mysql connector-java which is not ideal.
Any insight would be greatly appreciated.

Best,

S
 

Reply all
Reply to author
Forward
0 new messages