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.

How to change user/password and fix error:

The default SQL  login/password is activate on your database: ocsweb

I guess i have to enter to mysql database and change something, but how?
I mean, what commands must i write so it can work? Thx!
in OCS Inventory NG server for Windows by (140 points)
retagged by

1 Answer

0 votes

connect to mysql and do  :

USE ocsweb;

DROP USER 'ocs'@'host';

CREATE USER 'user'@'host' identified by 'password';

GRANT ALL PRIVILEGES ON ocsweb.* TO 'login'@'host';

replace host by your server hostname/ip (usually localhost if ocs is on the same machine than mysql)
replace user by whatever name your want to use
replace password by whatever password you want to use

change OCS Inventory NG config files : 
- in /usr/share/ocsinventory-reports/ocsreports/dbconfig.inc.php,
change those two lines according to what you wrote earlier in mysql :

- in /etc/apache2/conf.d/z-ocsinventory-server.conf or /etc/httpd/conf.d/z-ocsinventory-server.conf,
change those two lines according to what you wrote earlier in mysql :
PerlSetEnv OCS_DB_USER user
PerlSetVar OCS_DB_PWD password

restart apache service :
sudo service apache2 restart
or sudo service httpd restart


by (640 points)
Powered by Question2Answer