PowerShell Quick Checks

Fast checks for endpoint troubleshooting

Small, field-ready PowerShell checks for Intune, Windows, Exchange, SharePoint, Azure Virtual Desktop, Citrix, restart state, device health, and workspace troubleshooting.

EN

Enrollment state

dsregcmd /status remains the fastest first signal for Entra join, device registration, tenant details, and PRT availability.

IME

IME log folder

Review recent Intune Management Extension logs before resetting agents or changing assignments.

BL

BitLocker and TPM

Confirm protection state and TPM readiness before firmware, Secure Boot, or recovery-key related changes.

WU

Windows Update

Separate policy scope, service state, scan state, reboot state, and reporting latency.

EX

Exchange Online

Check Exchange Online connection context, mailbox visibility, recipient state, and basic service-side signals.

SP

SharePoint Online

Check tenant connectivity, site status, storage usage, lock state, and sharing-sensitive site configuration.

AVD

Azure Virtual Desktop

Inspect host pools, session hosts, user sessions, drain mode, and workspace/resource group alignment.

CTX

Citrix

Check broker machines, VDA registration, sessions, delivery groups, application publication, and user impact.

VDI

Profile and session state

Use FSLogix, profile container, disk space, session, and log checks to separate endpoint issues from VDI issues.

Identity and enrollment

Check Entra join and PRT state

dsregcmd /status

Intune Management Extension

List recent IME logs

$logPath = 'C:\ProgramData\Microsoft\IntuneManagementExtension\Logs'
Get-ChildItem $logPath -Filter '*.log' -ErrorAction SilentlyContinue |
    Sort-Object LastWriteTime -Descending |
    Select-Object Name, Length, LastWriteTime -First 10

BitLocker and TPM

Check protection and TPM readiness

Get-BitLockerVolume | Select-Object MountPoint, ProtectionStatus, VolumeStatus, EncryptionPercentage
Get-Tpm | Select-Object TpmPresent, TpmReady, TpmEnabled, TpmActivated

Windows Update

Check update services and local UX state

Get-Service wuauserv,bits,cryptsvc | Select-Object Name, Status, StartType
Get-ItemProperty 'HKLM:\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings' -ErrorAction SilentlyContinue

Restart governance

Check pending restart signals

$paths = @(
  'HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Component Based Servicing\RebootPending',
  'HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update\RebootRequired',
  'HKLM:\SYSTEM\CurrentControlSet\Control\Session Manager'
)
$paths | ForEach-Object {
    [pscustomobject]@{ Path = $_; Exists = Test-Path $_ }
}

Exchange Online

Check Exchange Online session and mailbox visibility

# Requires ExchangeOnlineManagement and an existing or new Exchange Online session.
Get-ConnectionInformation | Select-Object Name,UserPrincipalName,ConnectionUri,State
Get-EXOMailbox -ResultSize 10 |
    Select-Object DisplayName,PrimarySmtpAddress,RecipientTypeDetails

Exchange Online

Check mailbox size and last logon signal

# Replace the identity with the affected mailbox.
$mailbox = 'user@workplacecloudhub.com'
Get-EXOMailboxStatistics -Identity $mailbox |
    Select-Object DisplayName,TotalItemSize,ItemCount,LastLogonTime

SharePoint Online

Check SharePoint site status and storage

# Requires Microsoft.Online.SharePoint.PowerShell and Connect-SPOService.
Get-SPOSite -Limit 20 |
    Select-Object Url,Status,LockState,StorageUsageCurrent,StorageQuota |
    Sort-Object StorageUsageCurrent -Descending

SharePoint Online

Check a specific site collection

$siteUrl = 'https://workplacecloudhub.sharepoint.com/sites/example'
Get-SPOSite -Identity $siteUrl |
    Select-Object Url,Title,Status,LockState,SharingCapability,StorageUsageCurrent,StorageQuota

Azure Virtual Desktop

List host pools and session hosts

# Requires Az.DesktopVirtualization and an authenticated Az session.
$resourceGroup = 'rg-avd-prod'
Get-AzWvdHostPool -ResourceGroupName $resourceGroup |
    Select-Object Name,Location,HostPoolType,LoadBalancerType

Get-AzWvdSessionHost -ResourceGroupName $resourceGroup -HostPoolName 'hp-avd-prod' |
    Select-Object Name,Status,AllowNewSession,LastHeartBeat

Azure Virtual Desktop

Check active AVD user sessions

$resourceGroup = 'rg-avd-prod'
$hostPool = 'hp-avd-prod'
Get-AzWvdUserSession -ResourceGroupName $resourceGroup -HostPoolName $hostPool |
    Select-Object UserPrincipalName,SessionState,CreateTime,SessionHostName

Citrix Virtual Apps and Desktops

Check VDA registration and maintenance mode

# Run in a Citrix PowerShell context with the Broker snap-in/module available.
Get-BrokerMachine -MaxRecordCount 50 |
    Select-Object MachineName,RegistrationState,PowerState,InMaintenanceMode,SessionCount |
    Sort-Object RegistrationState,MachineName

Citrix Virtual Apps and Desktops

Check active Citrix sessions

Get-BrokerSession -MaxRecordCount 50 |
    Select-Object UserName,MachineName,SessionState,ApplicationState,StartTime |
    Sort-Object StartTime -Descending

FSLogix and VDI profiles

Check FSLogix service and profile logs

Get-Service frxsvc -ErrorAction SilentlyContinue |
    Select-Object Name,Status,StartType

$fslogixLogPath = 'C:\ProgramData\FSLogix\Logs'
Get-ChildItem $fslogixLogPath -Recurse -Filter '*.log' -ErrorAction SilentlyContinue |
    Sort-Object LastWriteTime -Descending |
    Select-Object FullName,Length,LastWriteTime -First 10

VDI session host health

Check session host disk and uptime basics

Get-CimInstance Win32_OperatingSystem |
    Select-Object CSName,LastBootUpTime,FreePhysicalMemory

Get-Volume |
    Select-Object DriveLetter,FileSystemLabel,SizeRemaining,Size |
    Sort-Object DriveLetter

Operational note

Use quick checks as evidence, not as final conclusions.

These commands are intended for triage. Validate results against Intune assignment state, Microsoft 365 admin context, AVD or Citrix control-plane state, device context, change history, event logs, and documented support procedures before applying remediation at scale.