I am trying to connect to local mysql server I use for development
The server starts fine, but I can not connect to it as a non-root user.
[root@somepc ]# mysql -u [someuser] -p[somepass] ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (13 "Permission denied")
As root, this works as expected. So that user does have permissions to access mysql.
mysql -u [user] -p[password] Welcome to the MariaDB monitor. Commands end with ; or \g. Your MariaDB connection id is 2 Server version: 10.1.30-MariaDB MariaDB Server Copyright (c) 2000, 2017, Oracle, MariaDB Corporation Ab and others. Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
When I check the permission of as my user
stat /var/lib/mysql/mysql.sock stat: cannot stat '/var/lib/mysql/mysql.sock': Permission denied
What should these permission be for a non-root user?