1. 21 2月, 2017 1 次提交
  2. 19 2月, 2017 3 次提交
    • J
      util: Move scsi_host specific functions from virutil · 03346def
      John Ferlan 提交于
      Create a virscsihost.c and place the functions there. That removes the
      last #ifdef __linux__ from virutil.c.
      
      Take the opporunity to also change the function names and in one case
      the parameters slightly
      03346def
    • J
      util: Replace virStoragePoolGetVhbaSCSIHostParent · d2d74a98
      John Ferlan 提交于
      Use the new virNodeDeviceGetParentName instead. Modify the callers to
      build the node device scsi_host# name string in order to call the new
      function so that proper lookup occurs.
      d2d74a98
    • J
      util: Create a new virvhba module and move/rename API's · 16416816
      John Ferlan 提交于
      Rather than have them mixed in with the virutil apis, create a separate
      virvhba.c module and move the vHBA related calls into there. Soon there
      will be more added.
      
      Also modify the names of the functions and some arguments to be more
      indicative of what is really happening. Adjust the callers respectively.
      
      While I was changing fchosttest, rather than the non-descriptive names
      test1...test6, rename them to match what the test is doing.
      16416816
  3. 11 2月, 2017 2 次提交
  4. 27 1月, 2017 2 次提交
  5. 26 1月, 2017 5 次提交
  6. 19 1月, 2017 7 次提交
  7. 18 1月, 2017 6 次提交
    • J
      disk: Fixup error handling path for devmapper when part_separator='yes' · 0d157b3f
      John Ferlan 提交于
      https://bugzilla.redhat.com/show_bug.cgi?id=1346566
      
      If libvirt_parthelper is erroneously told to append the partition
      separator 'p' onto the generated output for a disk pool using device
      mapper that has 'user_friendly_names' set to true, then the error
      recovery path will fail to find volume resulting in the pool being
      in an unusable state.
      
      So, augment the documentation to provide the better hint that the
      part_separator='yes' should be set when user_friendly_names are not
      being used. Additionally, once we're in the error path where the
      returned name doesn't match the expected partition name try to see
      if the reason is because the 'p' was erroneosly added. If so alter
      the about to be removed vol->target.path so that the DiskDeleteVol
      code can find the partition that was created and remove it.
      0d157b3f
    • J
      storage: Allow probe of volume capacity for BLOCK type · 9508682b
      John Ferlan 提交于
      If the voldef type is VIR_STORAGE_VOL_BLOCK, then as long as the
      format is known, let's allow the probe to happen - gets a truer value
      and the same probe/update would be allowed for the same volume defined
      in a domain.
      9508682b
    • J
      storage: Fix virStorageBackendUpdateVolTargetInfo type check · d04bb05f
      John Ferlan 提交于
      For volume processing in virStorageBackendUpdateVolTargetInfo to get
      the capacity commit id 'a760ba3a' added the ability to probe a volume
      that didn't list a target format. Unfortunately, the code used the
      virStorageSource  (e.g. target->type - virStorageType) rather than
      virStorageVolDef (e.g. vol->type - virStorageVolType) in order to
      make the comparison. As it turns out target->type for a volume is
      not filled in at all for a voldef as the code relies on vol->type.
      Ironically the result is that only VIR_STORAGE_VOL_BLOCK's would get
      their capacity updated.
      
      This patch will adjust the code to check the "vol->type" field instead
      as an argument. This way for a voldef, the correct comparison is made.
      
      Additionally for a backingStore, the 'type' field is never filled in;
      however, since we know that the provided path is a location at which
      the backing store can be accessed on the local filesystem thus just
      pass VIR_STORAGE_VOL_FILE in order to satisfy the adjusted voltype
      check. Whether it's a FILE or a BLOCK only matters if we're trying to
      get more data based on the target->format.
      d04bb05f
    • P
      storage: gluster: Remove build-time dependency on the 'gluster' cli tool · 9e97c8c0
      Peter Krempa 提交于
      The tool is used for pool discovery. Since we call an external binary we
      don't really need to compile out the code that uses it. We can check
      whether it exists at runtime.
      9e97c8c0
    • P
      storage: gluster: Report error if no volumes were found in pool lookup · ce5055d7
      Peter Krempa 提交于
      Similarly to the 'netfs' pool, return an error if the host does not have
      any volumes.
      ce5055d7
    • P
      storage: Fix error reporting when looking up storage pool sources · 7bdb4b8f
      Peter Krempa 提交于
      In commit 4090e153 we went back from reporting no errors if no storage
      pools were found on a given host to reporting a bad error. And only in
      cases when gluster was not installed.
      
      Report a less bad error in case there are no volumes. Also report the
      error when gluster is installed but no volumes were found, since
      virStorageBackendFindGlusterPoolSources would return success in that
      case.
      7bdb4b8f
  8. 14 1月, 2017 3 次提交
    • J
      storage: Alter error message in probe/empty checks · 40ec4ff6
      John Ferlan 提交于
      For case VIR_STORAGE_BLKID_PROBE_DIFFERENT, clean up the message to
      avoid using the virsh like --overwrite syntax. Additionally provide
      a different error message when not writing the label to avoid confusion.
      40ec4ff6
    • J
      storage: Clean up return value checking · f462f9ad
      John Ferlan 提交于
      Rather than special casing the VIR_STORAGE_BLKID_PROBE_UNKNOWN after
      calling virStorageBackendBLKIDFindPart, just allow the switch statement
      handle setting ret = -2.
      f462f9ad
    • J
      storage: Alter logic when both BLKID and PARTED unavailable · d1f5dfc4
      John Ferlan 提交于
      If neither BLKID or PARTED is available and we're not writing, then
      just return 0 which allows the underlying storage pool to generate
      a failure. If both are unavailable and we're writing, then generate
      a more generic error message.
      d1f5dfc4
  9. 13 1月, 2017 2 次提交
    • P
      Revert "storage: Validate the device formats at logical startup" · a80957c5
      Peter Krempa 提交于
      The check is pointless since LVM is capable to detect it's own members
      and the check is flawed as it would fail if neither libblkid nor parted
      is installed.
      
      We don't really need to babysit LVM in this way.
      
      This reverts commit cb38b6cb.
      a80957c5
    • P
      Revert "storage: For FS pool check for properly formatted target volume" · 9538dff9
      Peter Krempa 提交于
      The check does not work properly (crashes) with netfs filesystems and
      also checking that a device is not empty when attempting to mount a
      filesystem is not very usefull since the mount will fail anyways.
      
      As the code would improve only a very minor corner case I don't really
      see a reason to have this code at all.
      
      This code would also fail if libvirt is compiled without support for
      blkid and without parted.
      
      This reverts commit a11fd697.
      9538dff9
  10. 10 1月, 2017 9 次提交