[Fusioninventory-devel] Gathering hostid on Linux
Gonéri Le Bouder
goneri at lebouder.net
Mon Dec 2 09:44:30 UTC 2013
Quoting Walid Nouh (2013-12-02 10:17:36)
> Hello FusionInventory developers,
Hello Walid,
> I've been asked for gathering the result of the HostID on Linux.
> For the moment this information is gathered on Solaris, and put in the
> OS Comment, and on Linux.
> By discussing this point with David and Gonéri, it seems that the hostid
> is not a very useful information, as it may not be unique and thus cannot
> be used as a criterias for unicity rules.
hostid returns value from libc gethostid() function. The value is more
or less the IP address of the machine:
http://linux.die.net/man/2/gethostid
This is a bit different on Solaris. The hostid is stored in the
hardware.
> I was wondering either this information needs to be dropped from the
> Solaris code or generalized on all unices. What do you think about it ?
In this case, you can use the IP address as unicity criteria.
> Would it be interested to have this information in a specific key of the
> XML inventory so it could be displayed in FI4GLPI ?
I don't think it make sense to collect such kind of information. That's
more the purpose of the Collect task: gethering specific information in
demande.
Best regards,
--
Gonéri
More information about the Fusioninventory-devel
mailing list