Share via

Linux discovery failing with Azure Migrate

Jose Moreno 20 Reputation points
2026-03-17T09:38:13.52+00:00

I have tried two ways of discovering a Linux Ubuntu 22.04 HyperV virtual machine:

1) HyperV appliance

With the HyperV AzMigrate appliance, the appliance is not able to find the IP address of the VM, since HyperV doesn't get the IP address from the HyperV tools in the machine. The HyperV tools seem to be installed, but still the IP address doesn't show up in HyperV.

jose@linvm00-0:~$ lsmod | grep hv_utils
hv_utils               45056  0
hv_vmbus              139264  8 hv_balloon,hv_utils,hv_netvsc,hid_hyperv,hv_storvsc,hyperv_keyboard,hyperv_drm,hyperv_fb

Initially I had the VM configured with a static IP address. I moved it to DHCP, but it didn't change anything.

2) Azure Migrate Collector

I moved to the AzureMigrateCollector (disconnected appliance) and ran a bare metal server discovery. Here I got the error "Validation failed", with this explanation:

Failed to fetch BIOS GUID for the server '<PII Removed>'. BIOS GUID is important to uniquely identify and discover a server.

I run the commands in the docs page, both work successfully:

jose@linvm00-0:~$ sudo cat /sys/class/dmi/id/product_uuid
[sudo] password for jose:
<PII Removed>
jose@linvm00-0:~$ sudo dmidecode | grep -i uuid | awk '{print $2}'
<PII Removed>

I also added the recommended configuration to /etc/sudoers:

jose@linvm00-0:~$ sudo tail -2 /etc/sudoers
Defaults        !visiblepw
Defaults        !requiretty

However, the problem still persists after running the revalidate process.

Any suggestion?

Azure Migrate
Azure Migrate

A central hub of Azure cloud migration services and tools to discover, assess, and migrate workloads to the cloud.


Answer accepted by question author
  1. Bharath Y P 7,240 Reputation points Microsoft External Staff Moderator
    2026-03-17T10:40:46.6+00:00

    Hello Jose Moreno, we understand that you are trying to discover an Ubuntu 22.04 VM on Hyper-V using Azure Migrate, and facing two separate issues:

    • Hyper-V appliance discovery fails Because Hyper-V cannot retrieve the VM’s IP address.
    • Azure Migrate Collector discovery fails because of the error “Failed to fetch BIOS GUID”. Even though manual commands (dmidecode, product_uuid) work.

    Hyper-V Appliance Issue (IP Not Detected): Hyper-V depends on the KVP (Key-Value Pair Exchange) daemon (hv_kvp_daemon) inside the Linux VM to report the IP address. If this service is not running or not functioning correctly, the Hyper-V host cannot retrieve the IP. Azure Migrate queries Hyper-V, and if the host cannot obtain the IP via KVP, discovery fails.

    Azure Migrate Collector Issue (BIOS GUID Failure): The Azure Migrate Collector executes commands like dmidecode via non-interactive SSH. Even if the command works manually, it can fail during automation if:

    • The sudoers configuration does not allow passwordless execution (NOPASSWD)
    • The exact binary path is not specified
    • The system enforces requiretty, preventing non-interactive sudo execution As a result, the collector cannot retrieve the BIOS GUID and discovery fails.

    To fix Azure Migrate Collector:

    Configure sudoers correctly: Run the below command

    sudo visudo
    

    Add exactly:

    jose ALL=(ALL) NOPASSWD: /usr/sbin/dmidecode, /bin/cat /sys/class/dmi/id/product_uuid Defaults:Jose !requiretty
    

    Verify paths

    which dmidecode
    which cat
    

    Should return:

    • dmidecode > /usr/sbin/dmidecode
    • cat > /bin/cat

    Test non-interactive execution: From another machine (simulate collector):

    ssh jose@vm-ip "sudo /usr/sbin/dmidecode -s system-uuid"
    

    Must return UUID without prompting password

    Restart services

    sudo systemctl restart ssh
    

    Revalidate in Azure Migrate Collector: Run the validation again it should now pass.

    To fix Hyper-V Discovery (Optional):

    Ensure KVP daemon is running: This ensures the Hyper‑V Key‑Value Pair daemon is running, which is what reports IP addresses back to the host.

    sudo systemctl status hv-kvp-daemon
    

    If not:

    sudo systemctl restart hv-kvp-daemon
    

    Confirm synthetic NIC: you should see Microsoft Hyper-V Network Adapter. If not, the VM may be using a legacy NIC, which doesn’t support IP reporting.

    lspci | grep -i ethernet
    

    Should show: Microsoft Hyper-V Network Adapter

    Refresh DHCP lease: Forces the VM to renew its IP assignment.

    sudo dhclient -v
    

    Reboot VM: Hyper-V often updates IP only after reboot.

     

    The recommendation to Use Azure Migrate Collector (agentless). Fix sudoers with exact command paths + NOPASSWD + no TTY requirement. Do not rely on Hyper-V appliance for Linux discovery, It is inherently unreliable for IP detection on newer Linux distros

     Here are some useful documents: Discover physical servers with Azure Migrate discovery and assessment - Azure Migrate | Microsoft Learn

    Troubleshoot ongoing server discovery, software inventory, and SQL discovery - Azure Migrate | Microsoft Learn

    2 people found this answer helpful.

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.