NetBSD-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: mmap errors related to using encfs



Mayuresh <mayuresh%acm.org@localhost> writes:

> Trying out filesystems/fuse-encfs on NetBSD 8.0 amd64.
>
> # mount | grep puff
> /dev/puffs on /mnt/foo type puffs|refuse:encfs (nodev, nosuid)
>
> # cd /mnt/foo/
>
> # git init --bare
> error: unable to mmap '/mnt/foo/config': Operation not supported
> fatal: could not set 'core.filemode' to 'true'
>
> This problem occurs with encfs mounted directory only. From the error
> message it does not look like a git problem, rather some interaction
> between mmap and encfs.
>
> Would be interesting to know what's happening and is it possible to deal
> with this error.

The following hints may seem obvious, but because you didn't report on
your investigations into the source code of encfs and git, I'll send
them anyway :-)

I would suggest reading the encfs source code.  Likely it does not
support mmap, as that's pretty awkward to do for encrypted filesystems.
That should be ok, as mmap is typically used as an optimization with
normal operations as a fallback, or for specialized circumstances.

Then, you can read the git source code, and see 1) why it is using mmap
to change a value in a config file and 2) why it does not have fallback
to normal file operations if mmap fails, or 3) why the above guesses
about git are wrong and something else is going on.

Finally, if you determine that git does absolutely need mmap, you can
file a bug in git's bug-tracking system.



Home | Main Index | Thread Index | Old Index