You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
# Can't manage or remove objects that were synchronized through the Azure Active Directory Sync tool
10
10
@@ -34,27 +34,30 @@ This issue may occur if one or more of the following conditions are true:
34
34
35
35
You want to manage objects in Office 365, Azure, or Intune and you no longer want to use directory synchronization.
36
36
37
-
[!INCLUDE [Azure AD PowerShell deprecation note](~/../support/reusable-content/msgraph-powershell/includes/aad-powershell-deprecation-note.md)]
38
-
39
-
1. If you're not running Windows 10, install the 64-bit version of the Microsoft Online Services Sign-in Assistant: [Microsoft Online Services Sign-in Assistant for IT Professionals RTW](https://download.microsoft.com/download/7/1/E/71EF1D05-A42C-4A1F-8162-96494B5E615C/msoidcli_32bit.msi).
40
-
1. Install the Microsoft Azure Active Directory module for Windows PowerShell:
41
-
42
-
1. Open an elevated Windows PowerShell command prompt (run Windows PowerShell as an administrator).
43
-
2. Run the `Install-Module MSOnline` command.
44
-
45
-
1. Disable directory synchronization by running the following command:
37
+
1. Make sure that [Microsoft Graph PowerShell is installed](/powershell/microsoftgraph/installation).
38
+
2. Use the `Connect-MgGraph` command to sign in with the required scopes such as `Organization.ReadWrite.All`. For more information, see [Get started with the Microsoft Graph PowerShell SDK](/powershell/microsoftgraph/get-started).
39
+
1. Disable directory synchronization by running the [update-mgorganization](/powershell/module/microsoft.graph.identity.directorymanagement/update-mgorganization) command.
46
40
47
41
```powershell
48
-
Set-MsolDirSyncEnabled -EnableDirSync $false
42
+
43
+
$organizationId = (Get-MgOrganization).Id
44
+
45
+
# Store the False value for the DirSyncEnabled Attribute
0 commit comments