Indeed the error 500 is caused immediately when the default user credentials are changed as per the instructions on https://wiki.ocsinventory-ng.org/09.Extras/Secure-your-OCS-Inventory-NG-Server/. There are five lines mentioned where the ocs database users credentials are listed and can be manually changed, two of which appear to conflict with the other three.
Unfortunately, like 99.999 % of sysadmins, I am not a full-stack programmer so debugging a couple of hundred perl and php files when the answer might be in some unknowable database table is beyond me. Support here consists mostly ignoring the question or posturing about how dumb the user must be if they can't work it out themself. If anyone really does know this product well and would like to explain an appropriate fix for the question OP asked I'd be glad to have it explained by a professional.
The information on https://wiki.ocsinventory-ng.org/09.Extras/Secure-your-OCS-Inventory-NG-Server/ says to do the following. This causes the error 500.
db=ocsweb
SET PASSWORD FOR 'ocs'@'localhost' = PASSWORD ('ocsocsocsocs');
vi /usr/share/ocsinventory-reports/ocsreports/var.php ..
180 define('DFT_DB_CMPT', 'ocs');
181 define('DFT_DB_PSWD', 'ocsocsocsocs');
vi /etc/apache2/conf-available/z-ocsinventory-server.conf
31 PerlSetVar OCS_DB_PWD ocsocsocsocs
57 # PerlSetVar OCS_DB_SL_PWD ocsocsocsocs
vi /etc/ocsinventory-reports/dbconfig.inc.php
7 define("PSWD_BASE","ocsocsocsocs");
Restart apache2
Restart the database
Test on 2050
AGENT => Sending Prolog
ERROR *** AGENT => Failed to send Prolog <HTTP Status Code #500>
and this is just the password, no messing around with the actual user name.
Now I'm sure there's some simple explanation, but there are so many possibilities that looking for, and testing, every plausible option is too time consuming. This is exactly what (other) user support forums are supposed to be for.
/rant?