Tiny Core Base > Raspberry Pi
Mariadb
MrToga:
Hello guys,
I'm currently trying to use mariadb but when I try to use sudo /urs/local/mysql/bin/mysql I get this error :
--- Code: ---ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/tmp/mysql.sock' (111)
--- End code ---
I found something here (https://sebhastian.com/mysql-error-2002/)
So I tried to run sudo /usr/local/etc/init.d/mysql start but I get this error :
--- Code: ---sudo /usr/local/etc/init.d/mysql start
Starting MariaDB.220607 08:29:03 mysqld_safe Logging to '/home/tc/mysql/data/box.err'.
220607 08:29:03 mysqld_safe Starting mariadbd daemon with databases from /home/tc/mysql/data
sh: can't kill pid 5637: No such process
--- End code ---
I also use beforehand sudo /usr/local/mysql/bin/mysqld_safe --user=root & it runs without error.
Any toughts ?
Rich:
Hi MrToga
--- Quote from: MrToga on June 07, 2022, 04:33:37 AM ---
--- Code: ---sudo /usr/local/etc/init.d/mysql start
Starting MariaDB.220607 08:29:03 mysqld_safe Logging to '/home/tc/mysql/data/box.err'.
220607 08:29:03 mysqld_safe Starting mariadbd daemon with databases from /home/tc/mysql/data
sh: can't kill pid 5637: No such process
--- End code ---
--- End quote ---
That sounds like it tried to kill a nonexistent copy of mysql so multiple copies don't get started. I think you can
ignore that. Does this show that mysql started and is running:
--- Code: ---ps aux PIPE grep mysql PIPE grep -v grep
--- End code ---
Sorry, forum error. Replace the word PIPE with the | symbol.
MrToga:
Hi Rich,
It shows 0 process containing mysql
tacpilot:
Has been a very long time since I have done any DB stuff so I will just shoot from the hip
and see if any thing hits..
* reminder that the root/admin of the DB is not the same as the root/admin of your system
* /etc/init.d/mysql start is an init script that may establish some prerequisite before actually calling mysql
* looking at the init script may help point you in the right direction
* making sure all the correct user groups are setup and all appropriate permissions are in place
* checking your logs at /home/tc/mysql/data/box.err may detail the errors more clearly hope this helps
cheers :)
MrToga:
Update :
I think i've got a problem with my plugin because when I start mysqld I get an error that said I'm missing plugin (attached files). After some research I found out that you can see the plugin loaded using mysqlcheck (plugincheck.txt) but it seems to be some variable (at the end of the file).
I've also done what tacpilot said I checked the /init.d/mysql file I change some variable in the file for basedir and datadir like this :
--- Code: --- basedir=/usr/local/mysql and datadir=/home/tc/mysql/data
--- End code ---
I also modified the my.cnf file in /usr/local/etc/mysql/my.cnf I added :
--- Code: ---[mysqld]
basedir=/usr/local/mysql
plugin_dir=/usr/local/mysql/lib/plugin
--- End code ---
I don't understand what I am missing since the mariadb knoledge basis for installation only say to start mysqld (link : https://mariadb.com/kb/en/starting-and-stopping-mariadb-automatically/)
So in the end I'm still stuck.
Any toughts ?
Navigation
[0] Message Index
[#] Next page
Go to full version