You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by GitBox <gi...@apache.org> on 2020/10/06 07:35:16 UTC

[GitHub] [cloudstack] ustcweizhou opened a new pull request #4380: RBD: support multiple MON hosts

ustcweizhou opened a new pull request #4380:
URL: https://github.com/apache/cloudstack/pull/4380


   ## Description
   <!--- Describe your changes in detail -->
   
   <!-- For new features, provide link to FS, dev ML discussion etc. -->
   <!-- In case of bug fix, the expected and actual behaviours, steps to reproduce. -->
   
   <!-- When "Fixes: #<id>" is specified, the issue/PR will automatically be closed when this PR gets merged -->
   <!-- For addressing multiple issues/PRs, use multiple "Fixes: #<id>" -->
   <!-- Fixes: # -->
   
   ## Types of changes
   <!--- What types of changes does your code introduce? Put an `x` in all the boxes that apply: -->
   - [ ] Breaking change (fix or feature that would cause existing functionality to change)
   - [ ] New feature (non-breaking change which adds functionality)
   - [ ] Bug fix (non-breaking change which fixes an issue)
   - [X] Enhancement (improves an existing feature and functionality)
   - [ ] Cleanup (Code refactoring and cleanup, that may add test cases)
   
   ## Screenshots (if appropriate):
   ![ceph-rbd](https://user-images.githubusercontent.com/3204966/95172103-22d92d80-07b7-11eb-8d22-0c6dd7e707f1.PNG)
   
   details
   
   ![ceph-rbd-details](https://user-images.githubusercontent.com/3204966/95172129-2d93c280-07b7-11eb-84b3-f24bc5c495b6.PNG)
   
   ## How Has This Been Tested?
   <!-- Please describe in detail how you tested your changes. -->
   <!-- Include details of your testing environment, and the tests you ran to -->
   <!-- see how your change affects other areas of the code, etc. -->
   
   
   <!-- Please read the [CONTRIBUTING](https://github.com/apache/cloudstack/blob/master/CONTRIBUTING.md) document -->
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] weizhouapache commented on pull request #4380: RBD: support multiple MON hosts

Posted by GitBox <gi...@apache.org>.
weizhouapache commented on pull request #4380:
URL: https://github.com/apache/cloudstack/pull/4380#issuecomment-704286306


   > What does this add? Librados/RBD already handles this by creating a Round Robin DNS name pointing to all three IPs.
   
   @wido libvirt also supports multiple monitors. this provides another option.
   
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] rohityadavcloud commented on pull request #4380: RBD: support multiple MON hosts

Posted by GitBox <gi...@apache.org>.
rohityadavcloud commented on pull request #4380:
URL: https://github.com/apache/cloudstack/pull/4380#issuecomment-1004727059


   @weizhouapache I've verified this, it works but not in the syntax you've shared but:
   ```
   <pool type='rbd'>
     <name><name uuid here></name>
     ....
     <source>
       <host name='192.168.1.11'/>
       <host name='192.168.1.12'/>
       <host name='192.168.1.13'/>
       <name><name of ceph rbd pool here></name>
       <auth type='ceph' username='cloudstack'>
         <secret uuid='<uuid here>'/>
       </auth>
     </source>
   </pool>
   ```
   https://libvirt.org/storage.html#StorageBackendRBD
   
   DNS is good solution @wido but some people including me may like this solution.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] weizhouapache closed pull request #4380: RBD: support multiple MON hosts

Posted by GitBox <gi...@apache.org>.
weizhouapache closed pull request #4380:
URL: https://github.com/apache/cloudstack/pull/4380


   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] sureshanaparti commented on a change in pull request #4380: RBD: support multiple MON hosts

Posted by GitBox <gi...@apache.org>.
sureshanaparti commented on a change in pull request #4380:
URL: https://github.com/apache/cloudstack/pull/4380#discussion_r500744207



##########
File path: plugins/storage/volume/default/src/main/java/org/apache/cloudstack/storage/datastore/lifecycle/CloudStackPrimaryDataStoreLifeCycleImpl.java
##########
@@ -141,6 +141,9 @@ public DataStore initialize(Map<String, Object> dsInfos) {
 
         URI uri = null;
         try {
+            if (url != null && url.startsWith("rbd://")) {

Review comment:
       in case the url scheme is not case sensitive, can use:
   
   ```suggestion
               if (url != null && url..toLowerCase().startsWith("rbd://")) {
   ```
   
   (or)
   
   ```suggestion
               if (StringUtils.startsWithIgnoreCase(url, "rbd://")) {
   ```
   




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] ustcweizhou closed pull request #4380: RBD: support multiple MON hosts

Posted by GitBox <gi...@apache.org>.
ustcweizhou closed pull request #4380:
URL: https://github.com/apache/cloudstack/pull/4380


   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] weizhouapache commented on pull request #4380: RBD: support multiple MON hosts

Posted by GitBox <gi...@apache.org>.
weizhouapache commented on pull request #4380:
URL: https://github.com/apache/cloudstack/pull/4380#issuecomment-704988727


   > The PR currently only contains one commit and just a few changes. This seems incomplete to me.
   > 
   > Where do we generate the Libvirt XML?
   
   @wido this does not require any other code changes in kvm plugin.
   in libvirt pool definition, it uses host ips instead of single host ip.
   
   ```
   <pool type='rbd'>
     <name>uuid</name>
     <uuid>uuid</uuid>
     <capacity unit='bytes'>aaaaaa</capacity>
     <allocation unit='bytes'>aaaaaa</allocation>
     <available unit='bytes'>aaaaaa</available>
     <source>
       <host name='10.11.118.42,10.11.118.43,10.11.118.44' port='6789'/>
       <name>ceph-rbd</name>
       <auth type='ceph' username='cloudstack'>
         <secret uuid='60a41767-1196-3ff3-9105-19de5dc99fce'/>
       </auth>
     </source>
   </pool>
   ```


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] wido commented on pull request #4380: RBD: support multiple MON hosts

Posted by GitBox <gi...@apache.org>.
wido commented on pull request #4380:
URL: https://github.com/apache/cloudstack/pull/4380#issuecomment-704954017


   The PR currently only contains one commit and just a few changes. This seems incomplete to me.
   
   Where do we generate the Libvirt XML?


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] weizhouapache commented on pull request #4380: RBD: support multiple MON hosts

Posted by GitBox <gi...@apache.org>.
weizhouapache commented on pull request #4380:
URL: https://github.com/apache/cloudstack/pull/4380#issuecomment-704998823


   closed this ticket.
   
   I do not have a ceph testing env for now.
   I will open this ticket when I have verified everything works as expected.
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] weizhouapache edited a comment on pull request #4380: RBD: support multiple MON hosts

Posted by GitBox <gi...@apache.org>.
weizhouapache edited a comment on pull request #4380:
URL: https://github.com/apache/cloudstack/pull/4380#issuecomment-704988727


   > The PR currently only contains one commit and just a few changes. This seems incomplete to me.
   > 
   > Where do we generate the Libvirt XML?
   
   @wido this does not require any other code changes in kvm plugin.
   in libvirt pool definition, it uses host ips instead of single host ip.
   
   ```
   <pool type='rbd'>
     <name>uuid</name>
     <uuid>uuid</uuid>
     <capacity unit='bytes'>aaaaaa</capacity>
     <allocation unit='bytes'>aaaaaa</allocation>
     <available unit='bytes'>aaaaaa</available>
     <source>
       <host name='10.11.118.26,10.11.118.27,10.11.118.28' port='6789'/>
       <name>ceph-rbd</name>
       <auth type='ceph' username='cloudstack'>
         <secret uuid='60a41767-1196-3ff3-9105-19de5dc99fce'/>
       </auth>
     </source>
   </pool>
   ```


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] wido commented on pull request #4380: RBD: support multiple MON hosts

Posted by GitBox <gi...@apache.org>.
wido commented on pull request #4380:
URL: https://github.com/apache/cloudstack/pull/4380#issuecomment-704258924


   What does this add? Librados/RBD already handles this by creating a Round Robin DNS name pointing to all three IPs.
   
   There is no need to try and hack this into the URL. Redundancy can already be achieved with DNS.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org