Hi i have a problem with my database connection when im trying to get acces to ocsreports/index.php
ERROR: MySql connection problem 1045
cAccess denied for user 'ocsuser'@'localhost' (using password: YES)
 
here is my z-ocs-inventory-server.conf
  PerlSetEnv OCS_MODPERL_VERSION 2
  # Master Database settings
  # Replace localhost by hostname or ip of MySQL server for WRITE
  PerlSetEnv OCS_DB_HOST localhost
  # Replace 3306 by port where running MySQL server, generally 3306
  PerlSetEnv OCS_DB_PORT 3306
  # Name of database
  PerlSetEnv OCS_DB_NAME ocs
  PerlSetEnv OCS_DB_LOCAL ocs
  # User allowed to connect to database
  PerlSetEnv OCS_DB_USER ocsuser
  # Password for user
  PerlSetVar OCS_DB_PWD P@SS
 
dbconfig.inc.php
<?php
define("DB_NAME", "ocs");
define("SERVER_READ","localhost");
define("SERVER_WRITE","localhost");
define("SERVER_PORT","3306");
define("COMPTE_BASE","ocsuser");
define("PSWD_BASE","P@$$0rd");
define("ENABLE_SSL","0");
define("SSL_MODE","");
define("SSL_KEY","");
define("SSL_CERT","");
define("CA_CERT","");
 
grants in mariadb
+----------------------------------------------------------------------------------------------------------------+
| Grants for ocsuser@localhost                                                                                   |
+----------------------------------------------------------------------------------------------------------------+
| GRANT USAGE ON *.* TO `ocsuser`@`localhost` IDENTIFIED BY PASSWORD 'pass_hash' |
| GRANT ALL PRIVILEGES ON `ocs`.* TO `ocsuser`@`localhost` WITH GRANT OPTION                                     |
+----------------------------------------------------------------------------------------------------------------+