Weird JBDC and MongoDB error

hello,

i do not use both of those persistance in my setup but i keep receiving tons of error and warning in my logs for those two (this is one cycle, it’s non-stop):

2016-11-11 14:44:32.343 [WARN ] [.m.i.MongoDBPersistenceService] - The MongoDB database URL is missing - please configure the mongodb:url parameter in openhab.cfg
2016-11-11 14:44:32.343 [WARN ] [.m.i.MongoDBPersistenceService] - The MongoDB database name is missing - please configure the mongodb:database parameter in openhab.cfg
2016-11-11 14:44:32.343 [WARN ] [.m.i.MongoDBPersistenceService] - The MongoDB database collection is missing - please configure the mongodb:collection parameter in openhab.cfg
2016-11-11 14:44:32.344 [ERROR] [.m.i.MongoDBPersistenceService] - Failed to connect to database null
2016-11-11 14:44:32.358 [ERROR] [p.j.internal.JdbcConfiguration] - JDBC::updateConfig: url The SQL database URL is missing - please configure the jdbc:url parameter in openhab.cfg
2016-11-11 14:44:32.358 [ERROR] [p.j.internal.JdbcConfiguration] - JDBC::updateConfig: url Required database url like 'jdbc:<service>:<host>[:<port>;<attributes>]' - please configure the jdbc:url parameter in openhab.cfg
2016-11-11 14:44:32.359 [WARN ] [p.j.internal.JdbcConfiguration] - JDBC::updateConfig: no Configuration for serviceName 'no' found. ClassNotFoundException: org.openhab.persistence.jdbc.db.JdbcNoDAO
2016-11-11 14:44:32.359 [ERROR] [p.j.internal.JdbcConfiguration] - JDBC::updateConfig: SQL user is missing - please configure the jdbc:user parameter in openhab.cfg
2016-11-11 14:44:32.359 [ERROR] [p.j.internal.JdbcConfiguration] - JDBC::updateConfig: SQL password is missing. Attempting to connect without password. To specify a password configure the jdbc:password parameter in openhab.cfg.
2016-11-11 14:44:32.359 [WARN ] [p.j.internal.JdbcConfiguration] - JDBC::updateConfig: try to load JDBC-driverClass: 'null'

here’s my .cfg file for those service

related JDBC

############################ SQL Persistence Service ##################################
# the database url like 'jdbc:mysql://<host>:<port>/<database>' (without quotes)
#mysql:url=

# the database user
#mysql:user=

# the database password
#mysql:password=

# the reconnection counter
#mysql:reconnectCnt=

# the connection timeout (in seconds)
#mysql:waitTimeout=

############################ JPA Persistence Service ##################################
#
# The JPA bundle includes only the embedded derby driver.
# If you want to use a different database, like PostgreSQL, just
# drop the PostgreSQL driver jhar into the 'addons' folder of openhab.
#

# connection string url
#jpa:url=jdbc:postgresql://<host>:5432/<databasename>
#jpa:jdbc:mysql://<host>:3306/<databasename>
#jpa:url=jdbc:derby://<host>:1527/<databasename>;create=true
#jpa:url=jdbc:derby:<databasename>;create=true

# driver class name
#jpa:driver=org.postgresql.Driver                   #
#jpa:driver=com.mysql.jdbc.Driver                   #
#jpa:driver=org.apache.derby.jdbc.ClientDriver      #
#jpa:driver=org.apache.derby.jdbc.EmbeddedDriver    # (included)

# username
#jpa:user=

# password
#jpa:password=

# synchronize mappings
# !!! Attention: only change those if you know what you're doing. You can wipe your table or database.
# default is: "buildSchema(schemaAction='add')"
#jpa:syncmappings=

related to mongo

############################ MongoDB Persistence Service ##################################
#
# the database URL, e.g. mongodb://127.0.0.1:27017
#mongodb:url=mongodb:

# the database name
#mongodb:database=openhab

# the collection name
#mongodb:collection=openhab

Anyone know how can i stop thoses errors to fill my log?

Well… if you don’t use these 2 Persistence Services, you should uninstall (remove) the respective bindings from the ${openhab_home}/addons folder. Find org.openhab.persistence.mongodb-1.8.3.jar & org.openhab.persistence.jpa-1.8.3.jar and remove them from your OH1 deployment.

Also, make sure that you don’t have any mongodb.persist and/or jpa.persist in your ${openhab.home}/configuration/persistence folder.

BR,
Dim

Thanks a lot for the info.

I made a nice clean up my addons folder. Lot less error and warning now.

1 Like