docker-squid icon indicating copy to clipboard operation
docker-squid copied to clipboard

Mounting /data on NFS

Open sameersbn opened this issue 7 years ago • 3 comments

I'm trying to mount /data on an NFS mount. The idea is that I can boot up the image from any of my hosts in case one goes down. However, I'm getting the following error:

chown: changing ownership of/data/bind': Operation not permitted

Looks like the directories are initially created by nobody:nogroup.

Which user is attempting to change theh ownership? Is this because of the docker bridge network? How can I map /data to my NFS mount.

sameersbn avatar Mar 15 '18 16:03 sameersbn

➤ Diogo Monteiro commented:

I was having the same problem, had to tweak the export and mount settings to fix the issue.

sameersbn avatar Mar 15 '18 16:03 sameersbn

➤ Russ B commented:

@diogogmt, what settings on the client/server for your NFS mounts did you use to resolve the issue?

sameersbn avatar Mar 15 '18 16:03 sameersbn

@sameersbn It can be resolved if you change the ownership of the files as root to the squid user every boot/spin. The options is to either squash and force a specific uid and guid server side or make sure that these mounts allow root access to any mounting system. I did a similar thing with SSL BUMP which mounts the /var/squid/ssl_db directory on couple nodes. (multiple machines arenot supported for cached data, files or directory)

elico avatar Apr 24 '19 16:04 elico