SerCeMan / jnr-fuse

FUSE implementation in Java using Java Native Runtime (JNR)
MIT License
365 stars 87 forks source link

"mmap failed for CEN and END part of zip file" with direct_io #57

Open jupitergao opened 6 years ago

jupitergao commented 6 years ago

I implement a filesystem base on jnr-fuse. testing cp into my fs without direct_io option, write method called 18000 times per second and get 4k bytes every time (70M/s). while mounted with direct_io, write method called 3600 times per second and get 128k bytes every time (450M/s). so I add direct_io option in mount. but when i run java and other program using mmap , it fails and says "mmap failed for CEN and END part of zip file", how can I deal with it? or how can I improve non-direct_io performance? Thanks.

SerCeMan commented 6 years ago

Hi, @jupitergao!

I'm not sure if I fully understand the problem. Quick googling showed quite a few issues where this exception can be thrown with no relation to fuse. Could you provide a test case that can help to reproduce this problem?

jupitergao commented 6 years ago

I found a closed issue for libfuse here https://github.com/libfuse/libfuse/issues/152 . It's not a jnr-fuse problem.

jupitergao commented 6 years ago

To reproduce this problem, just copy jdk into a fuse filesystem(mounted with direct_io),then run "./bin/java". Sorry for my pool english.