Jump to content











Photo
- - - - -

Suddenly problem with mount imdisk on start


  • Please log in to reply
5 replies to this topic

#1 RequiemMG

RequiemMG
  • Members
  • 4 posts
  •  
    Germany

Posted 25 November 2015 - 03:00 PM

Hi,

 

I have a weird problem with my imdisk installation.

 

I run a Windows Home Server 2011 (based on Windows Server 2008 R2), which I also use as MediaPortal TV server. I use imdisk to have my timeshiftbuffer in RAM. I run a script c:\imdisk\startimdisk.cmd from the task scheduler. This script has run unmodified for years now.

 

imdisk -a -s 2G -m e: -p "/fs:ntfs /V:Timeshift /q /y"
md e:\timeshift
net share timeshift=e:\timeshift /grant:Jeder,FULL

 

NTFS permissions are set correctly on both file and directory.

The task (which I also tried to delte an re-create with the same result) runs on system start with SYSTEM account and highest privileges.

 

 

Last week, I had issues with my homegroup settings and fiddled around on the server. On this occasion I unmounted the E: Ramdisk once and assigned another drive this letter (only temporary) and removed it again. On the next reboot, I had drive E nonaccessible with a blue questionmark. I found and deleted some registry entries (HKLM\ControlSet01\Control\SessionManager\DOS devices) Key E:, Value \Devices\ImDisk0 and similar entries on

the registrie pointing to E: as I wanted to get rid of this ghost device. Maybe I deleted something there which I shouldn't have...

 

When I run the script above when logged into the server, it completes without any problem. I I run it from the task scheduler, I always get a 0x2 result code, while the event log in windows tells me that the script has run completely with this return code (no access denied, no file not found etc).

 

I uninstalled imdisk and rebooted, installed the lastest version, no change.

 

I have put a pipe to create a log file. When run from a logged on user, everthing is normal. When run by the task scheduler, only the commands of the script itself are being logged (weird...).

 

I have tried putting back the registry mentioned above, which gives me back e: with a blue questionmark. But it does not change the behaviour of the startup initialization failing.

 

The driver is set to start automatically.

 

I have no more idea what to do about this task failing. Any solution or workaround is appreciated.



#2 Olof Lagerkvist

Olof Lagerkvist

    Gold Member

  • Developer
  • 1448 posts
  • Location:Borås, Sweden
  •  
    Sweden

Posted 25 November 2015 - 06:42 PM

When you created the log, did you by any chance redirect just output data and not error messages?

 

imdisk -a -s 2G -m e: -p "/fs:ntfs /V:Timeshift /q /y" > C:\log.txt 2>&1

 

Notice the 2>&1 which redirects error messages to the same place as output data.



#3 RequiemMG

RequiemMG
  • Members
  • 4 posts
  •  
    Germany

Posted 26 November 2015 - 08:27 PM

No, I just put it to >log.txt, which did not show any errors.

 

I have found a solution, which seem strange to me, but is working.

I put a "timout 20" at the beginning of the .cmd batch file. The it will initialize without issues. The only possible solution I can think of is that the boot sequence may be faster after I have finished troubleshooting my homegroup issues and the driver is not ready. But as it is set to automatic, I thought that it should be...



#4 Olof Lagerkvist

Olof Lagerkvist

    Gold Member

  • Developer
  • 1448 posts
  • Location:Borås, Sweden
  •  
    Sweden

Posted 26 November 2015 - 09:24 PM

Thanks for testing. What I meant was that I suspected that you just had a > log.txt redirection and that doesn't redirect error messages. Could you please add 2>&1 as in my example and try again? You should get the error messages too in the log that way.
  • RequiemMG likes this

#5 RequiemMG

RequiemMG
  • Members
  • 4 posts
  •  
    Germany

Posted 27 November 2015 - 09:05 PM

Will do in the next few days for testing purposes, thanks for your effort.


  • Olof Lagerkvist likes this

#6 RequiemMG

RequiemMG
  • Members
  • 4 posts
  •  
    Germany

Posted 28 November 2015 - 09:02 PM

This is what happens with the timeout command at the beginning of the .cmd file using

imdisk -a -s 2G -m j: -p "/fs:ntfs /V:Timeshift /q /y" > C:\log.txt 2>&1

 

Der Typ des Dateisystems ist RAW.
Das neue Dateisystem ist NTFS.
Formatieren mit Schnellformatierung 2048 MB
Struktur des Dateisystems wird erstellt.
Formatieren beendet.                         
       2,0 GB Speicherplatz insgesamt.
       2,0 GB sind verfgbar.
Creating device...
Created device 0: J: -> Image in memory
Formatting disk J:...
Notifying applications...
Done.

 

What's strange, the job is not finished; the task scheduler always says "is being executed right now". Don't know why...

 

 

When I delete the timeout command, I get an access denied error:

 

Error loading ImDisk Virtual Disk Driver: Zugriff verweigert

 

Any solution to this?






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users