Imdisk -a -s 3G -m Z: -p "/fs:ntfs /q /y " Import the tasks If you want to change the size, you need to edit the file boot_ramdisk.bat and change the size given ( 3G in the example): bat files.īy default, a ramdisk of 3 Gio is created. If you want to change, simply change the path in the 2. Currently, it is in D:\ramdisk\persistent. You also need to create a folder on your HDD/SSD where persistent files will be stored so you won't lose them amoung reboots. save_ramdisk_shutdown.xml: Windows task to save persistent files on lock and session logout.save_ramdisk.xml: Windows task to save persistent files every hours.RamDisk.xml: Windows task to create the ramdisk.launcher.vbs: to lauch the scripts silently (without creating a console popup).boot_ramdisk_save_persistent.bat: script to save the persistent files from the ramdisk to a drive.boot_ramdisk.bat: script to create and fill the ramdisk.In this folder, you should have at least the following files: You can store it in another folder, but then you'll need to change the scripts. Download the scriptsįirst, you need to download all the scripts and save them in C:\myscripts\. Here, we will see how to automate the creation of a ramdisk at boot, along with the save of persistent files like cache. Once installed, you can continue to next section. I use these scripts for my own, and as you can see, it may be improved. This means that in the worst case, you will lose 1 hour of cache for Firefox, which is not critical. The scripts shown here save the persistent files every hour and on lock / end of session, but not on shutdown. This doesn't matter for Firefox (in the worst case, the cache will be filled when Firefox is running).Īlso, in the non-professional versions of Windows, it is not possible to run a script on shutdown. Unfortunately, this means that, unlike on Linux, the cache folders will only be copied after you opened your session. you disable the ramdisk for the update and reenable it afterwards.Īs Windows doesn't support ramdisk by default, we need to use another (free and open-source) software: ImDisk.you don't store system temporary files in the ramdisk.However, for big updates, it seems that Windows expect some files to still be in the temporary folder after reboot, which will not be the case with a ramdisk, causing the failure of the update. ![]() The storage of temporary files has a big advantage in Windows: all these files are removed on reboot, which is not the case by default and so you lose a lot of space for nothing. But as long as the ramdisk is created, you can store whatever cache you want in it. This repo creates a ramdisk in Windows and show you how to store temporary data in it, along with Firefox's cache. Create a ramdisk for tmp and cache folders with persistent saves amoung reboots - for Windows.
0 Comments
Leave a Reply. |