You are not logged in.
Pages: 1
Topic closed
Hello,
On my laptop (Windows 8.1, 192.168.1.103), I install Oracle Virtual Box with 2 VM : GLPI 0.85.4 (192.168.1.131) and OCS 2.1.2 (192.168.1.130).
In GLPI, I installed the last OCSInventory NG Plugin 1.1.1 but when I defined the server, I got the message : Échec de connexion à la base de données --> No connection with the database.
I think I do everything right (open the port 3306, grant command,...) because from a SSH session on the GLPI VM (192.168.1.131), I can run successfully the command :
mysql -u ocs -h 192.168.1.130 ocsweb –p
select * from hardware;
| 1 | PC-2014-07-29-15-54-03 | PC | WORKGROUP | NULL | Microsoft Windows 8.1 | 6.3.9600 | NULL | Intel(R) Core(TM) i7-3632QM CPU @ 2.20GHz [4 core(s) x64] | 2201 | 1 | 8007 | 16199 | 192.168.1.103 | NULL | NULL | NULL | 2015-07-22 11:55:27 | 2015-07-22 11:55:27 | NULL | 1 | fust | 0 | NULL | NULL | fust | 00179-60164-65257-AAOEM | T6HWD-3WHGP-8H37X-6MYDF-3C736 | OCS-NG_WINDOWS_AGENT_v2.0.2.0 | 262143 | 0 | 192.168.1.103 | 3804124D-12DD-E111-886D-B888E30E2380 | x86 64 bit |
Both GUI (GLPI + OCS) are working well, no problem at all (port 80 is ok).
I installed successfully an OCS Agent on my Laptop (192.168.1.103) and as you can see, OCS got the inventory.
Here below the PHP Log :
2015-07-23 10:01:44 [2@localhost.localdomain]
*** PHP Warning(2): mysqli::mysqli(): (HY000/2003): Can't connect to MySQL server on '192.168.1.130' (13)
Backtrace :
:
inc/dbmysql.class.php:109 mysqli->mysqli()
inc/dbmysql.class.php:78 DBmysql->connect()
plugins/ocsinventoryng/inc/dbocs.class.php:46 DBmysql->__construct()
...ins/ocsinventoryng/inc/ocsdbclient.class.php:39 PluginOcsinventoryngDBocs->__construct()
...ins/ocsinventoryng/inc/ocsserver.class.php:4193 PluginOcsinventoryngOcsDbClient->__construct()
...ins/ocsinventoryng/inc/ocsserver.class.php:4172 PluginOcsinventoryngOcsServer::getDBocs()
plugins/ocsinventoryng/inc/ocsserver.class.php:107 PluginOcsinventoryngOcsServer::checkOCSconnection()
inc/commonglpi.class.php:204 PluginOcsinventoryngOcsServer->getTabNameForItem()
plugins/ocsinventoryng/inc/ocsserver.class.php:154 CommonGLPI->addStandardTab()
inc/commonglpi.class.php:154 PluginOcsinventoryngOcsServer->defineTabs()
ajax/updatecurrenttab.php:44 CommonGLPI->defineAllTabs()
Both servers are installed with Centos 6.6
Operating system: Linux localhost.localdomain 2.6.32-504.23.4.el6.x86_64 #1 SMP Tue Jun 9 20:57:37 UTC 2015 x86_64
PHP 5.3.3 apache2handler (Core, PDO, Phar, Reflection, SPL, SimpleXML, apache2handler, bz2, calendar, ctype, curl, date, ereg,
exif, fileinfo, filter, ftp, gd, gettext, gmp, hash, iconv, json, libxml, mbstring, mysql, mysqli, openssl, pcre, pdo_mysql,
pdo_sqlite, session, shmop, sockets, sqlite3, standard, tokenizer, xml, zip, zlib)
Setup: max_execution_time="30" memory_limit="128M" post_max_size="8M" safe_mode="" session.save_handler="files"
upload_max_filesize="2M"
Software: Apache/2.2.15 (CentOS) (Apache/2.2.15 (CentOS) Server at 192.168.1.131 Port 80)
Mozilla/5.0 (Windows NT 6.3; WOW64; Trident/7.0; MAARJS; rv:11.0) like Gecko
Server Software: Source distribution
Server Version: 5.1.73
Parameters: root@localhost/glpi
Host info: Localhost via UNIX socket
Thank you for your help.
André
Last edited by andre.pache (2015-07-23 06:33:08)
Offline
Well, hum, hum, I find the problem
Under Centos in the file /etc/selinux/config
I changed SELINUX = disabled only on the OCS server
Now, I changed on the GLPI server too and the connection work well !
After changing a setting in OCS :
Tab Server in the Config part, change : TRACE_DELETED --> ON
I can go further and sorry for using the "Bug" ,...
Have a nice day
André
Offline
Offline
Pages: 1
Topic closed