1

Is there a way I can mount an NTFS filesystem on CoreOS?

I can't install ntfs-3g on CoreOS itself. I can create a docker image that has ntfs-3g installed and I can mount my NTFS drive within a docker container. However, I can't seem to find a way to make the mounted filesystem available anywhere other than in the container that mounted it.

oillio
  • 121
  • 1
  • 4

2 Answers2

1

It looks like the problem is that I am mounting with fuse. As per the below thread, it doesn't look like it is possible to get a fuse mount point out of a container: https://groups.google.com/forum/#!topic/docker-dev/_8bAG561VAI

I solved my problem by creating an NFS share within the mounting container and using that.

oillio
  • 121
  • 1
  • 4
0

If you run the container with the --privileged flag and bind mount it back to the host it can be made available to other containers:

First spawn the container as follows:

$ docker run --privileged -v /mnt:/data NTFSContainer

Then mount the device into /data inside the container

Now the files will be exposed to the underlying host and can be shared into other containers as well.

Brian Redbeard
  • 369
  • 3
  • 13
  • I've tried that. The mounted filesystem appears within the container, but on the host it is still an empty directory. I've tried to include /sys and /proc as volumes as well, no joy. – oillio Nov 08 '14 at 07:33
  • This might work with non-fuse mounts, though I think doing this with a non-fuse mount would be a pretty odd case. – oillio Nov 08 '14 at 20:33
  • Here is a video I did of a POC using the Gluster FUSE tools - https://www.youtube.com/watch?v=DjM0YqCkIz8&list=UUIG9tBpNZxYgNtWBYP1vCIA – Brian Redbeard Nov 08 '14 at 21:21
  • Correct me if I am wrong, but it looks like you are mounting a FUSE filesystem within a container, and then accessing that mount point from within the same container. I want to be able to then export that mount point to be used by other containers (with say --volumes-from), or from the host. I can access the mounted volume within the same container just fine, but it shows up as just an empty directory when I try to get access to it somewhere else. – oillio Nov 09 '14 at 06:40