gluster / gluster-kubernetes

GlusterFS Native Storage Service for Kubernetes
Apache License 2.0
875 stars 389 forks source link

gluster-block needs to dynamically create /dev/uio* devices #545

Closed nixpanic closed 5 years ago

nixpanic commented 5 years ago

By not bind-mounting /dev in the container anymore, gluster-block fails to create block-volumes. Unfortunately bind-mounting /dev is not possible with CRI-O, so we came up with a different approach to reach the same goal.

The gluster/gluster-container#115 change introduces a feature in the early start script for the glusterfs-server container. It is now possible to mount --rbind an alternative /dev from the host onto the /dev path in the container.

It also has been noticed that CRI-O secures /sys more than Docker does. tcmu-runner (part of gluster-block) needs write access to /sys/module and /sys/class.

With these two changes, gluster-block functions again on recent versions of OpenShift, both with Docker and CRI-O runtimes.


This change is Reviewable

centos-ci commented 5 years ago

Can one of the admins verify this patch?

nixpanic commented 5 years ago

ok to test

nixpanic commented 5 years ago

ok to test

nixpanic commented 5 years ago

add to whitelist

nixpanic commented 5 years ago

In addition to the required changes for gluster-block, two patches have been included so that the CentOS CI works again. @jarrpa @obnoxxx let me know if I should move those out into their own PR.

nixpanic commented 5 years ago

On Mon, Jan 07, 2019 at 05:30:38PM +0000, Jose A. Rivera wrote:

jarrpa requested changes on this pull request.

The CentOS CI patches should be moved to their own PR, yes. :)

Done. This PR is now rebased on top of https://github.com/gluster/gluster-kubernetes/pull/551 which needs to be merged first.

jarrpa commented 5 years ago

retest this please