v10.1.191-224
 2

🐘 The LEDE Stable MariaDB 10 package
 

It is important that you use ext-root, before you install, since MariaDB is space hungry. If you want to move the defaults, it requires you to program with it. The info is at the bottom. The defaults are the Linux defaults /var/lib/mysql.

You can read about ext-root at:
https://pages.corifeus.com/github/lede-insomnia/docs/ext-root.html

The feed 

Tested on Linksys WRT 

http://cdn.corifeus.com/lede/17.01.4/packages/arm_cortex-a9_vfpv3/mariadb

src/gz reboot_mariadb http://cdn.corifeus.com/lede/17.01.4/packages/arm_cortex-a9_vfpv3/mariadb

http://cdn.corifeus.com/lede/17.01.4/packages/mipsel_24kc/mariadb

src/gz reboot_mariadb http://cdn.corifeus.com/lede/17.01.4/packages/mipsel_24kc/mariadb

RPI-3 

http://cdn.corifeus.com/lede/17.01.4/packages/arm_cortex-a53_neon-vfpv4/mariadb/

src/gz reboot_mariadb http://cdn.corifeus.com/lede/17.01.4/packages/arm_cortex-a53_neon-vfpv4/mariadb

Built packages 

The router service 

Please, where you can find it in LEDE-INSOMNIA, of course it includes init.d service as well.

This is if you have ext-root or enough NAND. :)

# it is important that you might have a conflict if you use 
# some client like php, python or any other mysql client
# libmysqlclient or libmysqlclient-r , so
opkg remove libmysqlclient libmysqlclient-r
opkg update
opkg install mariadb-server-extra libmariadbclient mariadb-client-extra 
mysql_install_db --force --basedir=/usr
/etc/init.d/mysql stop|start

Your own build 

cp feeds.conf.default feeds.conf
echo 'src-git mariadb https://github.com/patrikx3/lede-mariadb.git' >> feeds.conf
./scripts/feeds update -a
./scripts/feeds install -a
./scripts/feeds update mariadb
./scripts/feeds install -a -p  mariadb


# create a .config
# the default is LITE
make menuconfig

# might need as well
make kernel_menuconfig

# either
# -j9 can be the number of cores + 1 
# (some programs are not using now, so add one more, I got 8 core)
make package/feeds/mariadb/mariadb/{clean,prepare,compile} package/index V=s -j9

# or
make V=s

Bulding info 

This is based on: https://github.com/openwrt/packages/pull/4221 and later https://github.com/openwrt/packages/pull/5851 .

It will be in all of my LEDE-INSOMNIA.

CPU type 

Right now, I only test on ARM (Linksys WRT1200ACS, Linksys 3200ACM) and D-Link DIR 860l B1 RAMIPS since it is 5.5.

Change the data location 

The defaults are /opt/var/lib/mysql and /opt/var/lib/mysql-tmp (auto created), but you can configure at /etc/mysql/my.cnf and /etc/init.d/mariadb. So, if you move the DB location, then you must change /etc/init.d/mariadb as well as my.cnf together, since right now it is a symlink. The built-in is /var/lib/mysql, that, you can't change right now, but LEDE puts it into the ROM, so I created a symlink for /var/lib/mysql to /opt/var/lib/mysql. That's all.

Given that lots of small devices expect /var/lib/mysql in the ROM and you have a different setup, please do not use /var/lib/mysql, otherwise you have to work on it more, but of course if you change the my.cnf and /etc/init.d/mariadb any setup can be configured at will.

Based on 

https://github.com/openwrt/packages/pull/4221 (Mariadb 5.5)
and later
https://github.com/openwrt/packages/pull/5851 (Mariadb 10.1) / https://github.com/micmac1/packages/tree/mariadb/utils/mariadb

Lede vs OpenWrt 

https://github.com/openwrt/packages/pull/5851#issuecomment-379456277

lede Elephant
aes-folderangular-compilecorifeuscorifeus-app-server-patrikx3corifeus-app-web-pagescorifeus-buildercorifeus-builder-angularcorifeus-servercorifeus-server-deployercorifeus-utilscorifeus-webcorifeus-web-materialdocker-debian-testing-mongodb-stabledocker-registry-clientfreenomgrunt-p3x-expresshtml-pdflede-insomnialede-mariadblede-redisnpm-registryonenoteopenwrt-insomniaopenwrt-mariadbopenwrt-redisramdiskredis-commandersystemd-managertools