Tiny Core Base > Raspberry Pi
Mariadb
Rich:
Hi MrToga
--- Quote from: MrToga on June 08, 2022, 10:23:26 AM --- ... And with Rich's solution I don't have /var/lib/mysql/ directory ...
--- End quote ---
The rm command was just in case mysql had created any files there.
--- Quote from: MrToga on June 07, 2022, 04:33:37 AM --- ... I also use beforehand sudo /usr/local/mysql/bin/mysqld_safe --user=root & it runs without error.
--- End quote ---
That's basically what it says to do here:
http://tinycorelinux.net/13.x/armv7/tcz/mariadb.tcz.info
tacpilot:
Server errors forcing this across multiple posts..
Core concepts to understand.
System users and mysql users are not the same..
They can be the same name but, their scope of authority are not the same.
Mariadb is installed on the system and needs to be run as a user.
It is recommended to Not run it as system root and is most often run as mysql
If the system user mysql was not be created automatically then adding it manually is required
tacpilot:
this forum is ridiculous .. taking 20 mins for a simple reply due to server errors ..
will continue in a bit before I get banned for DOS
tacpilot:
set this user in your /etc/ init.d/mysql
In that script and make sure mysql starts with mysql user
--- Code: ---su - mysql -s /bin/bash -c "mysqld_safe > /dev/null &"
--- End code ---
tacpilot:
Now create the path for where your DB will reside
and set user permissions
--- Code: ---mkdir -p /home/tc/mysql/data
sudo chown mysql:mysql /home/tc/mysql/data
sudo chmod 750 /home/tc/mysql/data
--- End code ---
This should get your system inline to run mysql
You can have many databases on a system and
each one can have its own authenticated user base and admins
Data base users and admins are configured through mysql
Now you need to create and activate a database
--- Code: ---sudo mysql_install_db --user=mysql --basedir=/usr/local/mysql --ldata=/home/tc/mysql/data
--- End code ---
The error log shows there may be path and/or command conflicts that may need further attention.
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version