Skip to contentSkip to conversation

Need to intercept open&write calls for vdi file when VirtualBox is working.

DISCUSSION Sergey Malykhin 2 participants 2 messages Mar 24, 2010

lore
Share & tools
lore
#0 lore raw

Hi,

My problem - I have to intercept open&write function calls to .vdi file when VirtualBox is working to control which sectors of vdi file were changed, i.e. I need to get 1. what file was open for writing; 2. data from buffer; 3. size of data; 4. offset in file;

I tryed:
- LD_PRELOAD - not helped

- using fuse - rewrote write call and successfully
intercepted, but fuse is slow.

I have possibilities to patch ext3 or patch inotify.

Is there any better way to do it?

TIA

#1 lore raw

Sergey,

Perhaps btrfs, or similar, would be a good starting point.

David