SOLVED Response Error Multiple hosts returned for list of mac addresses

  • Solved one problem with client update. Another client got an error in fog.log: Middleware::Response Error Multiple hosts returned for list of mac addresses

    This client worked some days ago because it then updated from 0.11.4 to 0.11.5. What can be the reason for this error?

  • I feel I need to add this, so people stumbling across the post understand.

    The UNIQUE key for the hostMAC table is one key with two columns (hmMAC, hmHostID). Basically this means, a MAC cannot exist multiple times for the SAME host, but they can appear multiple times for different hosts. The idea is to allow the mac’s to show up with the hosts they reside in, but when it comes to identifying a host based on the MAC address, this becomes much more of a “no man’s land”.

    This, we hope, will not be the case for much longer. One, MAC Addresses can be spoofed (and the same mac can exist on different machines even) so we’ve kind of lost the MAC Address as a unique identifier for a host. It probably doesn’t help that it’s not uncommon for a Laptop to have 2 or 3 MAC Addresses on it. Image an organization with only 1000 laptops. That’s potentially 2000 to 3000 MAC Addresses. Now I realize the unique identifier number is extremely high (each manufacturer has a potential of 16,777,215 addresses available) but as you see you can have the same mac address on multiple systems, it’s not very good for the hometeam.

    It is uncommon to see the error itself, but when it has come up it’s usually because of a VM or TUNNEL adapter that is embedded as a part of the image. This, more or less, is where the pending filter comes in though.

    While this field was, I think, only intended to filter any incoming “pending” mac addresses, it really should be applied to any mac address and it has been made to do exactly that.

  • the fog DB does not allow for a MAC to be entered into the hostMAC table more than once, the field is marked as unique.

    This would lead me to believe that multiple MACs are associated with a single host when they should not be.

  • @pmonstad said in Response Error Multiple hosts returned for list of mac addresses:

    @Tom-Elliott No VM in my setup. I’ll check tomorrow if this issue persists on other hosts.

    there must be another host that is using a mac that is also been used by another host, so if this is actually some test installation simply try to delete all of your hosts and re-add the problematic one and try again, if this is productive with more then two clients 😄 then do it in a more pro. way 😉

    Regards X23

  • I’ve edited the title and the information to be more proper with client versioning and the error that’s being seen.

  • @Tom-Elliott No VM in my setup. I’ll check tomorrow if this issue persists on other hosts.

  • @pmonstad Is it only this one host giving the issue?

    Personally the title is NOT an “still an issue updating client” as it’s clearly telling you what the issue is. One of the mac’s on that host already exists on the system using a different hostID (whether or not that hostID is actually valid or not).

    I don’t know your systems but there are at least two causes of this. First cause is because you have some sort of virtual machine installed on the image that’s being used with the identical MAC on all of the systems receiving this image. Now I don’t know if this is the case or not, I’m just saying this is a potential cause for this issue. The fix for this is to add that mac address to the FOG Configuration Page->FOG Settings->FOG Client - Host Register->FOG_QUICKREG_PENDING_MAC_FILTER, you can add the whole mac address or a part of the mac address. Using the “partial” address (usually the first 3 or 4 hex pairs) means it is going to filter anything that matches the partial part. This is comma separated. e.g. (00:01:0F,00:02:03:04,00:05:ab:af:ad:ac).

    The second cause is from olden issues that i can’t guess on. It’s relatively simple to fix, but does require some searching on your part.

    You will need to get into the DB itself.

    Run a check on the hostMAC table looking for each MAC Address.

    It will most likely return the set.
    You could do a query like:

    SELECT hmHostID FROM hostMAC where hmMAC IN ('00:01:02:03:04:05','00:ab:ab:ab:ab:ab','ab:ff:cc:cc:dd:ee')

    It will present you with all the associated hostID’s it’s finding. Figure out which is the one you want to keep, and which are no longer relevant and delete them, usually the higher ID number is the one you want to keep.

    Hopefully this helps.

  • @Wayne-Workman No. My hosts are solely Lenovo thinkpad T400, T410, T500, T61 Used for years without FOG problems.

  • @pmonstad Do you use USB to Ethernet adapters to image with?

  • @pmonstad Hm, on time to leave office. I mean 0.11.4 and 0.11.5…

  • Where are you getting these version numbers? Current new FOG Client is 0.11.5, previous was 0.11.4.