The best part here is Windows 10 devices are hybrid joined automatically. PowerShell (137) Best Answer. Does anyone have any idea why this would be happening?
…
I do not think there is an option to get user states for all computers using this cmdlet and you may need to write custom PowerShell code to do the same. I took a different approach, since the output is a little bit unpredictable, I build the property names dynamically. .
I spent a little bit of time researching it but not exhaustive. dsregcmd /join /debug -> debug the join (again administrator) dsregcmd /debug -> precheck whether AAD join can be performed dsregcmd /leave -> removes the AAD registration when executed as NT Authority dsregcmd /leave /debug -> debug the … (Option 1 and 2) Verify that the GPO with MDM enrollment applies to the device. This I’m not sure of. I also wanted a way to tell if the device was AzureAD joined. to your account. Neally. EDIT: I plan to rewrite this function based off of registry values directly instead of parsing the txt output of this command. psexec -i -s cmd.exe. New comments cannot be posted and votes cannot be cast. As long as the remote computer is configured for PowerShell Remoting, which is a one-time setup, there is minimal, if any, setup needed on the client computer for this to work. Skip to content.
Azure AD and will generate the certificate and send it back to the device. Cookies help us deliver our Services. After running the above command, under Device State, check the AzureADJoined. I wanted a way to determine if a system was joined to a domain and then to get the domain info. Not really worried about performance for this. Successfully merging a pull request may close this issue. This person is a verified professional. When I run it from Intune, it reports an error and the IntuneManagementExtension.log has a line that "The term 'dsregcmd' is not recognized as the name of a cmdlet", etc. Press J to jump to the feed. When a certificate is created it can be found from the cloud with PowerShell and in the portal device state is changed. @BacharBader I am able to get the User State using the command. If there are further questions regarding this matter, please reopen it and we will gladly continue the discussion. PowerShell is a cross-platform (Windows, Linux, and macOS) automation tool and configuration framework optimized for dealing with structured data (e.g.
You signed in with another tab or window. Press question mark to learn the rest of the keyboard shortcuts. Have a question about this project? Not just Azure Ad Jointed but enrolled as well. Note that dsregcmd needs to run as System, so you’ll need psExec to get your commands running in the correct context. @BacharBader I suggest you please open a new MSDN forum post with the details and community will help address your query. Mace. Or "workplace joined" means it's enrolled?? Thanks for sharing. You have to wait for at least 5-30 minutes or more to see the result. It was challenging because depending on how the device is joined (or not) the output if quite different.