Welcome to OCS Inventory NG community support, where you can ask questions and receive answers from other members of the community.

Please ask questions only in English or French.

Release 2.11.1 available

The official documentation can be found on http://wiki.ocsinventory-ng.org. Read it before asking your question.

MySQL error 1231 'sql_mode' 'NO_AUTO_CREATE_USER'

Dear OCS Team,

I upgraded my OCS Server from Ubuntu 18.04 to 20.04 during the last week and got the following error while trying to update the OCS server and report installed on that server : "ERROR: MySql connection problem 1231 Variable 'sql_mode' can't be set to the value of 'NO_AUTO_CREATE_USER'".

It looks and MySQL issue, but no issue with other software using the same server's DB.

The computer's client software doesn't seems to have issues to access the server's DB too ...

Any ideas regarding that issue ?

Many thanks in advance,

Best regards,

in OCS Inventory NG server for Unix by (360 points)

2 Answers

0 votes

┬┐Are you using MariaDB or MySQL (Oracle's)? Please also add the version.

According to  MySQL Documentation this mode was added on version 5.7.7. You should also check the Create Users you might have

by (760 points)
0 votes
Hi Jean,

I had this same error and I found that variable sql_mode being set to "NO_AUTO_CREATE_USER" in 5 different .php files within the OCS software.
It was set in all the following;


I removed it from all of those and the webpage starting working and connected to MySql as expected.

by (270 points)
Powered by Question2Answer