in reply to Re^2: imitation block device in linux
in thread imitation block device in linux

Yeah, I'm trying to imitate a block device, one that can be accessed by programs like dd, or even mounted with the mount command. My intention is to intercept read/write/seek operations and manage the data as it goes back and forth (logging, encryption, etc). I was hoping to stay with perl, but it looks like I might have to spend some learning curve on C?

Replies are listed 'Best First'.
Re^4: imitation block device in linux
by zentara (Cardinal) on Mar 21, 2011 at 14:51 UTC
    I'm trying to imitate a block device, one that can be accessed by programs like dd

    Have you thought of making a ramdisk... it essentially makes a little disk device in your ram memory, which you can treat exactly like a disk.

    Google for ramdisk linux for many guides.

    UPDATE: I forgot to mention a loopback filesystem, where you can mount a file with the -o loop option and it acts like a disk device also.


    I'm not really a human, but I play one on earth.
    Old Perl Programmer Haiku ................... flash japh