In the 'minimum' configuration ImDisk starts and remains with the empty command window for about 3 minutes.
Then it continues like in the 'standard' case.
What is happening when loading the driver into the kernel?
The driver ImDisk kernel level driver is started by the Service Control Manager, which means that the module imdisk.sys is loaded into the kernel. Just ordinary calls to OpenSCManager(), OpenService(), StartService() ...
Which conditions must be fullfilled?
Just that the driver is installed properly in the registry and that the caller has administrative privileges...
But anyway, you can try to change the ImDisk driver in the registry to auto-start instead of demand-start so that it is loaded automatically when Windows is starting up. Then the driver will already loaded and ready in the kernel when the imdisk.exe command starts to create the RAM-disk. The registry value Start
controls wether the driver is loaded automatically by Windows. Set the value to 2
instead of 3
to have the driver auto-started. This is also configurable from .inf files that installs drivers and services.