Forums | Mahara Community
Support
/
Installation problems: error relating to "trigger privileges"
12 June 2017, 22:34
Hi,
I'm trying to install Mahara 17.04.02 (latest version) and getting the following error:
Mahara: Site unavailable
Mahara requires permission to create database triggers, but is unable to do so. Please ensure that the trigger privilege has been granted to the appropriate user in your MySQL installation. For instructions on how to do this, see https://wiki.mahara.org/wiki/System_Administrator's_Guide/Granting_Trigger_Privilege
Problem is I've checked the database and the database user (dbuser) does have trigger (and all other) privileges on the database in question.
| GRANTEE | TABLE_CATALOG | TABLE_SCHEMA | PRIVILEGE_TYPE | IS_GRANTABLE |
+--------------------------+---------------+--------------+-------------------------+--------------+
| 'dbuser'@'localhost' | def | database | SELECT | NO |
| 'dbuser'@'localhost' | def | database | INSERT | NO |
| 'dbuser'@'localhost' | def | database | UPDATE | NO |
| 'dbuser'@'localhost' | def | database | DELETE | NO |
| 'dbuser'@'localhost' | def | database | CREATE | NO |
| 'dbuser'@'localhost' | def | database | DROP | NO |
| 'dbuser'@'localhost' | def | database | REFERENCES | NO |
| 'dbuser'@'localhost' | def | database | INDEX | NO |
| 'dbuser'@'localhost' | def | database | ALTER | NO |
| 'dbuser'@'localhost' | def | database | CREATE TEMPORARY TABLES | NO |
| 'dbuser'@'localhost' | def | database | LOCK TABLES | NO |
| 'dbuser'@'localhost' | def | database | EXECUTE | NO |
| 'dbuser'@'localhost' | def | database | CREATE VIEW | NO |
| 'dbuser'@'localhost' | def | database | SHOW VIEW | NO |
| 'dbuser'@'localhost' | def | database | CREATE ROUTINE | NO |
| 'dbuser'@'localhost' | def | database | ALTER ROUTINE | NO |
| 'dbuser'@'localhost' | def | database | EVENT | NO |
| 'dbuser'@'localhost' | def | database | TRIGGER | NO |
Log file error:
[DBG] 2e (lib/dml.php:157) mysqli error: [1419: You do not have the SUPER privilege and binary logging is enabled (you *might* want to use the less safe log_bin_trust_function_creators variable)] in EXECUTE("CREATE TRIGGER "testtrigger" BEFORE INSERT ON "testtable" FOR EACH ROW BEGIN END;")Command was: CREATE TRIGGER "testtrigger" BEFORE INSERT ON "testtable" FOR EACH ROW BEGIN END;
Can anyone figure out what I'm missing please?
Regards,
Remy
12 June 2017, 23:22
Hello all,
This problem has been resolved!
Turns out the problem was due to binary logging (see more information here: https://wiki.mahara.org/wiki/System_Administrator's_Guide/Granting_Trigger_Privilege).
By the way, 'log_bin' and/or 'log_bin_index' seem to be easy to miss (as I did when I first checked /etc/mysql/my.cnf) so may be best to use the search functionality in your editor.
Remy
13 June 2017, 10:58
Hello Remy,
Thanks for posting your solution. Others might find it useful if they come across the same issue.
Cheers
Kristina