Quantcast
Channel: Microsoft Intune
Viewing all articles
Browse latest Browse all 1216

Powershell Manage BDE failing to run automatically

$
0
0

We are trying to get the remediation to run in Intune to bitlocker and upload the numerical key to Azure. When I connect to a non encrypted machine and run the following manually this works 100% of the time. I do run each line and wait till it finishes to run the next. When I try to run this in PS ISE and put a sleep timer of 15 seconds between steps 1-2 and steps 2-3 the second line fails and returns the following...ERROR: Invalid Syntax.
"?protectors" was not understood.

Why would this work manually but not automatically and fail with that error?

Enable-BitLocker -MountPoint "C" -EncryptionMethod XtsAes128 -UsedSpaceOnly -TpmProtector -SkipHardwareTest

manage-bde –protectors –add C: -RecoveryPassword

BackupToAAD-BitLockerKeyProtector -MountPoint $env:SystemDrive -KeyProtectorId ((Get-BitLockerVolume -MountPoint $env:SystemDrive...


Viewing all articles
Browse latest Browse all 1216

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>