Plugin failed to access the database
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 35/100
Research direction
Begin at plugins/ocsinventoryng/inc/dbocs.class.php:97 and follow connect() from line 55, using the php-errors.log warning and the stated GLPI/OCSNG VM setup as context. Reproduce the failed connection and trace the configuration, network, and database-access behavior; done means the OCSNG plugin connects without the mysqli permission-denied warning.
Written by the indexing model from the issue text.
Description
- PLUGIN VERSION = 2.0.4
- GLPI 10.0.6
I've been trying to connect to my ocsng database via the OCSNG plugin and the plugin returns to me that it failed to connect to the database.
My current setup is two Virtual Machines running AlmaLinux 9.1 server (no gui). One running GLPI and another running OCSNG, both are on the same network
I went into the php-errors.log of GLPI and it returns this detailed Warning:
[2023-03-23 08:08:59] glpiphplog.WARNING: *** PHP Warning (2): mysqli::real_connect(): (HY000/2002): Permission denied in /var/www/html/glpi/plugins/ocsinventoryng/inc/dbocs.class.php at line 97
Backtrace :
plugins/ocsinventoryng/inc/dbocs.class.php:97 mysqli->real_connect()
plugins/ocsinventoryng/inc/dbocs.class.php:55 PluginOcsinventoryngDBocs->connect()
...ins/ocsinventoryng/inc/ocsdbclient.class.php:54 PluginOcsinventoryngDBocs->__construct()
...ins/ocsinventoryng/inc/ocsserver.class.php:1926 PluginOcsinventoryngOcsDbClient->__construct()
...ins/ocsinventoryng/inc/ocsserver.class.php:1905 PluginOcsinventoryngOcsServer::getDBocs()
...ins/ocsinventoryng/inc/snmpocslink.class.php:65 PluginOcsinventoryngOcsServer::checkOCSconnection()
src/CommonGLPI.php:382 PluginOcsinventoryngSnmpOcslink->getTabNameForItem()
plugins/ocsinventoryng/inc/ocsserver.class.php:146 CommonGLPI->addStandardTab()
src/CommonGLPI.php:332 PluginOcsinventoryngOcsServer->defineTabs()
src/Toolbox.php:3559 CommonGLPI->defineAllTabs()
ajax/updatecurrenttab.php:46 Toolbox::getAvailablesTabs()
- Dominant language
- JavaScript
- Stars
- 75
- Forks
- 54
- PR merge metrics
- No merged PRs in 30d
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from pluginsGLPI/ocsinventoryng
-
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
pluginsGLPI/ocsinventoryng#403 ·
-
Difficulty 3/5 1-2 days Newbie friendliness 35/100
pluginsGLPI/ocsinventoryng#409 ·
-
Difficulty 4/5 3-5 days Newbie friendliness 35/100
pluginsGLPI/ocsinventoryng#404 · 1 comment ·
-
Difficulty 4/5 3-5 days Newbie friendliness 35/100
pluginsGLPI/ocsinventoryng#402 ·
-
SNMP import error Open
Difficulty 3/5 1-2 days Newbie friendliness 48/100
pluginsGLPI/ocsinventoryng#401 ·
All issues in pluginsGLPI/ocsinventoryng
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
HarperFast/skills#96 ·
-
[Block] Latest Posts [Type] Bug
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Automattic/studio#4908 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 86/100
sugarlabs/musicblocks#8847 ·