What email address or phone number would you like to use to sign in to Docs.com?
If you already have an account that you use with Office or other Microsoft services, enter it here.
Or sign in with:
Signing in allows you to download and like content, and it provides the authors analytical data about your interactions with their content.
Embed code for: Script to clear SPTimer Cache
Select a size
Below is the script to clear SP config cache using PowerShell, script will do it for you on all the servers in the farm, only manual piece is stopping and starting of timer service on all the servers as automating that needs enabling PS remoting on SP Servers.
Add-PSSnapin -Name Microsoft.SharePoint.PowerShell –erroraction SilentlyContinue
read-host "Make sure you stop SPTImerV4 on all the servers in the farm before running this! If already stopped hit any key to continue"
$farm = Get-SPFarm
foreach($server in $farm.Servers)
if($server.Role -ne 'Invalid')
write-host "Working on Server :"$server.name -ForegroundColor DarkGreen
$path = "\\" + $server.name + "\C$\ProgramData\Microsoft\SharePoint\Config"
$folders = Get-ChildItem $path
foreach ($folder in $folders)
$items = Get-ChildItem $folder.FullName -Recurse
foreach ($item in $items)
if ($item.Name.ToLower() -eq "cache.ini")
$cachefolder = $folder.FullName
$cachefolderitems = Get-ChildItem $cachefolder -Recurse
foreach ($cachefolderitem in $cachefolderitems)
if ($cachefolderitem -like "*.xml")
$a = Get-Content $cachefolder\cache.ini
$a = 1
Set-Content $a -Path $cachefolder\cache.ini
read-host "Please start SPTimerV4 on all the Servers in the farm! If started press any key to continue"
Please get back to me in case of any suggestions or queries.