Home › Microsoft Intune › 0x80cf4017

Microsoft Intune · 0x80cf4017 · Windows 10/11 MDM Enrollment

Microsoft Intune MDM Enrollment Error 0x80cf4017 on Windows 10/11 - DNS or Connectivity Issue

The error occurs when the MDM service URL cannot be reached due to DNS misconfiguration or network connectivity issues. Fix by correcting DNS records and ensuring Intune endpoints are reachable.

Error Details

FactValueSourceNote
Exact error stringWe could not auto-discover a management endpoint matching your username. Confirm your email address and try again, or set up manually.Windows Settings > Accounts > Access work or school > Connect->
OS build affectedWindows 10/11 MDM EnrollmentMicrosoft Intune documentation->
Relevant DNS CNAME recordenterpriseenrollment.<domain.com>Public DNS provider management consoleShould resolve to EnterpriseEnrollment-s.manage.microsoft.com
Intune service endpoint URLsEnterpriseEnrollment.contoso.com or enrollment.manage.microsoft.comMicrosoft Intune documentation->
Log file signatureEvent ID 75: 'The auto-discovery request could not be resolved'Windows Event Viewer > Applications and Services Logs > Microsoft > Windows > DeviceManagement-Enterprise-Diagnostics-Provider > Admin->

Log Files to Check

What This Error Actually Means

The error code 0x80cf4017 indicates that the Microsoft Intune Mobile Device Management (MDM) enrollment process failed due to an inability to communicate with the Intune service discovery endpoint. Specifically, this error occurs when the Windows MDM client cannot reach either EnterpriseEnrollment.contoso.com or enrollment.manage.microsoft.com during automatic or manual enrollment. The error is raised by the Device Management-Enterprise-Diagnostics-Provider component in Windows 10/11, which logs events related to MDM enrollment and configuration.

Affected Versions and Scope

This issue affects Windows 10 and Windows 11 devices attempting MDM enrollment through Intune. It is not limited to specific OS builds but can occur across various versions of Windows 10/11 when the device fails to discover the Intune service endpoint. The error does not affect devices enrolled via other methods, such as Azure Active Directory (Azure AD) Join or Microsoft AutoPilot.

Where To Look First: Logs and Event IDs

To diagnose this issue, examine the following logs and events: 1. **Event Viewer**: - Navigate to Applications and Services Logs > Microsoft > Windows > DeviceManagement-Enterprise-Diagnostics-Provider > Admin. - Look for Event ID 75: "The auto-discovery request could not be resolved." - Look for Event ID 76: "MDM enrollment failed: 0x80cf4017." 2. **Log Files**: - C:\ProgramData\Microsoft\DMClient\ProvisioningCommands.log - Search for entries containing DiscoveryError or 0x80cf4017. - C:\Users\Public\Documents\MDMDiagnostics\MDMDiagReport.html - Review the enrollment section for errors like "EnterpriseEnrollment DNS SRV lookup failed" or "Discovery URL unreachable." 3. **PowerShell Command**: - Use Get-WinEvent -LogName "Microsoft-Windows-DeviceManagement-Enterprise-Diagnostics-Provider/Admin" -MaxEvents 50 to retrieve recent events from the diagnostic provider.

Root Causes

1. DNS Configuration Issues

The most common cause is a misconfigured or missing DNS CNAME record for enterpriseenrollment.. This record should point to EnterpriseEnrollment-s.manage.microsoft.com. If the DNS lookup fails or resolves to an incorrect IP address, the enrollment process cannot proceed.

2. MDM Automatic Enrollment Disabled in Entra ID

If the tenant has not enabled MDM automatic enrollment in the Entra admin center, devices will fail to discover the Intune service endpoint. This occurs when the "MDM user scope" is set to None instead of All or a specific group.

3. Network Connectivity Issues

Firewalls or proxies may block access to Intune endpoints on port 443 (HTTPS). Specifically, devices must be able to reach: - enrollment.manage.microsoft.com - EnterpriseEnrollment-s.manage.microsoft.com

4. UPN Suffix Mismatch

The user's Entra ID UPN suffix may not match a verified custom domain with an EnterpriseEnrollment CNAME record, and the fallback endpoint enrollment.manage.microsoft.com is unreachable.

Fix Procedure

  1. Verify DNS Configuration: - Open Command Prompt and run nslookup enterpriseenrollment.. - Ensure the result resolves to EnterpriseEnrollment-s.manage.microsoft.com and then to a Microsoft IP address. - In your DNS management console (e.g., Azure DNS, GoDaddy, Cloudflare), check for: - CNAME record: Host = enterpriseenrollment, Value = EnterpriseEnrollment-s.manage.microsoft.com - CNAME record: Host = enterpriseregistration, Value = enterpriseregistration.windows.net
  2. Enable MDM Automatic Enrollment: - Navigate to the Entra admin center > Identity > Mobility (MDM and MAM) > Microsoft Intune. - Under "MDM user scope," select All or a specific group, then save changes.
  3. Test Network Connectivity: - Run PowerShell commands: Test-NetConnection -ComputerName enrollment.manage.microsoft.com -Port 443 Test-NetConnection -ComputerName EnterpriseEnrollment-s.manage.microsoft.com -Port 443 - Ensure TcpTestSucceeded = True.
  4. Check for Split-DNS Issues: - If internal DNS overrides are causing incorrect resolutions, add a conditional forwarder for manage.microsoft.com to point to the public DNS resolver.
  5. Force MDM Redeployment (Optional): - Use dsregcmd /status to check device registration status.
    Warning: Forcing a redeployment may temporarily disconnect enrolled devices from Intune. Proceed with caution.
  6. Review MDM Diagnostic Report: - Access the report at C:\Users\Public\Documents\MDMDiagnostics\MDMDiagReport.html. - Look for enrollment errors and follow recommended actions.
  7. Update Device Configuration (Optional): - Use OMA-URI settings to enforce specific configurations: .Device/Vendor/MSFT/Policy/Config/EnterpriseWiFi/ProfileName .Device/Vendor/MSFT/Policy/Config/NetworkOperatorCredential/Carrier
  8. Monitor Device Enrollment: - Use the Intune admin center > Devices > All devices to verify successful enrollment. - Run Get-MgDeviceManagementManagedDevice -Filter "deviceEnrollmentType eq 'windowsAutoEnrollment'" to list enrolled devices.
  9. Log Analysis Post-Fix: - Check Event Viewer for Event ID 72: "The auto-discovery request succeeded." - Review ProvisioningCommands.log for successful enrollment markers.

Error Code Variants

Error Code Description Distinguishing Factors
0x80cf4017 MDM service URL or discovery endpoint unreachable Specific to DNS or network issues with Intune endpoints
0x80cf4016 Invalid MDM configuration data received Occurs when the device receives malformed or invalid enrollment data
0x80cf4018 MDM service responded with an error status code Indicates a server-side issue during enrollment

Verification

To confirm the fix: - Check Event Viewer for Event ID 72: "The auto-discovery request succeeded." - Verify device enrollment in the Intune admin center > Devices > All devices. - Run dsregcmd /status to ensure the device is properly registered.

Prevention

Implement the following measures: 1. Regularly monitor DNS records for enterpriseenrollment. and enterpriseregistration.. 2. Use PowerShell scripts to automate network connectivity tests to Intune endpoints. 3. Configure monitoring tools (e.g., Azure Monitor) to alert on MDM enrollment failures. 4. Review Entra ID settings periodically to ensure MDM automatic enrollment remains enabled.
Tip: Use the Test-NetConnection cmdlet regularly to verify network access to Intune endpoints and prevent recurring issues.
By following this guide, you can effectively troubleshoot and resolve the 0x80cf4017 error, ensuring seamless MDM enrollment for Windows 10/11 devices in your organization.

Sources & References

Related Guides

Get new error code fixes by email

Product-specific solutions for Intune, Autopilot, SCCM and Entra ID — straight to your inbox. No spam.