OpenWrt 22.03.0-rc4 - Mariadb Install Error

Hi Guys.

I got an error installing mariadb-server on Openwrt 22.03.0-rc4

2022-07-09 16:20:34 0 [Warning] Could not open mysql.plugin table: "Table 'mysql.plugin' doesn't exist". Some options may be missing from the help text
service not enabled in /etc/config/mysqld

I get the same error using the release version of openwrt 22.0.3. Did you ever get to the bottom of the error?

The hint here is service not enabled in /etc/config/mysqld.

I had to create some directories and use mysql_install_db. Then mariadb_server was running.

1 Like

Thanks for this. I came to the conclusion that installation (via Luci) wasn't ready for prime time but then I guess with a sql db extra work will always be required.
For the record I am running this on an x86 platform. I need to research if the installation will need alteration to provide a RW volume just for daya storage or whether I can simply make a data directory in /

Thanks for the help.

To summarise this:

Use Luci (or otherwise) to install mariadb-server and mariadb-client

Edit /etc/config/mysqld
option enabled '0' -> option enabled '1'

Edit /etc/mysql/conf.d/50-server.cnf (set up directories NOT in FLASH!!!)

datadir = /mnt/sqldata (create directory first)
tmpdir  = /tmp

Optionally comment out bind-address to allow access over the network

#bind-address 127.0.0.1

run mysql_install_db

After this you will need to run the usual command line mysql -u root (default is no password for root) and create the relevant users

You can then use mysql-workbench on Windows or Linux to connect over the LAN to edit passwords, add databases etc.
After you have created your databases remember to change the root password and if access is not required over the LAN either re-enable

bind-address 127.0.0.1

or remove/disable users with remote access, using bind-address is safer.

1 Like

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.