I’ve. problem like others mounting external volumes with Docker, in particular with NFS.
In my case I’m using a graphite container trying to store data on an NFS mounted directory.
No matter if I mount the NFS in the container (via volume) or in the docker host, I get the same error, which is not present when the directory is local.
I also tried to enter into the docker shell and I’m able to create/delete files from the mounted directory without any problem, so apparently it’s not a permission issue.
This is my error
graphite_1 | 11/03/2019 07:06:30 :: [console] Error creating carbon.agents.2fe0e1ff2c9a-a.metricsReceived: [Errno 95] fallocate
graphite_1 | 11/03/2019 07:06:30 :: [console] Unhandled Error
graphite_1 | Traceback (most recent call last):
graphite_1 | File “/opt/graphite/lib/python3.6/site-packages/twisted/python/threadpool.py”, line 266, in
graphite_1 | inContext.theWork = lambda: context.call(ctx, func, *args, **kw)
graphite_1 | File “/opt/graphite/lib/python3.6/site-packages/twisted/python/context.py”, line 122, in callWithContext
graphite_1 | return self.currentContext().callWithContext(ctx, func, *args, **kw)
graphite_1 | File “/opt/graphite/lib/python3.6/site-packages/twisted/python/context.py”, line 85, in callWithContext
graphite_1 | return func(*args,**kw)
graphite_1 | File “/opt/graphite/lib/carbon/writer.py”, line 189, in writeForever
graphite_1 | writeCachedDataPoints()
graphite_1 | — —
graphite_1 | File “/opt/graphite/lib/carbon/writer.py”, line 142, in writeCachedDataPoints
graphite_1 | state.database.create(metric, archiveConfig, xFilesFactor, aggregationMethod)
graphite_1 | File “/opt/graphite/lib/carbon/database.py”, line 145, in create
graphite_1 | self.sparse_create, self.fallocate_create)
graphite_1 | File “/opt/graphite/lib/python3.6/site-packages/whisper.py”, line 528, in create
graphite_1 | fallocate(fh, headerSize, remaining)
graphite_1 | File “/opt/graphite/lib/python3.6/site-packages/whisper.py”, line 93, in _py_fallocate
graphite_1 | raise IOError(res, ‘fallocate’)
graphite_1 | builtins.OSError: [Errno 95] fallocate
and this is the docker-composer I use (/opt/data is mounted via NFS) as I said I also tried to mount the NFS dir in the container, result and error is exactly the same.