Manage cookie folders and other transactional folders
This article applies to Profile Management 3.1 and later.
The two procedures, mirroring folders and deleting stale cookies, are related. If you manage the Internet Explorer cookies folder, use both procedures. This step ensures transactional integrity while also reducing profile bloat involving Index.dat and browser cookies.
Mirroring can also be applied more widely because it can help solve similar issues involving any transactional folder (also known as a referential folder). These folders contain interdependent files, where one file references others. Mirroring folders allows Profile Management to process a transactional folder and its contents as a single entity, therefore avoiding profile bloat.
For example, consider how Index.dat references cookies while a user browses the Internet. A user has two Internet Explorer sessions, each on a different server, and they visit different sites in each session. Cookies from each site are added to the appropriate server. The user logs off from the first session (or in the middle of a session, if the active write-back feature is configured). Then the cookies from the second session replace the cookies from the first session. However, instead they are merged, and the references to the cookies in Index.dat become out of date. Further browsing in new sessions results in repeated merging and a bloated cookie folder.
Mirroring the cookie folder solves the issue. With this feature, Profile Management overwrites the cookies with those cookies from the last session each time the user logs off. Therefore, Index.dat stays up-to-date.
The cookie folder can become bloated in the following situations:
- Multiple sessions are involved
- Websites are revisited and stale cookies build up.
The second procedure in this topic solves the latter issue by removing the stale cookies from all profiles.
Settings required for Internet Explorer 10 and later versions for browser compatibility
CONFIGURE: Add the following folders under Mirroring:
- AppData\Local\Microsoft\Windows\INetCookies (Cookies location for Windows 8.1 platform)
- AppData\Roaming\Microsoft\Windows\Cookies (Cookies location for Windows 7 and Windows 8 platforms)
- AppData\Local\Microsoft\Windows\WebCache (Cookies database is maintained at Webcache01.dat)
Note:
- History: Browsing history from profiles of Profile Management Version 5.1 is not persisted.
- Cookies: Cookies created using profiles of Profile Management Version 5.1 or earlier are persisted.
- Stale cookies:
- In Profile Management Version 5.1 and earlier, these cookies are not handled and remain as a part of the profile until deleted manually.
- In Profile Management Version 5.2, when using Internet Explorer 10 and later, these cookies are handled in Protected and Normal modes.
The cookies and browsing history information in Internet Explorer 9 and earlier are not compatible with the information in Internet Explorer 10 and later. Users are advised not to move across multiple systems that have different versions of Internet Explorer installed. [#474200]
To mirror folders
Use this procedure for any transactional folders not just those folders that store cookies.
The Folders to mirror policy does not support scenarios where certain files in a folder or certain subfolders are mirrored. As a workaround, use the Folders to mirror policy with the Exclusion list – directories policy or the Exclusion list – files policy.
For example, in the case of Google Chrome, the bookmark-related files or subfolders in AppData\Local\Google\Chrome\User Data\Default
are interdependent. As a result, they must be synchronized as a single entity. To avoid profile bloat, follow these steps:
- Add
AppData\Local\Google\Chrome\User Data\Default
to the list of folders to mirror. - Add the files or subfolders unrelated to bookmarks in that folder to the exclusion list.
Caution:
Mirroring transactional folders can mean that the “last write wins.” Files that are modified in more than one session are overwritten by the last update. Changes to the user profile might be lost.
- Under Profile Management > File system > Synchronization, double-click the Folders to mirror policy.
- Select Enabled.
- Add the list of folders, relative to the root folder in the user store, that you want to mirror. Use Enter to separate multiple entries. This policy works recursively, so do not add subfolders to the list. For example, add AppData\Roaming\Microsoft\Windows\Cookies but not AppData\Roaming\Microsoft\Windows\Cookies\Low as well.
If Folders to mirror is not configured here, the value from the .ini file is used. If this setting is not configured here or in the .ini file, no folders are mirrored.
For your changes to take effect, run the gpupdate /force
command from the command prompt as documented at https://docs.microsoft.com/en-us/windows-server/administration/windows-commands/gpupdate.
To delete stale cookies
If you are using Internet Explorer 10 or later, this procedure is not required.
- Under Profile Management > Advanced Settings, double-click the Process Internet cookie files on logoff policy.
- Select Enabled.
- Click OK.
If Process Internet cookie files on logoff is not configured here, the value from the .ini file is used. If this setting is not configured here or in the .ini file, no processing of Index.dat takes place.
For your changes to take effect, run the gpupdate /force
command from the command prompt as documented at https://docs.microsoft.com/en-us/windows-server/administration/windows-commands/gpupdate.
Enabling Process Internet cookie files on logoff increases logoff times. Nevertheless, to maintain the integrity of the cookie folder, the supported configuration is to set both Folders to mirror and Process Internet cookie files on logoff, as the following best practice demonstrates:
To process cookie folders
- Under Profile Management > File system > Synchronization, double-click the Folders to mirror policy.
- Select Enabled.
- Add the list of folders, relative to the root folder in the user store, that you want to mirror. Add the folder Cookies for Version 1 profiles and AppData\Roaming\Microsoft\Windows\Cookies for Version 2 profiles.
- Under Profile Management > Advanced Settings, double-click the Process Internet cookie files on logoff policy. This step deletes the stale cookies referenced by Index.dat.
- Select Enabled.
- Click OK.
For your changes to take effect, run the gpupdate /force
command from the command prompt as documented at https://docs.microsoft.com/en-us/windows-server/administration/windows-commands/gpupdate.