C:\Windows\System32\Configuration\ConfigurationStatus directory growing

Hi,

i have installed PS V5 (5.0.10586.117).

In this directory (C:\Windows\System32\Configuration\ConfigurationStatus) i can find over 10000 GUID-0.mof files (each 55KB) which are created every 30 minutes.

It seems that these files are not being deleted. Can you please take a look and if you find also these files?

Is this a bug or a problem on my side?

Thanks

LCM Config:

Get-DscLocalConfigurationManager

ActionAfterReboot : ContinueConfiguration
AgentId : 81CD540E-DC4D-11E5-A65A-0050569E002D
AllowModuleOverWrite : True
CertificateID : xxx
ConfigurationDownloadManagers : {}
ConfigurationID : 64926d8b-2d60-4ec5-859b-7ec4e06adf9e
ConfigurationMode : ApplyAndAutoCorrect
ConfigurationModeFrequencyMins : 60
Credential :
DebugMode : {NONE}
DownloadManagerCustomData : {MSFT_KeyValuePair (key = “ServerUrl”), MSFT_KeyValuePair (key =
“AllowUnsecureConnection”)}
DownloadManagerName : WebDownloadManager
LCMCompatibleVersions : {1.0, 2.0}
LCMState : Idle
LCMStateDetail :
LCMVersion : 2.0
StatusRetentionTimeInDays : 10
PartialConfigurations :
RebootNodeIfNeeded : False
RefreshFrequencyMins : 30
RefreshMode : Pull
ReportManagers : {}
ResourceModuleManagers : {}
PSComputerName :

I have a scheduled task clearing that directory every 24 hours. Might be worth opening up an issue on UserVoice.

its already on GitHub and the PS team is aware of it.
Its the log files for the local database holding all the node information

I believe ive seen it on uservoice but if you dont find it, they yes open a new one.

There is a default retention policy of 10 days that can’t be customized in WMF 5.0 RTM. If you need to delete these files more aggressively you will have to use similar technique Zuldan is using.

Actually it can be customized using ‘StatusRetentionTimeInDays’ property of local configuration manager. However you can’t configure it for less than 24 hours.

[DSCLocalConfigurationManager()]
configuration Test
{
    settings
    {
        StatusRetentionTimeInDays = 1
    }
}

After doing some testing myself, I realized that retention policy is not working and DSC is not deleting files. Your best bet is to use some scheduler to delete those files if you don’t need them.

I’ve opened up a UserVoice for the issue https://windowsserver.uservoice.com/forums/301869-powershell/suggestions/14343861-dsc-statusretentiontimeindays-is-not-deleting-file

Hopefully it can be fixed in WMF 5.1

Thanks Zuldan.