Minio is an S3 compatible object storage system. It can be easily setup via docker or a static go binary and provides a nice web UI. The catch is that this system can only be used internally as public access to the storage bucket is required if you don’t want to configure anything else in SBT. Access a terminal for a running job. Generate the OpenSSH certificate-key pairs. Generate a set of random 20 & 64 character alpha.
The goal
I want to share/sync a common folder between 4 nodes.
You know like dropbox but without a 3td party server of course.
Let's see if (Minio Erasure Code) can help.
This doc is not on Minio website yet but it really helped me.
Create the folder to share between our 4 nodes:
Run this on all nodes:
About my path SOURCE:
mnt
is for things sharedminio
is the driver or the applications used to sharedev-d
is my cluster ID. It could beprod-a
,prod-b
,dev-b
...
Network
Run this the leader node:
Deploying 4 instances (Minio Erasure Code)
Run this the leader node:
Create your own MINIO_ACCESS_KEY and MINIO_SECRET_KEY values!
- Ensure access key = 5 to 20 characters
- Ensure secret key = 8 to 40 characters
docker service ls
logs from minio1
Status 1)
The services are running good.
Create a bucket
- Open a new tab on your browser
- Go to: http://ip10_0_25_6-9001.play-with-docker.com/minio
- Enter credits
- Create bucket 'tester'
- Upload a picture 'animated-good-job.gif' from the browser
On your 4 nodes, check if the file is there:
Minio Generate Random Access Key Free
Status 2)
When uploading a file from the web GUI, all nodes sync the files as expected. Good!
2/2 Testing file sharing by creating a file from the nodes
Then ...
from node3, Create dummy files (unit test)
You get the pattern at this point :)
from node4, Create dummy files (unit test)
You get the pattern at this point :)
Status 3)
Files are NOT SYNCED when they are created from the nodes. Is it normal?
Asking for help on Slack
Hello folks!
Regarding Minio Erasure Code Mode,
I want to share/sync a common folder between 4 nodes using Erasure Code Mode.
You know like dropbox (but without a 3td party main server of course).
I took many hours to test this setup and this is my conclusion:
- When uploading a file from the web GUI, all nodes sync the files as expected. Good!
- But files are NOT SYNCED when they are created from the nodes. Damm :-/
May I ask your help here?
https://github.com/minio/minio/issues/3713#issuecomment-279573366
Cheers!
Answers on Slack!
y4m4b4 [8:18 PM]
mounting a common DIR you can either use MinFS or S3FS
[8:18]
which would mount the relevant bucket on the nodes..
pascalandy [8:18 PM]
OK tell me about it :)))
y4m4b4 [8:18 PM]
https://github.com/minio/minfs#docker-simple
minio/minfs: A network filesystem client to connect to Minio and Amazon S3 compatible cloud storage servers
minfs - A network filesystem client to connect to Minio and Amazon S3 compatible cloud storage servers
all you need to do is this..
Minio Generate Random Access Key Generator
pascalandy [8:18 PM]
OMG!
You guys are doing this as well?!
You saved the day!
The missing part - Install the volume driver
docker volume create
Testing the volume within a container
Status 4)
By using our docker volume bucket-dev-e
we can mount the bucket into any container. Very good!
Using sub directories from a bucket.
This part is work in progress. See https://github.com/minio/minfs/issues/20
For all details about my setup, please check my post:
The complete guide to attach a Docker volume with Minio on your Docker Swarm Cluster
— — —
Minio Generate Random Access Keyword
Let’s say that my Minio's bucket is named: bucket-dev-e
.
I mounted it here /mnt/minio00000/dev-e
using docker volume create …
Let's start one blog (This works perfectly):
What if I need to run multiple websites:
My challange is … the commands above are not working. By default we cannot specify subpaths bucket-dev-e/ghost/site2/images
from a Docker Volume.
What can we do ? (I DON’T KNOW THE ANSWER YET)
I don't want to use one Docker Volume for each of the 100x (potentially 1000x) site I’m hosting.
Any other ideas?
Conclusion
By using Minio along their minfs (https://github.com/minio/minfs) we can have best of both worlds.
A solid object storage and connect Docker volume to this storage. Any container can have access to the bucket created in Minio.
Another great thing with Minio is that you don't have to pre-define disk space (like GlusterFS, Infinit, Portworx, etc). Minio use whatever space you have a disk.
You can also create another data store easily on hyper.sh and rock to the world. It's been a long journey and now this will help me to move to production.
Cheers!
Pascal Andy | Twitter
[
Don't be shy to buzz me 👋 on Twitter @askpascalandy. Cheers!