Public Repository

Last pushed: an hour ago
Short Description
OpenEBS is purpose built storage for containerized environments, written in Go
Full Description

Jiva is a Docker image for creating OpenEBS Volumes. OpenEBS Volume provide block storage to your application containers. OpenEBS Volume - is itself launched as a container, making OpenEBS a true Container Native Storage for Containers.

A OpenEBS Volume comprises of:

  • One Controller (or Frontend-Container) that exposes storage via iSCSI, TCMU etc., and can be launched along side your application container.
  • One or more Replicas (or Backend-Containers) that will persist the data, providing redundancy and high-availability. The Replica container will save the data into the storage (disks) attached to your docker hosts.

Both controller and replica can be launched using this same image openebs/jiva, by passing different launch arguments. The controller expects the volume details like - name and size, where as the replica will require the controller to which it is attached, and the mount path - where it has to store the data.

The scheduling of the controller and replica containers of OpenEBS Volume is managed by maya that integrates itself into Container Orchestrators like Kubernetes, Docker Swarm, Mesos or Nomad. OpenEBS v0.4.0, provides integration into Kubernetes Clusters. Please follow OpenEBS documentation, if you are using Kubernetes.

For other types of Container Orchestrators like Docker Swarm, Mesos, Nomad, etc., the following instructions will help you to quickly setup an OpenEBS Volume (exposed via iSCSI) with 2 replicas. To enable redundancy, the replicas have to be run on different hosts.


Setup the storage network.

To launch a OpenEBS Volume with 2 replica, you will require three IPs one for the controller (where iSCSI service will be started) and 2 for the replicas. This example uses static IPs with host networking mode, but you can set this up using your preferred network plugin, that allows multi-host networking.

Let us say that is accessible across different docker hosts ( host#1, host#2).

Create the static IPs on host#1, where you can create Controller and Replica-1.

host#1$ sudo ip addr add dev eth0
host#1$ sudo ip addr add dev eth0


Create the static IP on host#2, where you can create Replica-2

host#2$ sudo ip addr add dev eth0


Setup the storage disks

The backend containers will need to provided with the storage (directory) where the data will be persisted. The directory should be accessible via the containers. One host1 and host2, setup create a directory on the disk that has sufficient space for holding the volume. (Again, these operations are taken care by the Storage Orchestrator - Maya, if you are using Kubernetes).

host#1$ mkdir /mnt/store1


host#2$ mkdir /mnt/store2


Launch Controller

Create a controller on host#1, that will create demo-vol1 with capacity of 10G.

host#1$ sudo docker run -d --network="host" -P --expose 3260 --expose 9501 --name ctrl openebs/jiva launch controller --frontend gotgt --frontendIP demo-vol1 10G


Launch Replica

Create the Replica on host#1, for demo-vol1 with data stored in /mnt/store1

docker run -d --network="host" -P --expose 9502-9504 --expose 9700-9800 -v /mnt/stor1:/stor1 --name replica-1 <openebs/jiva> launch replica --frontendIP --listen --size 10G /stor1

Create the backend container on host#2, for demo-vol1 with data stored in /mnt/store1

docker run -d --network="host" -P --expose 9502-9504 --expose 9700-9800 -v /mnt/stor2:/stor2 --name replica-2 <openebs/jiva> launch replica --frontendIP --listen --size 10G /stor2


Using the iSCSI volume

The volume created from the above containers can be used via the iSCSI plugin or iscsiadm by using the following details:

Portal :

For further info, checkout or join the slack#

Docker Pull Command