On Wed, 2019-12-04 at 21:48 +0100, to...@tuxteam.de wrote: > On Wed, Dec 04, 2019 at 08:16:49PM +0100, Bjoern Schiessle wrote: > > Hi, > > > > I run the XMPP server Prosody on a Debian server which I recently > > updated to Buster. Since the update the Prosody server refuses to > > connect to the MariaDB database. The log shows following error: > > > > Nov 30 22:09:15 sql debug Connecting to [MySQL] prosody... > > Nov 30 22:09:15 sql debug Database connection was closed. Will > > reconnect and retry. > > Nov 30 22:09:15 sql debug Retrying SQL transaction > > [function(mod_storage_sql.lua:137)] > > Nov 30 22:09:15 sql debug Connecting to [MySQL] prosody... > > Nov 30 22:09:15 sql debug SQL transaction retry failed > > Nov 30 22:09:15 sql error Error in SQL transaction: > > /usr/local/share/lua/5.2/DBI.lua:53: Cannot load driver MySQL. > ^^^^^ > > Hm. This looks like a locally installed driver, not the > distribution's...
That's interesting. I didn't noticed it. A apt-file search for this file doesn't give me any result. Also no luarocks packages are installed according to "loarocks list". Maybe this come from another repository I no longer use. Is there a way to find out from which package/source the file was originally installed beside apt-file, which only works if the repository with the package is still there? > > Available drivers are: SQLite3 > > > > It looks like the MySQL driver is not installed. But both packages, > > "lua-dbi-mysql/stable,now 0.7.1-2 amd64" and "lua-sql- > > mysql/stable,now > > 2.3.4-1+b1 amd64" are installed. > > Perhaps you can play around by setting the environment variables > LUA_PATH (and/or LUA_CPATH) to have /usr/share/lua before > /usr/local/share/lua? > > Or, if you don't need the stuff in /usr/local/share/lua, perhaps > move it out of the way. I tried to move the file /usr/local/share/lua/5.2/DBI.lua away, then the error message changes to: Dec 05 11:57:35 sql error Error in SQL transaction: /usr/share/lua/5.2/DBI.lua:53: Cannot load driver MySQL. Available drivers are: PostgreSQL So now it tries to load the "official" source. But the mysql driver is still not found. What still confuses me, that the Postgresql driver installed from the Debian repository is recognized correctly. So it seems to look at the right places but something seems to be different if it comes to the mysql driver. > What's the version of Lua you're using (Buster has the whole > array from 5.0 to 5.3 on offer, it seems). I'm using Lua 5.2.4 Cheers, Bjoern