<html>
  <head>
    <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    My proposal is for gdeploy to communicate with Heketi, glusterd, and
    the system itself to service requests from the administrator. 
    Communicate with Heketi for all volume allocation/deallocation, with
    glusterd for any modifications on the volume, and with the node
    operating system (if really necessary) for any required setup.<br>
    <br>
    The following is just a brainstorm, not a spec file by any means. 
    Just an idea of what the workflow could be like. <br>
    <br>
    Here is a possible workflow:<br>
    <br>
    # Admin: Create SSH keys<br>
    # Admin: Setup Heketi service<br>
      - Heketi configured with private SSH key.<br>
    # Admin: Raw nodes are setup only with the gluster service and the
    public ssh key.<br>
    # Admin: Create topology.json with clusters, nodes, zones, and
    devices.<br>
    Admin needs to create a topology.json file.  See example in <br>
<a class="moz-txt-link-freetext" href="https://github.com/heketi/vagrant-heketi/blob/master/roles/heketi/files/topology_libvirt.json">https://github.com/heketi/vagrant-heketi/blob/master/roles/heketi/files/topology_libvirt.json</a><br>
    * gdeploy topology load -json=topology.json<br>
      - Assume that the configuration of the location of the Heketi
    server is known, either by an environment<br>
        variable, configuration file, or switch.<br>
      - At this point Heketi has been loaded with the configuration of
    the data center.<br>
    # Display topology<br>
    * gdeploy topology show<br>
    <tt>Cluster [2345235]</tt><tt><br>
    </tt><tt> |- Node [my.node.com]</tt><tt><br>
    </tt><tt>    |- Device [/dev/sdb]</tt><tt><br>
    </tt><tt>    |- Device [/dev/sdc]</tt><tt><br>
    </tt><tt>Cluster [F54DD]</tt><tt><br>
    </tt><tt> |- Node...</tt><tt><br>
    </tt><tt>...</tt><br>
    <br>
    # Display node information<br>
    * gdeploy node info [hostname or uuid]<br>
    <br>
    # Create a volume <br>
    * gdeploy volume create -size=100<br>
    <br>
    # Create volumes from a configuration file<br>
    * gdeploy volume create -c volumes.conf<br>
    <br>
    $ cat volumes.conf<tt><br>
    </tt><tt>[volume]</tt><tt><br>
    </tt><tt>action=create</tt><tt><br>
    </tt><tt>volname=Gdeploy_test  &lt;-- optional</tt><tt><br>
    </tt><tt>transport=tcp,rdma  &lt;-- would need to be added to Heketi</tt><tt><br>
    </tt><tt>replica=yes</tt><tt><br>
    </tt><tt>replica_count=2</tt><tt><br>
    </tt><tt><br>
    </tt><tt>[clients]</tt><tt><br>
    </tt><tt>action=mount</tt><tt><br>
    </tt><tt>#volname=glustervol (If not specified earlier in 'volume'
      section</tt><tt><br>
    </tt><tt>hosts=node2.redhat.com</tt><tt><br>
    </tt><tt>fstype=glusterfs</tt><tt><br>
    </tt><tt>client_mount_points=/mnt/gluster</tt><br>
    <br>
    <br>
    # Set volume options, snapshots, etc.<br>
    These would first talk to Heketi to determine which servers are
    servicing this volume.<br>
    gdeploy can then communicate with glusterd to execute the volume
    modifications.<br>
    * gdeploy volume options &lt;vol name and cluster | UUID&gt;
    &lt;options=val&gt;<br>
    * gdeploy volume options &lt;vol name and cluster | UUID&gt;-c
    options.conf<br>
    <br>
    # Destroy a volume<br>
    Here gdeploy would first check for snapshots.  If there are none,
    then it would<br>
    request the work from Heketi.<br>
    <br>
    <br>
    These are just some possible methods of how they could interact.<br>
    <br>
    - Luis<br>
    <br>
    <div class="moz-cite-prefix">On 12/11/2015 02:16 AM, Sachidananda
      URS wrote:<br>
    </div>
    <blockquote
cite="mid:CAE44-AtHyTBFcFNYK8S1UOoswhq--H1P4x7_rb0bQA9h51h7kg@mail.gmail.com"
      type="cite">
      <div dir="ltr"><br>
        <div class="gmail_extra"><br>
          <div class="gmail_quote">On Fri, Dec 11, 2015 at 12:31 PM,
            Luis Pabon <span dir="ltr">&lt;<a moz-do-not-send="true"
                href="mailto:lpabon@redhat.com" target="_blank">lpabon@redhat.com</a>&gt;</span>
            wrote:<br>
            <blockquote class="gmail_quote" style="margin:0 0 0
              .8ex;border-left:1px #ccc solid;padding-left:1ex">I think
              at its simplest would be to specify workflow examples and
              how gdploy+Heketi would satisfy them.  I will be sending
              out some possible workflows tomorrow.<br>
            </blockquote>
            <div><br>
            </div>
            <div>Awesome, I will see if we can add something to it.<br>
               <br>
            </div>
            <blockquote class="gmail_quote" style="margin:0 0 0
              .8ex;border-left:1px #ccc solid;padding-left:1ex">
              <br>
              Also, there is a python Heketi client in the works right
              now which would benefit gdeploy:  <a
                moz-do-not-send="true"
                href="https://github.com/heketi/heketi/pull/251"
                rel="noreferrer" target="_blank"><a class="moz-txt-link-freetext" href="https://github.com/heketi/heketi/pull/251">https://github.com/heketi/heketi/pull/251</a></a>
              .<br>
              <span class="HOEnZb"><font color="#888888"><br>
                </font></span></blockquote>
            <div><br>
            </div>
            <div>Cool, will check this out.<br>
              <br>
            </div>
            <div>-sac<br>
            </div>
            <div> </div>
            <blockquote class="gmail_quote" style="margin:0 0 0
              .8ex;border-left:1px #ccc solid;padding-left:1ex"><span
                class="HOEnZb"><font color="#888888">
                  - Luis<br>
                </font></span>
              <div class="HOEnZb">
                <div class="h5"><br>
                  ----- Original Message -----<br>
                  From: "Sachidananda URS" &lt;<a moz-do-not-send="true"
                    href="mailto:surs@redhat.com">surs@redhat.com</a>&gt;<br>
                  To: "Luis Pabon" &lt;<a moz-do-not-send="true"
                    href="mailto:lpabon@redhat.com">lpabon@redhat.com</a>&gt;<br>
                  Cc: "Gluster Devel" &lt;<a moz-do-not-send="true"
                    href="mailto:gluster-devel@gluster.org">gluster-devel@gluster.org</a>&gt;<br>
                  Sent: Friday, December 11, 2015 1:54:18 AM<br>
                  Subject: Re: gdploy + Heketi<br>
                  <br>
                  Hi Luis,<br>
                  <br>
                  On Fri, Dec 11, 2015 at 12:01 PM, Luis Pabon &lt;<a
                    moz-do-not-send="true"
                    href="mailto:lpabon@redhat.com"><a class="moz-txt-link-abbreviated" href="mailto:lpabon@redhat.com">lpabon@redhat.com</a></a>&gt;
                  wrote:<br>
                  <br>
                  &gt; Hi Sachidananda,<br>
                  &gt;   I think there is a great opportunity to enhance
                  GlusterFS management by<br>
                  &gt; using gdeploy as a service which uses Heketi for
                  volume management.<br>
                  &gt; Currently, gdeploy sets up nodes, file systems,
                  bricks, and volumes.  It<br>
                  &gt; does all this with input from the administrator,
                  but it does not support<br>
                  &gt; automated brick allocation management, failure
                  domains, or multiple<br>
                  &gt; clusters.  On the other hand, it does have
                  support for mounting volumes in<br>
                  &gt; clients, and setting up multiple options on a
                  specified volume.<br>
                  &gt;<br>
                  &gt;   I would like to add support for Heketi in the
                  gdeploy workflow.  This<br>
                  &gt; would enable administrators to manage clusters,
                  nodes, disks, and volumes<br>
                  &gt; with gdeploy based on Heketi.<br>
                  &gt;<br>
                  &gt; What do you guys think?<br>
                  &gt;<br>
                  <br>
                  <br>
                  That would be great. Please let us know if you already
                  have a plan on how<br>
                  to make these two work.<br>
                  <br>
                  -sac<br>
                </div>
              </div>
            </blockquote>
          </div>
          <br>
        </div>
      </div>
    </blockquote>
    <br>
  </body>
</html>