We have a Windows Server 2016 Terminal Server that frequently connects 100 users, and most are using a web browser after login. This is causing a huge browser cache load on the disk drives.
What would be the recommended process for creating a RAM disk for all these web browser cache files, and how can we apply this for all users? Your Cache Relocator application seems to only be for the one user invoking it, and we can't depend on each user to run the Cache Relocator correctly.
Indeed, moving the browser cache to a RAM disk can significantly reduce the load on your disk drives and potentially boost performance for your users. However, there are a few challenges in this process that need to be dealt with carefully:
As RAM is a scarce resource compared to disk storage, you will need to size the RAM disk appropriately to hold the cache files, keeping in mind that it will be shared across many users. For example, if each user uses a 500 MB cache, for 100 users it will take extra 50 GB of RAM.
Generally each user's cache can be moved to a RAM disk with this command (for Chrome):
Prior to this command, the existing Cache folder needs to be deleted as it will be replaced with the symbolic link. Likewise, the target path R:\Cache must already exist, not just for this command, but every time the browser is started.
To avoid clashing of cache files of multiple users, each symbolic links will have to go to a different folder, e.g. R:\Cache[USERNAME] and again, these paths must already exist whenever a symbolic link is created or the browser is started.
To automate this process for all users, you could create a PowerShell script that loops through all user directories, moves the cache to the RAM Disk, and creates a symbolic link.
Despite these challenges, if executed correctly, this process can result in considerable improvements.