One of my good friends has been having trouble with Java NIO code running on iSeries box (JDK 1.5). From what he's told me, the code is splitting a file up into chunks (part of the file to another smaller file). The same code has been operating on other iSeries boxes for some time with no problems.
//copy original data file content to temp file
long startPos = dataFile.length() - remaining;
long transferSize = maxSizeBytes - size;
size += inChannel.transferTo(startPos, transferSize, outChannel); //exception here
remaining -= size;
Here's the stack farce:
Caused by: java.io.IOException: Operation not supported. Map failed
at sun.nio.ch.FileChannelImpl.map0(Native Method)
He's been doing some investigation and all the causes he's found so far (file permissions of parent directory, out of memory, shared memory control QSHRMEMCTL switched off, use of SAN) haven't worked. What could be causing his troubles? Thanks!