update to MariaDB management

This commit is contained in:
Philip Sargent 2021-04-25 01:48:03 +01:00
parent 4e59c8791f
commit 20c42b14bf

View File

@ -246,7 +246,7 @@ While logged in at a terminal session as expo on expo.survex.,com
$ mysql -h localhost -u expo -p<password>
will get you the MariasDb command prompt: https://www.hostwinds.com/guide/how-to-use-mysql-mariadb-from-command-line/
then:
then (Note the SEMICOLONS !):
>drop database troggle;
>create database troggle;
>quit
@ -259,6 +259,21 @@ GRANT ALL PRIVILEGES ON troggle.* TO 'expo'@'localhost' IDENTIFIED BY 'somepassw
(explained on https://chartio.com/resources/tutorials/how-to-grant-all-privileges-on-a-database-in-mysql/)
(but you need to create the database too)
The GRANT ALL PRIVILEGES bit requires you to logon in to MariaDB as root. sudo doesn't cut it.
these permissions are set in a different 'info' database which usually is untouched even if database troggle gets creamed.
PERMISSIONS
https://linuxize.com/post/usermod-command-in-linux/
sudo usermod -a expo www-data
adds expo to the www-data group which is what the webserver uses, and thus so the user troggle is acting as when
running live.
sudo usermod -a expo expocvs
the expocvs group is used for git & hg
all the users should bve in this group
Running a Troggle server
------------------------