Posted by Eswar Koneti on 26th May 2012
Question from Community : When client downloaded a package into the cache and is removed from the collection with the advertisement will the content stay in the cache? Then if you put the client back into the collection later will it download the package or will is run from the cache if the content stays?
Configuration manager will not clean up the content from the cache, files will be available and usable. Content is not specific to any advertisements OR collection memberships. Clients simply require the content and a version of that content; if it’s already in the client cache, it just uses it else it will download and run.
For more information about how sccm client cache works refer http://support.microsoft.com/kb/839513
Here is the script (from Shane Alexander) with little changes that works on both X86 and X64 OS looks into cache folder with folder name like x-x-x-x.1.System (X is random digits) and pipes the folder names to cache.txt file and remove each folder by reading one by one.
On Error Resume Next
Set objFSO = CreateObject("Scripting.FileSystemObject")
Set objShell = WScript.CreateObject("WScript.Shell")
‘Delete all software update caches
If objFSO.FolderExists("C:\Windows\System32\ccm\cache") Then
objShell.Run ("cmd /c dir /b c:\windows\system32\ccm\cache\*-*-*-*-*.1.System>c:\temp\caches.txt")
else
objShell.Run ("cmd /c dir /b c:\windows\syswow64\ccm\cache\*-*-*-*-*.1.System>c:\temp\caches.txt")
End If
If objFSO.FileExists ("C:\temp\caches.txt") Then
Set objFile = objFSO.OpenTextFile("C:\temp\caches.txt", 1)
Do Until objFile.AtEndOfStream
strLine = objFile.ReadLine
‘Wscript.Echo strLine
dirPath = "c:\windows\system32\ccm\cache\" & strLine
‘Wscript.Echo dirPath
objFSO.DeleteFolder dirPath, True
Wscript.Sleep 10
Loop
objFile.Close
End If
Wscript.Quit(0)
You can also power shell script to do this activity ,for more info please refer http://www.myitforum.com/absolutenm/templates/Articles.aspx?articleid=18962&zoneid=89
Tags: Cache packages, Cache size, configmgr, configuration Manager, SCCM, SCCM 2007, script to remove cache folders, script to remove sccm client cache folder, software update files removal from cache, VB Script
Posted in SCCM 2007, Scripting, Software Updates | No Comments »
Posted by Eswar Koneti on 30th January 2012
SCCM client cache is location where it stores the packages on the client before any application runs from it.
The default location for the Configuration Manager client cache is %windir%\ccmcache and the default disk space is 5120 MB.
The Configuration Manager client downloads the content for required software soon after it receives the deployment but waits to run it until the deployment scheduled time. At the scheduled time, the Configuration Manager client checks to see whether the content is available in the cache. If content is in the cache and it is the correct version, the client always uses this cached content. However, when the required version of the content has changed or if the content was deleted to make room for another package, the content is downloaded to the cache again.
If the client attempts to download content for a program or application that is greater than the size of the cache, the deployment fails because of insufficient cache size and Configuration Manager generates status message ID 10050. If the cache size is increased later, the download retry behavior is different for a required program and a required application:
- For a required program: The client does not automatically retry to download the content. You must redeploy the package and program to the client.
- For a required application: Because an application deployment is state-based, the client automatically retries to download the content when it next downloads its client policy.
If the client attempts to download a package that is less than the size of the cache but the cache is currently full, all required deployments keep retrying until the cache space is available, until the download times out, or until the retry limit is reached for the cache space failure. If the cache size is increased later, the Configuration Manager client attempts to download the package again during the next retry interval. The client tries to download the content every four hours until it has tried 18 times.
Cached content is not automatically deleted but remains in the cache for at least one day after the client used that content. If you configure the package properties with the option to persist content in the client cache, the client does not automatically delete the package content from the cache. If the client cache space is used by packages that have been downloaded within the last 24 hours and the client must download new packages, you can either increase the client cache size or choose the delete option to delete persisted cache content.
More Via http://technet.microsoft.com/en-us/library/gg712288.aspx
Tags: Cache packages, Cache size, ConfigMgr Client cache, SCCM client Cache, size of Cache size, Some information about SCCM 2012 Client Cache
Posted in SCCM 2007, SCCM 2012, Trobleshooting Tips, Troubleshooting Issues | No Comments »