1. 28 7月, 2016 2 次提交
    • D
      storage: remove "luks" storage volume type · a48c7141
      Daniel P. Berrange 提交于
      The current LUKS support has a "luks" volume type which has
      a "luks" encryption format.
      
      This partially makes sense if you consider the QEMU shorthand
      syntax only requires you to specify a format=luks, and it'll
      automagically uses "raw" as the next level driver. QEMU will
      however let you override the "raw" with any other driver it
      supports (vmdk, qcow, rbd, iscsi, etc, etc)
      
      IOW the intention though is that the "luks" encryption format
      is applied to all disk formats (whether raw, qcow2, rbd, gluster
      or whatever). As such it doesn't make much sense for libvirt
      to say the volume type is "luks" - we should be saying that it
      is a "raw" file, but with "luks" encryption applied.
      
      IOW, when creating a storage volume we should use this XML
      
        <volume>
          <name>demo.raw</name>
          <capacity>5368709120</capacity>
          <target>
            <format type='raw'/>
            <encryption format='luks'>
              <secret type='passphrase' uuid='0a81f5b2-8403-7b23-c8d6-21ccd2f80d6f'/>
            </encryption>
          </target>
        </volume>
      
      and when configuring a guest disk we should use
      
        <disk type='file' device='disk'>
          <driver name='qemu' type='raw'/>
          <source file='/home/berrange/VirtualMachines/demo.raw'/>
          <target dev='sda' bus='scsi'/>
          <encryption format='luks'>
            <secret type='passphrase' uuid='0a81f5b2-8403-7b23-c8d6-21ccd2f80d6f'/>
          </encryption>
        </disk>
      
      This commit thus removes the "luks" storage volume type added
      in
      
        commit 318ebb36
        Author: John Ferlan <jferlan@redhat.com>
        Date:   Tue Jun 21 12:59:54 2016 -0400
      
          util: Add 'luks' to the FileTypeInfo
      
      The storage file probing code is modified so that it can probe
      the actual encryption formats explicitly, rather than merely
      probing existance of encryption and letting the storage driver
      guess the format.
      
      The rest of the code is then adapted to deal with
      VIR_STORAGE_FILE_RAW w/ VIR_STORAGE_ENCRYPTION_FORMAT_LUKS
      instead of just VIR_STORAGE_FILE_LUKS.
      
      The commit mentioned above was included in libvirt v2.0.0.
      So when querying volume XML this will be a change in behaviour
      vs the 2.0.0 release - it'll report 'raw' instead of 'luks'
      for the volume format, but still report 'luks' for encryption
      format.  I think this change is OK because the storage driver
      did not include any support for creating volumes, nor starting
      guets with luks volumes in v2.0.0 - that only since then.
      Clearly if we change this we must do it before v2.1.0 though.
      Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
      a48c7141
    • D
      virstoragefile: refactor virStorageFileMatchesNNN methods · 970f42ab
      Daniel P. Berrange 提交于
      Refactor the virStorageFileMatchesNNN methods so that
      they don't take a struct FileFormatInfo parameter, but
      instead get the actual raw dat items they needs. This
      will facilitate reuse in other contexts.
      Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
      970f42ab
  2. 27 7月, 2016 21 次提交
  3. 26 7月, 2016 2 次提交
  4. 19 7月, 2016 3 次提交
  5. 18 7月, 2016 8 次提交
  6. 15 7月, 2016 3 次提交
  7. 13 7月, 2016 1 次提交
    • M
      dnsmasq: disable IPv6 default gateway in RA for isolated networks · 527968d4
      Maxim Perevedentsev 提交于
      IPv6 RA always contains an implicit default route via
      the link-local address of the source of RA. This forces
      the guest to install a route via isolated network, which
      may disturb the guest's networking in case of multiple interfaces.
      More info in 013427e6.
      
      The validity of this route is controlled by "default [route] lifetime"
      field of RA. If the lifetime is set to 0 seconds, then no route
      is installed by receiver.
      
      dnsmasq 2.67+ supports "ra-param=<interface>,<RA interval>,<default
      lifetime>" option. We pass "ra-param=*,0,0"
      (here, RA_interval=0 means default) to disable default gateway in RA
      for isolated networks.
      527968d4