You are not logged in.
Pages: 1
Hi
I have some problem when importing from OCSNG (after GLPI and MariaDB upgrade). When I run:
sh /var/www/html/glpi/plugins/ocsinventoryng/scripts/ocsng_fullsync.sh --thread_nbr=2 --server_id=1 --nolog
this is the error:
mer 22 ago 2018, 10.12.11, CEST /var/www/html/glpi/plugins/ocsinventoryng/scripts/ocsng_fullsync.sh started
Manage delete items in OCS server #1: "ocs"
=====================================================
Thread #1: starting (1/2)
Thread #1: import computers from server: 'ocs'
Thread #1: 132 computer(s)
.DBmysql::query() in /var/www/html/glpi/inc/dbmysql.class.php line 180
*** MySQL query error:
SQL: INSERT INTO `glpi_items_operatingsystems` (`items_id`, `itemtype`, `operatingsystems_id`, `operatingsystemversions_id`, `operatingsystemservicepacks_id`, `operatingsystemarchitectures_id`, `license_number`, `license_id`, `is_dynamic`, `entities_id`, `is_recursive`, `date_creation`, `date_mod`) VALUES ('395', 'Computer', '1', '1', '1', '1', 'RBCCY-RRFQV-YFRXF-H26DJ-WTWW7', '00371-177-7872963-85111', '1', '0', '0', '2018-08-22 10:12:16', '2018-08-22 10:12:16')
Error: Duplicate entry '395-Computer-1-1' for key 'unicity'
Backtrace :
inc/dbmysql.class.php:918
inc/commondbtm.class.php:537 DBmysql->insert()
inc/commondbtm.class.php:974 CommonDBTM->addToDB()
plugins/ocsinventoryng/inc/os.class.php:258 CommonDBTM->add()
...ns/ocsinventoryng/inc/ocsprocess.class.php:1228 PluginOcsinventoryngOS::updateComputerOS()
...ins/ocsinventoryng/inc/ocsprocess.class.php:472 PluginOcsinventoryngOcsProcess::synchronizeComputer()
...s/ocsinventoryng/scripts/ocsng_fullsync.php:413 PluginOcsinventoryngOcsProcess::processComputer()
...s/ocsinventoryng/scripts/ocsng_fullsync.php:288 plugin_ocsinventoryng_importFromOcsServer()
...s/ocsinventoryng/scripts/ocsng_fullsync.php:160 SecondPass()
.DBmysql::query() in /var/www/html/glpi/inc/dbmysql.class.php line 180
*** MySQL query error:
SQL: INSERT INTO `glpi_items_operatingsystems` (`items_id`, `itemtype`, `operatingsystems_id`, `operatingsystemversions_id`, `operatingsystemservicepacks_id`, `operatingsystemarchitectures_id`, `license_number`, `license_id`, `is_dynamic`, `entities_id`, `is_recursive`, `date_creation`, `date_mod`) VALUES ('272', 'Computer', '1', '1', '1', '1', '237XB-GDJ7B-MV8MH-98QJM-24367', '00371-OEM-8992671-00437', '1', '0', '0', '2018-08-22 10:12:16', '2018-08-22 10:12:16')
Error: Duplicate entry '272-Computer-1-1' for key 'unicity'
Backtrace :
inc/dbmysql.class.php:918
inc/commondbtm.class.php:537 DBmysql->insert()
inc/commondbtm.class.php:974 CommonDBTM->addToDB()
plugins/ocsinventoryng/inc/os.class.php:258 CommonDBTM->add()
...ns/ocsinventoryng/inc/ocsprocess.class.php:1228 PluginOcsinventoryngOS::updateComputerOS()
...ins/ocsinventoryng/inc/ocsprocess.class.php:472 PluginOcsinventoryngOcsProcess::synchronizeComputer()
...s/ocsinventoryng/scripts/ocsng_fullsync.php:413 PluginOcsinventoryngOcsProcess::processComputer()
...s/ocsinventoryng/scripts/ocsng_fullsync.php:288 plugin_ocsinventoryng_importFromOcsServer()
...s/ocsinventoryng/scripts/ocsng_fullsync.php:160 SecondPass()
..DBmysql::query() in /var/www/html/glpi/inc/dbmysql.class.php line 180
*** MySQL query error:
and so on.
Any suggestion?
Thank you in advance
Massimo
Informazioni sul sistema, l'installazione e la configurazione
GLPI 9.3.0 (/glpi => /var/www/html/glpi)
Installation mode: TARBALL
Server
Operating system: Linux glpi2018 3.10.0-862.11.6.el7.x86_64 #1 SMP Tue Aug 14 21:49:04 UTC 2018 x86_64
PHP 5.6.37 apache2handler (Core, PDO, Phar, Reflection, SPL, SimpleXML, Zend OPcache, apache2handler, apc, apcu, bz2, calendar,
ctype, curl, date, dom, ereg, exif, fileinfo, filter, ftp, gd, gettext, gmp, hash, iconv, imap, json, ldap, libxml, mbstring,
mhash, mysql, mysqli, mysqlnd, openssl, pcre, pdo_mysql, pdo_sqlite, posix, session, shmop, sockets, sqlite3, standard, sysvmsg,
sysvsem, sysvshm, tokenizer, wddx, xml, xmlreader, xmlrpc, xmlwriter, xsl, zip, zlib)
Setup: max_execution_time="600" memory_limit="128M" post_max_size="8M" safe_mode="" session.save_handler="files"
upload_max_filesize="2M"
Software: Apache/2.4.6 (CentOS) PHP/5.6.37 ()
Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:60.0) Gecko/20100101 Firefox/60.0
Server Software: MariaDB Server
Server Version: 10.3.9-MariaDB
Server SQL Mode:
Parameters: glpiuser@localhost/glpidb
Host info: Localhost via UNIX socket
mysqli extension is installed
ctype extension is installed
fileinfo extension is installed
json extension is installed
mbstring extension is installed
zlib extension is installed
curl extension is installed
gd extension is installed
simplexml extension is installed
xml extension is installed
ldap extension is installed
imap extension is installed
Zend OPcache extension is installed
APCu extension is installed
xmlrpc extension is installed
CAS extension is not present
Database version seems correct (10.3.9) - Perfect!Database version seems correct (10.3.9) - Perfect!
OK/var/www/html/glpi/config : OK
OK/var/www/html/glpi/files : OK
OK/var/www/html/glpi/files/_dumps : OK
OK/var/www/html/glpi/files/_sessions : OK
OK/var/www/html/glpi/files/_cron : OK
OK/var/www/html/glpi/files/_graphs : OK
OK/var/www/html/glpi/files/_lock : OK
OK/var/www/html/glpi/files/_plugins : OK
OK/var/www/html/glpi/files/_tmp : OK
OK/var/www/html/glpi/files/_cache : OK
OK/var/www/html/glpi/files/_rss : OK
OK/var/www/html/glpi/files/_uploads : OK
OK/var/www/html/glpi/files/_pictures : OK
OK/var/www/html/glpi/files/_log : OK
Web access to files directory is protectedWeb access to files directory is protected : OK
OKSELinux mode is Disabled
Libraries
htmLawed version 1.2.4 in (/var/www/html/glpi/lib/htmlawed)
SimplePie version 1.5.1 in (/var/www/html/glpi/vendor/simplepie/simplepie/library)
TCPDF version 6.2.17 in (/var/www/html/glpi/vendor/tecnickcom/tcpdf)
michelf/php-markdown in (/var/www/html/glpi/vendor/michelf/php-markdown/Michelf)
true/punycode in (/var/www/html/glpi/vendor/true/punycode/src)
iacaml/autolink in (/var/www/html/glpi/vendor/iamcal/lib_autolink)
sabre/vobject in (/var/www/html/glpi/vendor/sabre/vobject/lib)
ocsinventoryng Name: OCS Inventory NG Version: 1.5.2 State: Enabled
Offline
Corrected in https://github.com/pluginsGLPI/ocsinven … issues/138
Offline
Pages: 1