Ask a question

David Moore

Failed exchange removal

I am trying to remove the last and only Exchange server 2019 after doing a cut over migration to Office 365.

This is the procedure I used:

Set-ADServerSettings -ViewEntireForest $true

Get-MoveRequest | Remove-MoveRequest -Confirm:$false

Get-OfflineAddressBook | Remove-OfflineAddressBook -Confirm:$false

Get-Mailbox -ResultSize Unlimited | Disable-Mailbox -Confirm:$false

Get-Mailbox -ResultSize Unlimited -Archive | Disable-Mailbox -Confirm:$false

Get-Mailbox -ResultSize Unlimited -PublicFolder | Disable-Mailbox -Confirm:$false

Get-Mailbox -AuditLog | Disable-Mailbox -Confirm:$false

Get-Mailbox -Arbitration | Disable-Mailbox -Arbitration -DisableLastArbitrationMailboxAllowed -Confirm:$false

Get-MailboxDatabase | Remove-MailboxDatabase -Confirm:$false

I then went to control panel Programs and Features to unistall Exchange, which stated thet prerequisites were accepted.

At Step 7 the uninstall stoped working with this:

Error:
The following error was generated when "$error.Clear(); 
    uninstall-ExsetDataAtom -AtomName OrgLevelCt -DomainController $RoleDomainController

" was run: "Microsoft.Exchange.Management.Deployment.ExsetdataException: An error occurred with error code '2147942405' and message 'Access denied.'.
   at Microsoft.Exchange.Configuration.Tasks.Task.ThrowTerminatingError(Exception exception, ErrorCategory category, Object target)
   at Microsoft.Exchange.Management.Deployment.ManageExsetdataAtom.HandleExsetdataReturnCode(UInt32 scErr)
   at Microsoft.Exchange.Management.Deployment.ManageExsetdataAtom.UninstallAtom(AtomID atomID)
   at Microsoft.Exchange.Management.Deployment.UninstallExsetdataAtom.InternalProcessRecord()
   at Microsoft.Exchange.Configuration.Tasks.Task.<ProcessRecord>b__91_1()
   at Microsoft.Exchange.Configuration.Tasks.Task.InvokeRetryableFunc(String funcName, Action func, Boolean terminatePipelineIfFailed)".
 

I tried to restart the uninstall and run again but would allow me to.

So I have restored the WSE2016 server and EXCH2019 server and I am back to stage one.

So my question is was the procedure above the correct way to uninstall?

Was there anything else I could have done prior to starting.

If I go through the procedure again and it bombs out (already tried 2 times so the problem is repeatable) should I just accept and do the next suggest manual uninstall in Active directory.

Removed link to spam company.

Regards David Moore.


asked12/13/2022 06:45
210 views
Add Comment
Last Activity 12/26/2022 13:32

1 Answer(s)

  • Mariette Knap
    Add Comment
    David Moore

    Thanks for the suggestions and sorry about taking so long to answer this post, I had to wait for Friday down time.  I added my account to the Schema Admins and Enterprise Admins and performed the E:\Setup.exe /IAcceptExchangeServerLicenseTerms_DiagnosticDataOFF /PrepareSchema, unfortunalty it didnt solve my problem as per graphic, any other suggetions would be appreciated.

    Attached Files
    Mariette Knap

    Pls, enable the builtin Administrator account. Reboot both servers and try to install again with the Administrator account


    replied 12/16/2022 10:34
    David Moore

    Thankyou Mariette, enabling the domain administrator (domain\administrator) account and doing the uninstall using that account fixed my problem. I staill had to do the powershell scripts under my own login.

    Thank you, I was getting worried.

    Apart from removeing the exchange server from the domain is there any other advise you would give?

     


    replied 12/16/2022 13:47
    Mariette Knap

    David,

    Was this Windows Server Essentials 2016 integrated with the Dashboard into the Exchange Server? It could be that it is now impossible to disable that but I would have a look at that. I guess you also want to migrate the DC to something new? Maybe after that you want to install Azure ADSync? If you do that you must run Microsoft Idfix first to fix any issues.


    replied 12/16/2022 14:51
    David Moore

    I was hoping to keep the WSE 2016 server as the domain controller for the time being, however I have tried to use the WSE Dashboard to enable the Office 365 cloud intergration service but it is failing to work.

    Here is what I have done so far.

    1. downloaded and installed msoidcli_64bit.msi (which worked for me in the past)

    2. enabled TLS enforcement https://learn.microsoft.com/en-us/azure/active-directory/hybrid/reference-connect-tls-enforcement

    3. Installed Password Change Notification Service.

    Any other suggestions?


    replied 12/18/2022 10:33
    Mariette Knap

    Can you be more specific? I mean, 'it is failing' is difficult for me


    replied 12/18/2022 14:26
    David Moore

    Is it safe to add the log file SharedServiceHost-EmailProviderServiceConfig.log here.

    Attached Files

    replied 12/20/2022 18:19
    David Moore

    SharedServiceHost-EmailProviderServiceConfig.log - Ziped

     

    Attached Files

    replied 12/26/2022 09:09
    Mariette Knap

    Pls, run this and try again:

    # PowerShell
    New-ItemProperty -Path "HKLM:\SOFTWARE\WOW6432Node\Microsoft\.NETFramework\v2.0.50727" -Name "SystemDefaultTlsVersions" -Value 1 -PropertyType DWORD -Force
    New-ItemProperty -Path "HKLM:\SOFTWARE\WOW6432Node\Microsoft\.NETFramework\v2.0.50727" -Name "SchUseStrongCrypto" -Value 1 -PropertyType DWORD -Force
    New-ItemProperty -Path "HKLM:\SOFTWARE\WOW6432Node\Microsoft\.NETFramework\v4.0.30319" -Name "SystemDefaultTlsVersions" -Value 1 -PropertyType DWORD -Force
    New-ItemProperty -Path "HKLM:\SOFTWARE\WOW6432Node\Microsoft\.NETFramework\v4.0.30319" -Name "SchUseStrongCrypto" -Value 1 -PropertyType DWORD -Force
    
    New-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\.NETFramework\v2.0.50727" -Name "SystemDefaultTlsVersions" -Value 1 -PropertyType DWORD -Force
    New-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\.NETFramework\v2.0.50727" -Name "SchUseStrongCrypto" -Value 1 -PropertyType DWORD -Force
    New-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\.NETFramework\v4.0.30319" -Name "SystemDefaultTlsVersions" -Value 1 -PropertyType DWORD -Force
    New-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\.NETFramework\v4.0.30319" -Name "SchUseStrongCrypto" -Value 1 -PropertyType DWORD -Force
    
    Restart-Computer -Force

     


    replied 12/26/2022 10:54
    David Moore

    Thankyou for taking a look at the log, I tried your script above and it did not fix my issue.

    This is happening on 2 customers, CCC and Wilden.

    I have posted both zipped logs of my last attempt.

    Regards David.

    Attached Files

    replied 12/26/2022 12:45
    Mariette Knap

    Thanks. I will have a look at the logs


    replied 12/26/2022 13:32

    Reply
    replied 12/16/2022 10:19
Add an Answer