1. 23 8月, 2019 1 次提交
  2. 04 3月, 2019 1 次提交
  3. 13 2月, 2019 1 次提交
  4. 12 2月, 2019 2 次提交
  5. 01 2月, 2018 1 次提交
  6. 08 11月, 2017 1 次提交
  7. 19 9月, 2017 1 次提交
    • J
      storage: Introduce storage volume add, delete, count APIs · 40630a8e
      John Ferlan 提交于
      Create/use virStoragePoolObjAddVol in order to add volumes onto list.
      
      Create/use virStoragePoolObjRemoveVol in order to remove volumes from list.
      
      Create/use virStoragePoolObjGetVolumesCount to get count of volumes on list.
      
      For the storage driver, the logic alters when the volumes.obj list grows
      to after we've fetched the volobj. This is an optimization of sorts, but
      also doesn't "needlessly" grow the volumes.objs list and then just decr
      the count if the virGetStorageVol fails.
      Signed-off-by: NJohn Ferlan <jferlan@redhat.com>
      40630a8e
  8. 22 7月, 2017 1 次提交
  9. 21 2月, 2017 1 次提交
  10. 19 1月, 2017 1 次提交
  11. 25 11月, 2016 1 次提交
    • M
      virstring: Unify string list function names · c2a5a4e7
      Michal Privoznik 提交于
      We have couple of functions that operate over NULL terminated
      lits of strings. However, our naming sucks:
      
      virStringJoin
      virStringFreeList
      virStringFreeListCount
      virStringArrayHasString
      virStringGetFirstWithPrefix
      
      We can do better:
      
      virStringListJoin
      virStringListFree
      virStringListFreeCount
      virStringListHasString
      virStringListGetFirstWithPrefix
      Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
      c2a5a4e7
  12. 17 4月, 2016 1 次提交
    • R
      ZFS: Support sparse volumes · c81bba4f
      Richard Laager 提交于
      By default, `zfs create -V ...` reserves space for the entire volsize,
      plus some extra (which attempts to account for overhead).
      
      If `zfs create -s -V ...` is used instead, zvols are (fully) sparse.
      
      A middle ground (partial allocation) can be achieved with
      `zfs create -s -o refreservation=... -V ...`.  Both libvirt and ZFS
      support this approach, so the ZFS storage backend should support it.
      Signed-off-by: NRichard Laager <rlaager@wiktel.com>
      c81bba4f
  13. 14 4月, 2016 1 次提交
  14. 27 3月, 2016 1 次提交
    • R
      Revert "zfs: Only raw volumes are supported" · b77cec09
      Roman Bogorodskiy 提交于
      This reverts commit bb5f2dc9.
      
      The "if (vol->target.format != VIR_STORAGE_FILE_RAW)" check in the
      createVol backend. This check is bogus because virStorageVolDefParseXML()
      in conf/storage_conf.c sets target.format only if volOptions in
      virStoragePoolTypeInfo has formatFromString set, and that's not the
      case the zfs backend.
      
      So the check always fails and breaks volume creation.
      b77cec09
  15. 21 3月, 2016 3 次提交
  16. 26 2月, 2016 2 次提交
  17. 04 2月, 2016 1 次提交
    • R
      storage: zfs: flexible use of 'volmode' option · c94f6d4d
      Roman Bogorodskiy 提交于
      There are slight differences in various ZFS implementations.
      Specifically, ZFS on FreeBSD requires to set value of 'volmode'
      option to 'dev' to expose volumes as raw disk device (that's what
      we need) rather than geom provides, for example.
      
      With ZFS on Linux, however, such option is not available and
      volumes exposed like we need by default.
      
      To make our implementation more flexible, only pass 'volmode'
      when it's supported. Support is checked by parsing usage
      information of the 'zfs get' command.
      c94f6d4d
  18. 02 4月, 2015 1 次提交
  19. 18 9月, 2014 1 次提交
    • R
      storage: zfs: implement pool build and delete · b4af4022
      Roman Bogorodskiy 提交于
       - Provide an implementation for buildPool and deletePool operations
         for the ZFS storage backend.
       - Add VIR_STORAGE_POOL_SOURCE_DEVICE flag to ZFS pool poolOptions
         as now we can specify devices to build pool from
       - storagepool.rng: add an optional 'sourceinfodev' to 'sourcezfs' and
         add an optional 'target' to 'poolzfs' entity
       - Add a couple of tests to storagepoolxml2xmltest
      b4af4022
  20. 30 8月, 2014 1 次提交
    • R
      storage: zfs: fix double listing of new volumes · c4d2a102
      Roman Bogorodskiy 提交于
      Currently, after calling commands to create a new volumes,
      virStorageBackendZFSCreateVol calls virStorageBackendZFSFindVols that
      calls virStorageBackendZFSParseVol.
      
      virStorageBackendZFSParseVol checks if a volume already exists by
      trying to get it using virStorageVolDefFindByName.
      
      For a just created volume it returns NULL, so volume is reported as
      new and appended to pool->volumes. This causes a volume to be listed
      twice as storageVolCreateXML appends this new volume to the list as
      well.
      
      Fix that by passing a new volume definition to
      virStorageBackendZFSParseVol so it could determine if it needs to add
      this volume to the list.
      c4d2a102
  21. 25 8月, 2014 1 次提交
  22. 12 8月, 2014 1 次提交
    • R
      storage: ZFS support · 0257d06b
      Roman Bogorodskiy 提交于
      Implement ZFS storage backend driver. Currently supported
      only on FreeBSD because of ZFS limitations on Linux.
      
      Features supported:
      
       - pool-start, pool-stop
       - pool-info
       - vol-list
       - vol-create / vol-delete
      
      Pool definition looks like that:
      
       <pool type='zfs'>
        <name>myzfspool</name>
        <source>
          <name>actualpoolname</name>
        </source>
       </pool>
      
      The 'actualpoolname' value is a name of the pool on the system,
      such as shown by 'zpool list' command. Target makes no sense
      here because volumes path is always /dev/zvol/$poolname/$volname.
      
      User has to create a pool on his own, this driver doesn't
      support pool creation currently.
      
      A volume could be used with Qemu by adding an entry like this:
      
          <disk type='volume' device='disk'>
            <driver name='qemu' type='raw'/>
            <source pool='myzfspool' volume='vol5'/>
            <target dev='hdc' bus='ide'/>
          </disk>
      0257d06b