25
Nov
Nov
During one of our projects, we had to increase all the client cache sizes to 7.5GB (and later even more) regarding some ‘nice’ 3rd party applications which stored a large amount of files in the cache.
We used this script as a pre-requirement to the of the SCCM package, which was rolled out by SMS. The code could be written a whole lot shorter, but we used it to set some additional things as well, therefore the ‘large’ formatting ![]()
extend_cache.vbs
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | Dim objSetCache, objCache, objCacheSize objCacheSize = 7500 Set objSetCache = createobject("UIResource.UIResourceMgr") Set objCacheInfo = objSetCache.GetCacheInfo If objSetCache Is Nothing Then Wscript.Quit End If Set objCache = objSetCache.GetCacheInfo() If objCache Is Nothing Then Set objSetCache = Nothing Wscript.Quit End If objCache.TotalSize = objCacheSize objCacheInfo.Location = "D:\CommonUserData" 'Msgbox("Cache increased to 5GB") |