Intune Initial Scripts Backup

This commit is contained in:
andrewamason committed 2025-04-21 14:21:38 -04:00
commit 71764cd10f
241 files changed
+28218

No files matched your search

@@ -0,0 +1,28 @@
try {
Test-Path -Path "C:\Program Files (x86)\Bit9\Parity Agent"
}
catch {
Write-Host "Carbon Black App Control Folder Does Not Exist"
exit 1
}
try {
Test-Path -Path "C:\Program Files (x86)\Bit9\Parity Agent\DasCLI.exe"
}
catch {
Write-Host "Carbon Black App Control is not installed"
exit 1
}
Set-Location "C:\Program Files (x86)\Bit9\Parity Agent"
$CBagentstatus = .\DasCLI.exe status
if (((($CBagentstatus[55]).Split(":")[1])).Trimstart() -like "Healthy") {
Write-Host "Carbon Black agent is healthy"
Exit 0
}
else {
Write-Host "Carbon Black App Control Status is unknown" ((($CBagentstatus[55]).Split(":")[1])).Trimstart()
exit 1
}