Jump to content











Photo
- - - - -

ImDisk ramdisk persistent in Windows 10?


  • Please log in to reply
4 replies to this topic

#1 XIII

XIII

    Newbie

  • Members
  • 13 posts

Posted 28 August 2015 - 08:33 AM

I recently upgraded from Windows 7 to Windows 10. At the same time I have moved to the latest version of ImDisk (2.0.6) and started using the ImDisk tools provided on this forum (also latest version, containing ImDisk 2.0.6). In the past I used a RAM disk image, but currently I let it create a TEMP folder on the fly. Still I notice that the ramdisk is persistent! If I store files on it and shut down my PC they are back after a reboot...

 

What do I do wrong here?

 

(And: is there a way to create a second empty folder on the fly?)



#2 v77

v77

    Silver Member

  • Team Reboot
  • 602 posts
  •  
    France

Posted 28 August 2015 - 12:42 PM

I recently upgraded from Windows 7 to Windows 10. At the same time I have moved to the latest version of ImDisk (2.0.6) and started using the ImDisk tools provided on this forum (also latest version, containing ImDisk 2.0.6). In the past I used a RAM disk image, but currently I let it create a TEMP folder on the fly. Still I notice that the ramdisk is persistent! If I store files on it and shut down my PC they are back after a reboot...

 

What do I do wrong here?

 

Unless you are using ImDisk Toolkit with the synchronization feature at system shutdown, this means that you use a static ramdisk with the hybrid sleep of Windows enabled.
The hybrid sleep was introduced in Windows 8 to speed up the boot by writing onto the hard drive the state of the kernel, including the memory allocated by the drivers, that is, the memory of a static ramdisk.
The hybrid sleep is not used when you do a system restart. It's why a system restart will empty the content of the ramdisk.

If you want to avoid that, you need to disable the hybrid sleep. You can do that by using the following command in a command prompt with administrative privileges:
powercfg /h off

This issue has been discussed several times. Perhaps I should do something about that...

 

 

(And: is there a way to create a second empty folder on the fly?)

 

In the data tab of the RamDisk Configuration Tool, you can set a folder from which the content will be loaded.
For example, create a folder named C:\test, and a subfolder C:\test\empty. Use C:\test in the GUI and the content, that is, the folder named "empty", will be copied into the ramdisk.


  • pscEx likes this

#3 XIII

XIII

    Newbie

  • Members
  • 13 posts

Posted 28 August 2015 - 06:50 PM

You use a static ramdisk with the hybrid sleep of Windows enabled. This issue has been discussed several times. Perhaps I should do something about that...

 

In the data tab of the RamDisk Configuration Tool, you can set a folder from which the content will be loaded.

 

Sorry about asking a FAQ. I had no idea... Thanks for explaining and both solutions!



#4 XIII

XIII

    Newbie

  • Members
  • 13 posts

Posted 29 August 2015 - 09:46 AM

Good to learn about this hybrid sleep!

 

It turns out that this also makes TrueCrypt volumes accessible without a password after shutdown because they are stored mounted (logged in)...

 

(I have now configured TrueCrypt to dismount when entering power save mode - which I should probably have done long time ago)



#5 v77

v77

    Silver Member

  • Team Reboot
  • 602 posts
  •  
    France

Posted 29 August 2015 - 11:56 AM

Hybrid sleep is indeed an important issue for privacy.
I forgot to say that the previously pointed command also disable the hibernation. But obviously, if you are using encryption tools, you'll want to avoid to write everything to the hard drive: unencrypted data, encryption keys...
By the way, if you don't use system encryption but still use ImDisk, you can take a look at my ProxyCrypt (but containers are not compatible).

 

I think to add an option to force the dismount of the ramdisk at system shutdown, but I wonder how to implement that. There is already a service used for waiting the system shutdown, but it cannot be used for that because it already process a pre-shutdown notification which prevents it to receive the final shutdown notification that would be required for dismounting the volume.
So, unless creating a new service, this could be difficult.
But there is already:
- "ImDisk Virtual Disk Driver Helper": used by the driver
- "ImDisk RamDisk starter": used by the Toolkit to mount the ramdisks at system boot
- "ImDisk Toolkit helper service": installed if you use the data synchronization at system shutdown
A 4th service might be a bit overkill...

 

An easier alternative would be to display a warning if the hybrid sleep is enabled and the user attempts to mount a static ramdisk, with a button to disable the hybrid sleep in one click (with, as a side effect, to also disable the hibernation because on Windows 8/8.1, disable only the hybrid sleep in the power policy does not work, I don't have checked yet on Windows 10 because it requires a physical machine).
But of course, with that, the system startup can be slower. So it's not an elegant solution.






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users