Porting Advice
- Use a compiler that has 64 bit off_t type
- 32bits only gets you as far as 4GB, which is much too small for
modern disks. The programs need a 64bit
off_t
type.
- Use a libc that supports O_LONGFILE and lseek64
- These are common extensions to the file I/O API.
- Check that your system supports shared MAP_ANONYMOUS mmaps
- If it doesn't define
MAP_ANONYMOUS
, open and
map /dev/zero
instead.
If you don't have shared anonymous maps, you can back the mmap with
a file, which may be on ramdisk. If you don't have any of the above,
replace the mmap and msync with writes to the reply pipe.
Peter Benie <peterb@chiark.greenend.org.uk>
Linux RAID