Iv had it with filesystemwatcher

  • Thread starter Steel City Phantom
  • Start date
S

Steel City Phantom

i am building a content distribution system using the filesystemwatcher
to catch people moving files in and out of the system and update a
database. what happens is when a process runs that moves hundreds of
files (happens every day) i get all kinds of debug errors and an
unhandled exception. here is the debug log

First-chance exception at 0x7c342eee (msvcr71.dll) in VoiceScanner.exe:
0xC0000005: Access violation reading location 0x00233000.
An unhandled exception of type 'System.NullReferenceException' occurred
in system.dll

Additional information: Object reference not set to an instance of an
object.

First-chance exception at 0x791bcf3e in VoiceScanner.exe: 0xC0000005:
Access violation reading location 0x00e61ba4.
An unhandled exception of type 'System.ExecutionEngineException'
occurred in mscorlib.dll

The thread 'Win32 Thread' (0x980) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0x8a4) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0xb24) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0x510) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0xb0c) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0xaf8) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0x26c) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0xe0) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0xb10) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0x41c) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0x60c) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0x5a0) has exited with code -2146233082
(0x80131506).
HEAP[voicescanner.exe]: Dedicated (0004) free list element 18df90 is
wrong size (0036)
Unhandled exception at 0x77f813b1 in VoiceScanner.exe: User breakpoint.

when i try to capture the unhanded exception, the app gets stuck in an
infinate loop on the first chance exception line, the exception is never
captured. the exception seems random, its only triggered by large file
moves. my buffer on the filesystemwatcher is set to 256k so i know im
not overrunning the buffer, besides, if that happened, the
filesystemwatcher.error event would be fired.

any ideas? i have been working on this all day and the more and more i
look, the more and more it looks like a bug in the framework.
 
S

Steel City Phantom

ok, i have been working on this some more and have a few new details.
after messing with it i finally got this error

First-chance exception at 0x7c342eee (msvcr71.dll) in VoiceScanner.exe:
0xC0000005: Access violation reading location 0x00233000.
First-chance exception at 0x791b7eb8 in VoiceScanner.exe: 0xC0000005:
Access violation reading location 0x006901d4.

i looked on my system for msvcr71 and found about 12 copies of 2
different versions. i deleted all but the copy in win\sys and tried
again. same thing. then tried the other copy in win\sys and same deal

now one thing i did get it to do, which i havn't been able to duplicate
is in one test, i all of a sudden had tons of threads die and got this
error

HEAP[voicescanner.exe]: Heap entry 18c610 has incorrect PreviousSize
field (0075 instead of 0401)
Unhandled exception at 0x77f813b1 in VoiceScanner.exe: User breakpoint.
First-chance exception at 0x77fcca14 in VoiceScanner.exe: 0xC0000005:
Access violation writing location 0x0065006e.

now 401 happens to be the same amount of files that i move from one
directory to another. does filesystemwatcher create a new thread for
each file?

is there any way you can think of where i can capture this exception and
attempt to dump the filesystemwatcher buffer to figure this out? when i
try to capture it with the AppDomain.unhandled whenever the exception
occurs, it does not get sent to the error handle, it just gets locked in
an infinate loop and most of the time kills vstudio, and on a few
occations windows.


im out of ideas, i think this is a bug in the framework but i don't have
enough info to keep investigating it. any ideas?



Message by Steel City Phantom said:
i am building a content distribution system using the filesystemwatcher
to catch people moving files in and out of the system and update a
database. what happens is when a process runs that moves hundreds of
files (happens every day) i get all kinds of debug errors and an
unhandled exception. here is the debug log

First-chance exception at 0x7c342eee (msvcr71.dll) in VoiceScanner.exe:
0xC0000005: Access violation reading location 0x00233000.
An unhandled exception of type 'System.NullReferenceException' occurred
in system.dll

Additional information: Object reference not set to an instance of an
object.

First-chance exception at 0x791bcf3e in VoiceScanner.exe: 0xC0000005:
Access violation reading location 0x00e61ba4.
An unhandled exception of type 'System.ExecutionEngineException'
occurred in mscorlib.dll

The thread 'Win32 Thread' (0x980) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0x8a4) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0xb24) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0x510) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0xb0c) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0xaf8) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0x26c) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0xe0) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0xb10) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0x41c) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0x60c) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0x5a0) has exited with code -2146233082
(0x80131506).
HEAP[voicescanner.exe]: Dedicated (0004) free list element 18df90 is
wrong size (0036)
Unhandled exception at 0x77f813b1 in VoiceScanner.exe: User breakpoint.

when i try to capture the unhanded exception, the app gets stuck in an
infinate loop on the first chance exception line, the exception is never
captured. the exception seems random, its only triggered by large file
moves. my buffer on the filesystemwatcher is set to 256k so i know im
not overrunning the buffer, besides, if that happened, the
filesystemwatcher.error event would be fired.

any ideas? i have been working on this all day and the more and more i
look, the more and more it looks like a bug in the framework.
 
Z

zidanechina

Check whether you have any memory overwrite? or memory overflow?


Steel City Phantom said:
ok, i have been working on this some more and have a few new details.
after messing with it i finally got this error

First-chance exception at 0x7c342eee (msvcr71.dll) in VoiceScanner.exe:
0xC0000005: Access violation reading location 0x00233000.
First-chance exception at 0x791b7eb8 in VoiceScanner.exe: 0xC0000005:
Access violation reading location 0x006901d4.

i looked on my system for msvcr71 and found about 12 copies of 2
different versions. i deleted all but the copy in win\sys and tried
again. same thing. then tried the other copy in win\sys and same deal

now one thing i did get it to do, which i havn't been able to duplicate
is in one test, i all of a sudden had tons of threads die and got this
error

HEAP[voicescanner.exe]: Heap entry 18c610 has incorrect PreviousSize
field (0075 instead of 0401)
Unhandled exception at 0x77f813b1 in VoiceScanner.exe: User breakpoint.
First-chance exception at 0x77fcca14 in VoiceScanner.exe: 0xC0000005:
Access violation writing location 0x0065006e.

now 401 happens to be the same amount of files that i move from one
directory to another. does filesystemwatcher create a new thread for
each file?

is there any way you can think of where i can capture this exception and
attempt to dump the filesystemwatcher buffer to figure this out? when i
try to capture it with the AppDomain.unhandled whenever the exception
occurs, it does not get sent to the error handle, it just gets locked in
an infinate loop and most of the time kills vstudio, and on a few
occations windows.


im out of ideas, i think this is a bug in the framework but i don't have
enough info to keep investigating it. any ideas?



Message by Steel City Phantom said:
i am building a content distribution system using the filesystemwatcher
to catch people moving files in and out of the system and update a
database. what happens is when a process runs that moves hundreds of
files (happens every day) i get all kinds of debug errors and an
unhandled exception. here is the debug log

First-chance exception at 0x7c342eee (msvcr71.dll) in VoiceScanner.exe:
0xC0000005: Access violation reading location 0x00233000.
An unhandled exception of type 'System.NullReferenceException' occurred
in system.dll

Additional information: Object reference not set to an instance of an
object.

First-chance exception at 0x791bcf3e in VoiceScanner.exe: 0xC0000005:
Access violation reading location 0x00e61ba4.
An unhandled exception of type 'System.ExecutionEngineException'
occurred in mscorlib.dll

The thread 'Win32 Thread' (0x980) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0x8a4) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0xb24) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0x510) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0xb0c) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0xaf8) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0x26c) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0xe0) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0xb10) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0x41c) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0x60c) has exited with code -2146233082
(0x80131506).
The thread 'Win32 Thread' (0x5a0) has exited with code -2146233082
(0x80131506).
HEAP[voicescanner.exe]: Dedicated (0004) free list element 18df90 is
wrong size (0036)
Unhandled exception at 0x77f813b1 in VoiceScanner.exe: User breakpoint.

when i try to capture the unhanded exception, the app gets stuck in an
infinate loop on the first chance exception line, the exception is never
captured. the exception seems random, its only triggered by large file
moves. my buffer on the filesystemwatcher is set to 256k so i know im
not overrunning the buffer, besides, if that happened, the
filesystemwatcher.error event would be fired.

any ideas? i have been working on this all day and the more and more i
look, the more and more it looks like a bug in the framework.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top