XCP-ng
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Register
    • Login
    1. Home
    2. eeldivad
    3. Best
    E
    Offline
    • Profile
    • Following 0
    • Followers 0
    • Topics 3
    • Posts 18
    • Groups 0

    Posts

    Recent Best Controversial
    • RE: How to return all data with xo-cli without limits

      @MathieuRA That worked! Thank you. I thought json was the default format and it seems --json must be right after the rest word. I tried putting it at the end and it didn't work but not a big deal. Thank you. How do you mark this post as resolved?

      posted in REST API
      E
      eeldivad
    • RE: How to expand a VM disk using xo-cli?

      @Gurve Even though I figured out how to do it all in xo-cli now, I haven't figured out how to build the filter search in the querystring using the API method you mentioned above. Could you give me a couple examples for my curiosity as I may need it in the future.
      &filter=[namelabelSearch]

      posted in REST API
      E
      eeldivad
    • RE: How to expand a VM disk using xo-cli?

      @Gurve I was trying it your way and then I noticed something in the doc where we can use xo-cli to call any REST method. So from your example we can do the following in xo-cli

      get all VMs
      xo-cli rest get vms

      get single vm with id. this includes the VDI disks IDs I needed
      xo-cli rest get vms/d55b0683-2fb9-7b06-6fa5-be6f2065e4b5

      get vdis for a vm by vm id
      xo-cli rest get vms/d55b0683-2fb9-7b06-6fa5-be6f2065e4b5/vdis

      get VDI details with vdi ID
      xo-cli rest get vdis/50436f36-5d5b-4048-9834-2cad0b869f66

      Thank you so much!! you solved my problem

      posted in REST API
      E
      eeldivad
    • RE: How to expand a VM disk using xo-cli?

      I figured out how to expand a VDI disk if I can get the id of the disk. But how do I get a list of disks attached to a VM if I have the name label of a vm? This is what I would run to get object details of the vm but I was hoping it would show a list of VDI ids attached to this VM but it doesn't.

      xo-cli list-objects name_label=vmtest1

      posted in REST API
      E
      eeldivad