Wednesday, June 8, 2011

Windows 7 network share refresh problems

Recently when I have attempted to access network shares using a Windows 7 client, I would often be unable to see newly created files/folders. Even if I create the folder myself via the client, sometimes it would not appear, and pressing F5/refresh would not help!

Sometimes I would also delete a file, and whilst the file would be deleted it would still show in the folder view!

After a bit of digging, the following seemed to do the trick:

1. Backup your registry.

2. Edit your registry and go to  HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters

3. Create the following DWORD values:
  • FileInfoCacheLifetime = 0
  • FileNotFoundCacheLifetime = 0
  • DirectoryCacheLifetime = 0
4. Reboot the machine.