MySQL error

Did you create the Database? I case you did not, do the following and/or follow this tutorial openHAB2 & MySQL persistence setup

While we are at it… maybe consider using InfluxDB instead of MySQL because this => InfluxDB+Grafana persistence and graphing

  1. Use the normal shell/terminal not openhab-karaf
  2. Fire up this command to login into your mysql server mysql -h localhost -uroot -proot
  3. Fire up this command to list all databases mysql> show databases; (Note that "mysql> is the prompt from the shell)
  4. Check if there is an openhab database, should look something like this
+--------------------+
| Database           |
+--------------------+
| information_schema |
| mysql              |
| openhab            |
| performance_schema |
+--------------------+
  1. If there is no openhab entry, create a Database with this command CREATE DATABASE openhab;