By David,
FSLogix profile containers grow because users fill them, and they don't shrink on their own unless FSLogix can compact them at sign-out. A container is capped by SizeInMBs (30,000 MB by default), which you can raise but never lower. With dynamic disks, FSLogix's built-in VHDCompactDisk reclaims deleted space at sign-out, but only when the container is over 1 GB and at least 20% of it is reclaimable, and only if the Optimize Drives service is allowed to run. To keep containers small, stop the biggest data from landing in them: Outlook's OST, Teams and browser caches, and duplicated OneDrive files.
The short version: Leave compaction on, make sure
defragsvcandsmphostaren't disabled on your image, and check the profile log for "WasCompacted". Use VHDX and dynamic disks. Raise SizeInMBs in steps only when real data needs it. Then go after what fills profiles: OneDrive Files On-Demand and Known Folder Move, the Teams VDI cache exclusions, and Outlook's cached mode settings. Watch the share's free space too: Microsoft suggests alerting below 20% free.
This guide goes deeper on the "container full" section of our FSLogix troubleshooting guide. Everything below is from Microsoft Learn as of November 2026, with each source linked.
The settings that decide container size
All under HKLM\SOFTWARE\FSLogix\Profiles (configuration settings):
| Setting | Default | What it does |
|---|---|---|
| SizeInMBs | 30000 | The maximum size of a new or existing container. "You can increase this value at any time, but can't decrease it." Existing containers are extended at the user's next sign-in |
| IsDynamic | 1 | A dynamic disk only uses the space it holds on the share, growing up to SizeInMBs. A fixed disk takes the whole size immediately |
| VolumeType | VHD | The disk format. Microsoft's profile container guidance recommends VHDX "due to its supported size and reduced corruption scenarios" (configure profile containers) |
Two consequences matter in practice. Lowering SizeInMBs does nothing to existing containers, so set it deliberately. And raising it applies to every user with a dynamic disk, so a bigger limit is a bigger ceiling for everyone, not just the person who asked (container size troubleshooting).
How FSLogix compaction works
VHDCompactDisk, under HKLM\SOFTWARE\FSLogix\Apps, is on by default (1) in FSLogix 2210 and later. At sign-out FSLogix checks the container and compacts it when both of these are true (VHD disk compaction):
- The size on disk is more than 1 GB.
- The space that could be reclaimed is at least 20% of the size on disk.
Microsoft's examples: a 6 GB container that only needs 2.5 GB is compacted; a 12 GB container that needs 10 GB isn't, because less than 20% would be saved. The threshold isn't configurable (FAQ). Compaction applies to profile and Office containers, Cloud Cache included, but only to dynamic disks: "fixed size virtual hard disks cannot be compacted."
What it costs at sign-out. Users see "Waiting for FSLogix Apps Services" while it runs. Microsoft gives an average of 20 to 30 seconds, longest the first time. It stops after 5 minutes and carries on at the next sign-out. Winlogon may warn that sign-out took more than 60 seconds; Microsoft calls that "normal and expected" (compaction). If the user signs back in while compaction is still running, the container is in use, and by default they get a temporary profile (FAQ). See FSLogix profile locked if that happens often.
Why compaction isn't running, and how to tell
Check the services first. Compaction needs the Optimize Drives service (defragsvc) and the Microsoft Storage Spaces SMP service (smphost) set to Manual or Automatic, not Disabled. Hardened images often disable them. Microsoft's fix (compaction troubleshooting):
Set-Service defragsvc -StartupType Manual
Set-Service smphost -StartupType Manual
Then check the profile log for the user's sign-out. A compaction writes a line beginning "Disk size results: WasCompacted: true" with the size before and after and the time it took. When it doesn't run you'll see a reason, for example "Disk was not compacted, Reason: Not enough recoverable space for compaction."
And the event log. Compaction is one of the few FSLogix areas with documented event IDs, in the Microsoft-FSLogix-Apps channels (compaction troubleshooting, reference queries):
| Event ID | Channel | Meaning |
|---|---|---|
| 57 | Operational | Compaction result |
| 58 | Operational | Optimization failed |
| 60 | Admin | Optimize Drives service is disabled |
| 61 | Operational | The disk is fixed size |
| 62 | Admin | Unable to compact |
| 63 | Admin | Compaction failed |
Get-WinEvent -FilterHashtable @{
LogName = "Microsoft-FSLogix-Apps/Operational", "Microsoft-FSLogix-Apps/Admin"
Id = 57, 58, 60, 61, 62, 63
StartTime = (Get-Date).AddDays(-1)
} -ErrorAction SilentlyContinue | Select-Object TimeCreated, Id, Message
Our FSLogix logs and status codes reference covers the rest of the log.
When to switch it off. If you use Cloud Cache and sign-outs are slow, Microsoft lists disabling VHDCompactDisk as one of the fixes (FAQ). Otherwise, leave it on.
Compaction won't fix real data
Compaction gives back space from data that's been deleted. If the container is full of data the user still has, it won't help. Microsoft points to the usual culprits and the controls for each (container size troubleshooting):
| What fills profiles | Control |
|---|---|
| OneDrive files synced into the profile | OneDrive Files On-Demand, and Known Folder Move to keep Desktop and Documents in OneDrive |
| Outlook's OST | Cached Exchange Mode sync settings; FSLogix's RemoveOrphanedOSTFilesOnLogoff (default 0) set to 1 deletes all but the newest OST at sign-out, for classic Outlook |
| Teams caches | The cache folders Microsoft lists for new Teams in VDI, excluded with redirections.xml |
| Browser caches | Stateless cache data is one of the few things Microsoft says is safe to exclude (redirections.xml) |
Exclusions apply from the next sign-in. They don't remove data already in a container, and "FSLogix doesn't have tools or features to remove this data" (container size troubleshooting). Our FSLogix exclusions and redirections.xml guide covers how to set them up.
Shrinking a container that's already too big
FSLogix has no shrink command. Microsoft documents two approaches with frx.exe (in C:\Program Files\FSLogix\Apps) (frx):
- Delete the data, then let compaction reclaim it.
frx begin-edit-profilemounts a user's container while they're signed out; delete what you've confirmed is safe to remove, runfrx end-edit-profile, and the next compaction (or the next sign-out) gives the space back. Microsoft warns that deleting the wrong data "could lead to data loss or profile corruption". - Copy into a new container.
frx migrate-vhd"creates, formats a VHD or VHDX, and mirrors the contents of the source VHD", with options for the new size and whether it's dynamic. Microsoft doesn't describe it as a shrink method, so test it on a copy first.
Either way, the user must be signed out, and keep a copy of the original until they've signed in successfully.
Watch the share, not just the containers
A full container hurts one user. A full share stops everyone signing in. Microsoft recommends monitoring the share and alerting when free space drops below 20% (container size troubleshooting). On Azure Files, the Percentage File Share Utilization metric can drive that alert (Azure Files alerts). For sizing premium shares, see Azure Files premium sizing for FSLogix.
Containers for people who've left are the other slow leak. FSLogix doesn't document a clean-up feature for them, so find them by checking each container's user account and remove them on a schedule.
How Atlas AVD helps
In Atlas AVD, Workspace → FSLogix → Profiles has a Scan sizes & orphans action. For one host pool at a time, it reads each container's size, flags outliers well above the fleet median, and checks each user's account (Enabled, Disabled or No account), so orphaned containers stand out as clean-up candidates. The FSLogix Capacity Monitor checks every profile share every 15 minutes, warns at 85% full by default, and, if you turn auto-expand on, grows an Azure Files share by 10% when it reaches 95%, by at least 1 GB and never more than double in one step. Azure NetApp Files and other SMB shares are monitored but not resized.
FAQ
What is the default FSLogix profile container size?
30,000 MB (about 30 GB), set by SizeInMBs. With dynamic disks, the container only uses the space it holds on the share.
Can I make an FSLogix container smaller?
Not by lowering SizeInMBs; that only ever increases. Delete data with frx begin-edit-profile and let compaction reclaim the space, or copy the profile into a new container with frx migrate-vhd, after testing on a copy.
Why isn't FSLogix compacting my containers?
Usually because the Optimize Drives (defragsvc) or Storage Spaces SMP (smphost) service is disabled, the disk is fixed size, or less than 20% of a container over 1 GB could be reclaimed. The profile log and events 57 to 63 say which.
Does FSLogix compaction slow down sign-out?
Yes, by 20 to 30 seconds on average according to Microsoft, capped at 5 minutes. A user who signs back in while it's still running gets a temporary profile by default.
Should I use VHD or VHDX for FSLogix?
VHDX. The default is still VHD, but Microsoft recommends VHDX for its supported size and fewer corruption scenarios.
FSLogix settings, thresholds and event IDs are from Microsoft Learn as of November 2026: configuration settings, configure profile containers, VHD disk compaction, compaction troubleshooting, compaction reference, container size troubleshooting, the FAQ and frx. Atlas AVD behavior is described as of November 2026.