You are not logged in.

Announcement

 Téléchargez la dernière version stable de GLPI      -     Et vous, que pouvez vous faire pour le projet GLPI ? :  Contribuer
 Download last stable version of GLPI                      -     What can you do for GLPI ? :  Contribute

#1 2017-12-13 10:56:58

gaionim
Guest
Registered: 2017-12-13
Posts: 2

Fusioninventory detach from right port and attach to phantom hub

Hi,
I can not understand the strange behavior of the inventory.

Even though the connection is correctly identified

VAL-PC-1563 - Lan <-> SW ifc2 (Slot: 1 Port: 2)

this is  replaced by

VAL-PC-1563 - Lan <-> N / A on hub

I do not know where to look to understand where it happens, but my impression is that:

  - when the correct switch is inventoried, the right port is connected

  - when another switch is inventoried that has the mac address on a trunk port,
    a hub is generated, disconnected from the correct port and connected to a phantom hub


I've seen suggestions to enable LLPD, but I think a solution could be
DO NOT detach from port that have names to attack HUB

unfortunately I do not know where to look to try to make some changes.
I can not even find the log when it is attached to the hub

Here some data

History of Network port - ifc2 (Slot: 1 Port: 2)
20486999    06-12-2017 13:24    Plugin_FusionInventory (333)    Network port    Disconnect the item: VAL-PC-1563 - Lan (19556229)
20479529    06-12-2017 13:24    Plugin_FusionInventory (333)    Network port    Connect the item: VAL-PC-1563 - Lan (19556229)
20340942    06-12-2017 12:10    Plugin_FusionInventory (333)    Network port    Disconnect the item: VAL-PC-1563 - Lan (19556229)
20333159    06-12-2017 12:09    Plugin_FusionInventory (333)    Network port    Connect the item: VAL-PC-1563 - Lan (19556229)


Network port Computer - VAL-PC-1563    1/1    Next    Last

#     Name     Connected to     Ethernet port speed     MAC     IP addresses     IP networks

1     Lan      N/A on hub Disconnect     10 Mbit/s     90:1b:0e:4c:4d:da     10.10.70.70     10.10.0.0 / 255.255.0.0 - Lan Esine

History

20487000    06-12-2017 13:24    Plugin_FusionInventory (333)    Network port    Disconnect the item: swRackN1 - ifc2 (Slot: 1 Port: 2) (2043)
20479530    06-12-2017 13:24    Plugin_FusionInventory (333)    Network port    Connect the item: swRackN1 - ifc2 (Slot: 1 Port: 2) (2043)
20340943    06-12-2017 12:10    Plugin_FusionInventory (333)    Network port    Disconnect the item: swRackN1 - ifc2 (Slot: 1 Port: 2) (2043)
20333160    06-12-2017 12:09    Plugin_FusionInventory (333)    Network port    Connect the item: swRackN1 - ifc2 (Slot: 1 Port: 2) (2043)

Regards, Mauro

Offline

#2 2017-12-29 16:00:22

gaionim
Guest
Registered: 2017-12-13
Posts: 2

Re: Fusioninventory detach from right port and attach to phantom hub

with some line commented seems to work or at least I see more devices connected
BUT i do not know side effects.

Any suggestions ?


FusionInventory    9.2+1.0

$ diff -c inventorynetworkequipmentlib.class.php{.orig,.new} 
*** inventorynetworkequipmentlib.class.php.orig	2017-12-29 14:38:00.340748246 +0100
--- inventorynetworkequipmentlib.class.php.new	2017-12-29 14:44:31.290499176 +0100
***************
*** 520,527 ****
--- 520,529 ----
                          $networkPort->getFromDB($direct_id);
                          if ($networkPort->fields['itemtype'] == 'PluginFusioninventoryUnmanaged') {
                             // 1. Hub connected to this switch port
+                            /* Mauro
                             $pfUnmanaged->connectPortToHub(array($a_port),
                                                                $networkPort->fields['items_id']);
+                            */
                          } else {
                             // 2. direct connection
                             $directconnect = 1;
***************
*** 552,559 ****
--- 554,563 ----
                             // to this switch port
                             if ($ddirect['itemtype'] == 'PluginFusioninventoryUnmanaged') {
                                // b. We have a hub connected to the switch port
+                               /* Mauro
                                $pfUnmanaged->connectPortToHub(array($a_port),
                                                                   $ddirect['items_id']);
+                               */
                             } else {
                                // a. We have a direct connexion to another device
                                // (on the switch port)
***************
*** 562,571 ****
--- 566,577 ----
                          }
                       }
                       if ($directconnect == '1') {
+                         /* Mauro dovrebbe essere un hub, quindi non stacco niente per attaccarlo ad hub, o no ?!?
                          $pfNetworkPort->disconnectDB($networkports_id); // disconnect this port
                          $pfNetworkPort->disconnectDB($a_port['id']); // disconnect destination port
                          $wire->add(array('networkports_id_1'=> $networkports_id,
                                           'networkports_id_2' => $a_port['id']));
+                         */
                       }
                    } else if ($id) {
                       // Yet connected
***************
*** 593,601 ****
--- 599,609 ----
                    $input['mac'] = $ifmac;
                    $input['instantiation_type'] = "NetworkPortEthernet";
                    $newPortID = $networkPort->add($input);
+                   /* Mauro, non stacco da niente per attaccare ad unmanaged
                    $pfNetworkPort->disconnectDB($networkports_id); // disconnect this port
                    $wire->add(array('networkports_id_1'=> $networkports_id,
                                     'networkports_id_2' => $newPortID));
+                   */
                 }
              }
           }

Offline

#3 2018-10-23 22:03:54

fralla2
Guest
Registered: 2018-03-28
Posts: 5

Re: Fusioninventory detach from right port and attach to phantom hub

gaionim : Did you notice unwanted or strange behaviors once you commented those lines???

I'm having the same problem here and really need a fix on this. I cannot have 4000 computers disconnecting randomly to the switches and get connected to a ghost hub hahaha.

Thanks
Francois

Offline

Board footer

Powered by FluxBB