New Intune Connector for Active Directory Process Not Working

Matt Dillon 437 Reputation points
2025-03-14T16:19:46.1733333+00:00

I have two projects that need the Intune Connector for Active Directory installed. I went through the processes listed here: https://learn.microsoft.com/en-us/autopilot/tutorial/user-driven/hybrid-azure-ad-join-intune-connector?tabs=updated-connector

On the first project, I had an issue and ultimately it was solved by giving my Global Admin account an Intune license temporarily.

On the second project, it just refuses to work at all. Three different admins tried signing in and we all get the same results:

  1. ODJConnector installed
  2. Service is running
  3. Cannot complete configuration.

The Managed Service OU was missing so we followed some directions online and fixed it.

Log file has the following entry over and over with the main issue saying "Failed to create a managed service account - Element not found"

Any help welcomed. About to open a Microsoft ticket.

ODJ Connector UI Information: 0 : User clicked on SignIn
    DateTime=2025-03-14T15:39:59.2116739Z
ODJ Connector UI Information: 0 : Navigating to URL https://portal.manage.microsoft.com/Home/ClientLogon
    DateTime=2025-03-14T15:39:59.2898053Z
ODJ Connector UI Information: 0 : Browser loaded page https://login.microsoftonline.com/common/oauth2/authorize?client_id=74bcdadc-2fdc-4bb3-8459-76d06952a0e9&redirect_uri=https%3A%2F%2Fportal.manage.microsoft.com%2Fsignin-oidc&response_type=code&prompt=select_account&scope=openid profile&response_mode=form_post&nonce=638775635996879226.MjIwYWI0ODItYTc3YS00NzY2LWEyZTEtMjYyN2Q2MTY4YTkzMTgwNDMyNzMtMmQzNC00MTY1LThhN2ItMDMxOTE2NDA4MDMx&display=host&state=CfDJ8Ji1hs71b9ZDlZfpMprk6xUmh5ZyiH2tn2o80ueQkJnLktqRnri68LHjk9smwi1SW4CxmiwntrTIiqivmIKN4GNOs17XMCIMq_gK50SStqkrPdrTYW092vUJu3uqjVqUxveNpJygWFHIkSw1CDKf-kRD3ugxbsWkKstPzUAtdK_d4vhOEk4PNCXdnL2-D0ZzgrIgMrMHZNSIbF9f0aC1Ya8xHg79E5Ev88B9t87DUeR2KFCoJBKrBcyADHWrfzJxBTQANVdVcA8DSsoczySKv6LyrVsRK0ZgllR2jh9uF4jAY91uDgX3Rby7TMbM9rDrwiDqjgKniaKt4oF1Df7lnB27gG4jSe6ZoOg52y5uxfitA5SkPWuJH-w_0FdNfeRk5g&x-client-SKU=ID_NET472&x-client-ver=8.3.0.0
    DateTime=2025-03-14T15:40:00.0710556Z
ODJ Connector UI Information: 0 : Browser loaded page https://portal.manage.microsoft.com/Home/ClientLogonSuccess
    DateTime=2025-03-14T15:41:26.9508117Z
ODJ Connector UI Information: 0 : Getting the URL for EnrollmentService from https://manage.microsoft.com/RestUserAuthLocationService/RestUserAuthLocationService/ServiceAddresses
    DateTime=2025-03-14T15:41:27.6851767Z
ODJ Connector UI Information: 0 : Received Url for EnrollmentService as https://fef.amsua0102.manage.microsoft.com/StatelessEnrollmentService from RestUserAuthLocationService.
    DateTime=2025-03-14T15:41:27.6851767Z
ODJ Connector UI Information: 0 : Getting the URL for RAODJPlusFEGatewayService_FEF from https://manage.microsoft.com/RestUserAuthLocationService/RestUserAuthLocationService/ServiceAddresses
    DateTime=2025-03-14T15:41:27.6851767Z
ODJ Connector UI Information: 0 : Received Url for RAODJPlusFEGatewayService_FEF as https://fef.amsua0102.manage.microsoft.com/TrafficGateway/TrafficRoutingService/RAODJPlus/StatelessODJService from RestUserAuthLocationService.
    DateTime=2025-03-14T15:41:27.6851767Z
ODJ Connector UI Information: 0 : Searching for any pre-existing Managed Service Accounts installed on this machine.
    DateTime=2025-03-14T15:41:27.7320578Z
ODJ Connector UI Information: 0 : MSA name : msaODJBfuWt
    DateTime=2025-03-14T15:41:27.8414250Z
ODJ Connector UI Error: 2 : ERROR: Enrollment failed. Detailed message is: Microsoft.Management.Services.ConnectorCommon.Exceptions.ConnectorConfigurationException: Failed to create a managed service account - Element not found
   at Microsoft.Management.Services.ConnectorCommon.ManagedServiceAccountUtilities.NativeMethods.NetAddServiceAccountWrapper(String accountName)
   at Microsoft.Management.Services.ConnectorCommon.ManagedServiceAccountUtilities.ManagedServiceAccountUtilities.CreateManagedServiceAccount(String domainName, String precreatedMsaAccount)
   at ODJConnectorUI.EnrollmentTab.CreateMsa(String domainName, StepsStarted& stepsStartedFlag)
   at ODJConnectorUI.EnrollmentTab.webBrowser_LoadCompleted(Object sender, NavigationEventArgs e)
    DateTime=2025-03-14T15:41:27.8883066Z
ODJ Connector UI Information: 0 : Storing telemetry: CreateMsaAccount, hasException: True
    DateTime=2025-03-14T15:41:27.8883066Z
ODJ Connector UI Information: 0 : Sending telemetry: CreateMsaAccount, hasException: True
    DateTime=2025-03-14T15:41:27.8883066Z
ODJ Connector UI Information: 0 : Sending telemetry to ODJService
    DateTime=2025-03-14T15:41:27.9039290Z
ODJ Connector UI Information: 0 : RAODJPlus Service URL: https://fef.amsua0102.manage.microsoft.com/TrafficGateway/TrafficRoutingService/RAODJPlus/StatelessODJService/odjConnectorTelemetry/uploadTelemetry
    DateTime=2025-03-14T15:41:27.9039290Z
ODJ Connector UI Information: 0 : Successfully sent request to RAODJPlusFEGatewayService_FEF
    DateTime=2025-03-14T15:41:28.2320528Z
ODJ Connector UI Information: 0 : Response from ODJService: OK
    DateTime=2025-03-14T15:41:28.2320528Z
ODJ Connector UI Error: 8 : Removing Managed Service Account ...
    DateTime=2025-03-14T15:41:28.2320528Z
ODJ Connector UI Error: 8 : Successfully removed Managed Service Account
    DateTime=2025-03-14T15:41:28.2476749Z
ODJ Connector UI Error: 8 : Returning to the home page
    DateTime=2025-03-14T15:41:28.2476749Z

Microsoft Security Intune Enrollment
{count} votes

Accepted answer
  1. Groß, Florian 80 Reputation points
    2025-06-16T12:12:05.8666667+00:00

    Hello together, I've had a customer with the same problem:

    they deleted the "Managed Service Accounts" container from the ad and therefore were not able to install the intune connector.

    Here's the way i got it working again:

    1. (opt) Delete manually created "Managed Service Accounts"-Container (I've had a similar container created with powershell, in this case, delete it)
    2. Connect to ADSI (Default Naming Context)
    3. Under "Default naming context -> DC=<DomainName>,DC=<TLD> -> CN=System -> CN=DomainUpdates -> CN=Operations" Delete Container called "CN=5e1574f6-55df-493e-a671-aaeffca6a100"
    4. Under "DC=<DomainName>,DC=<TLD> -> CN=System -> CN=DomainUpdates -> CN=ActiveDirectoryUpdate" edit Properties: revisions (set to 15/16), set to undefined / remove value
    5. Mount Server OS ISO
    6. Run ADprep.exe /domainprep (in my case: D:\support\adprep\adprep.exe /domainprep)

    run the following PowerShell Script:

    $DomainDN = (Get-ADDomain).distinguishedName
    $TargetOWKOIDString = "1EB93889E40C45DF9F0C64D23BBB6237" # Identifier for wellknown SID. 
    $TargetOWKOTemplate = "B:32:$TargetOWKOIDString`:{0}" # String.Format replacable string.
    $TargetDN = "CN=Managed Service Accounts,$DomainDN"
    
    $OtherWellKnownObjectsOG = (Get-ADObject -filter "objectClass -eq 'domainDns'" -Properties otherwellknownobjects).otherwellknownobjects
    $TargetOWKOIndex = $OtherWellKnownObjectsOG.IndexOf( $OtherWellKnownObjectsOG.where({ $PSItem -like "*$TargetOWKOIDString*"})[0])
    
    Set-ADObject -Identity $DomainDN -Add @{ 'otherwellknownobjects' = ($TargetOWKOTemplate -f "$TargetDN") } -Remove @{ 'otherwellknownobjects' = $OtherWellKnownObjectsOG[$TargetOWKOIndex] }
    
    (Get-ADObject -filter "objectClass -eq 'domainDns'" -Properties otherwellknownobjects).otherwellknownobjects
    

    creds for script: Vin

    What does it all do:

    Recreates the Managed Service Accounts Container, so that you can add the default guid to the otherwellknownobjects.

    This way the default state for the Managed Service Accounts Container is recreated and you can successfully install the intune connector.

    1 person found this answer helpful.
    0 comments No comments

1 additional answer

Sort by: Most helpful
  1. Vin 20 Reputation points
    2025-05-13T14:54:30.5433333+00:00

    For anyone experiencing Error "Element not found" or

    User's image

    You will need to run the below in Powershell. This will update the Managed Services Account CN with the default GUID.

    $DomainDN = (Get-ADDomain).distinguishedName
    $TargetOWKOIDString = "1EB93889E40C45DF9F0C64D23BBB6237" # Identifier for wellknown SID. 
    $TargetOWKOTemplate = "B:32:$TargetOWKOIDString`:{0}" # String.Format replacable string.
    $TargetDN = "CN=Managed Service Accounts,$DomainDN"
    
    $OtherWellKnownObjectsOG = (Get-ADObject -filter "objectClass -eq 'domainDns'" -Properties otherwellknownobjects).otherwellknownobjects
    $TargetOWKOIndex = $OtherWellKnownObjectsOG.IndexOf( $OtherWellKnownObjectsOG.where({ $PSItem -like "*$TargetOWKOIDString*"})[0])
    
    Set-ADObject -Identity $DomainDN -Add @{ 'otherwellknownobjects' = ($TargetOWKOTemplate -f "$TargetDN") } -Remove @{ 'otherwellknownobjects' = $OtherWellKnownObjectsOG[$TargetOWKOIndex] }
    
    (Get-ADObject -filter "objectClass -eq 'domainDns'" -Properties otherwellknownobjects).otherwellknownobjects
    
    
    

    After running the above:

    Untitled

    4 people found this answer helpful.

Your answer

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