Jump to content

Formatting Offline File Cache and Disabling


Recommended Posts

Posted

Guys and Gals

 

We have taken over the management of the IT at a school and we have put in a new server, there are 80 or so pcs and laptops, we want to remove offline files from the computers but leave it on for Staff laptops.

 

Thats easy enough we can just disable the offline files using the following GPOs

 

Computer Config > Admin Templates > Network > Offline Files

 

Allow or Disallow use of the Offline Files feature - Disabled

 

Prohibit user configuration of Offline Files - Enabled

 

Synchronise all offline files when logging on - Disabled

 

Synchronise all offline files before logging off - Disabled

 

Remove "Make Available Offline" - Enabled

 

This removes the Sync Manager on logoff, which is what i want, but this leaves all the Cache in c:\windows\csc sometimes there over 20GB in here, doing the CTRL SHIFT trick on each PC isnt an option really.

 

So we decided to do the registry entry as suggested in KB230738 which involves adding the key called FormatDatabase in the netcache key, we did this with a startu script and on reboot it didnt clear the CSC folder, so i did it as a shutdown script this and it didnt work either, the scripts where running as i made it echo, finally i made a GPO ADM file and ran gpupdate /force and you can see the key appear as it should but this didnt work either.

 

SO i turned off the GPO: Allow or Disallow use of the Offline Files feature

 

And then upon reapplying the policy and rebooing it worked it cleared, so great, it seems that the offline files cannot be off to format the cache (UNLESS ANYONE KNOWS DIFFERENTLY, as i cant find anything the back this up), but now the sync manager shows on logoff, and starts to sync all Redirected folders, so i set loopback polices to set the Policy: Do not automatically make redirected folders offline

 

This worked to stop the files syncing but the sync manager still shows briefly, which can be clicked to setup a few things which i don want. Even options for sync on logon and logoff are ticked even though GPOs say not to.

 

What i really want is to clear the cache and disable offline files INCLUDING the sync manager, does any one know how to achieve what i need to do?

 

Cheers

 

S

Posted (edited)

You'll have to hunt for this because I can't remember or find where I acquired the idea, but my murky old personal notes for offline files have a comment claiming you can clear the cache whilst CSC is enabled simply by zapping the %windir%\CSC folder in a shutdown script. Thus:

 

1) Disable CSC (and all the relevant policy settings)

 

2) Zap the %windir%\CSC folder

 

Should be fine.

 

I'd test it on one box first though i.e. ensure CSC happily remakes the folder and works if you enable it again.

 

PS: Got it - look for the text "Reset the Cache" in an article called "Introduction to Offline Files" on Jonathan Hardwick's blog

Edited by PiqueABoo
PS:
Posted

Hi

 

Thanks for the reply....

 

Has anyone else doen it this way, and does the folder regenerate if tuned back on, as we are not located at the school, so ant to have a plan before we go.

 

Cheers

 

S

  • 2 weeks later...
Posted
Just to add back on this to help anyone else out, we used a shutdown script to delete the CSC Folder and it works a treat, if you renable the offline files policy it recreates it.
Posted

We use this code to zap offline files,

 

REG ADD "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\NetCache" /v FormatDatabase /t REG_DWORD /d 1 /f
echo y|chkdsk c: /f
shutdown -r -t 1

zaps the cache and doesn't recreate it on reboot unless you reset it up.

Posted

Hi Chris

 

 

That doesnt work unless you have the policy Allow on disallow the use of offline files turned on.

 

We wanter to clear the cach and disable offline files, trouble is if offline files are off when you enter the format database key, it doesnt do anything, as the mobsync.dll must be disabled completely so can format the cache.

Posted

It works fine for us, still picking up problems from the previous lack of IT support in this school. That is the easiest way to zap the local cache and remove all files and settings from the workstation for offline files.

You will then be able to set all of the group policys for disabling offline files and the like.

Posted (edited)

Trouble is if the allow or dissallow policy has already applied it doesnt work, you have to enable offline files for the cache to be formatted, then wait for all the machines to be rebooted at least once then enter the formatecache key then turn off offline files again. You still get the sync manager otherwise on logoff

 

My method is easiest i think, turn off all offline files completley this turns off mobsync.dll so you dont get it on logoff, regardless of if there is files synced or not, then use a shutdown script to del CSC, and its gone.

Edited by Scorpio

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now



×
×
  • Create New...