Hi,
For backing chain that all images are iscsi network disk type , such as
iscsi://ip/iqn../0(base image) <-iscsi://ip/iqn../1(active image).
Currently, 'qemu-img info --backing-chain' command can display correct
backing file info, but after starting guest with the active image in
backing chain, it don't include the related element in
dumpxml.
So, Whether libvirt can support all backing chain layer are iscsi
network disk type?
Best Regards
Meina Li
On Wed, Jan 3, 2018 at 6:39 AM, Meina Li wrote:
> Hi,
>
> I am a libvirt qe, I am testing the function about the new location of
> disk auth element (as sub-element of the source element) in Backing Chain
> Management. And I have a questions:
>
> When all the backing chain are iscsi network disk type(no matter if the
> authentication is exist), start the guest , it will only has the top
> level disk in xml and there are no other backingStore in it. The test step
> is below.
>
> So can this function support all backing chain with network disk type
> actually, or only use network authentication as the base image for backing
> chain of file disk type?
>
> Can you help reviewing it? Thanks very much in advance!
>
> Test step:
> 1. iSCSI server:
> o- iscsi
> [Targets: 2]
> | o- iqn.2003-01.org.linux-iscsi.localhost.x8664:sn.9cba196611e6
> ... [TPGs: 1]
> | | o- tpg1
> .
> [gen-acls, tpg-auth, 1-way auth]
> | | o- acls ..
>
> [ACLs: 0]
> | | o- luns ..
>
> [LUNs: 4]
> | | | o- lun0 ..
> .. [fileio/file1 (/tmp/lun1.img)
> (default_tg_pt_gp)]
> | | o- portals ..
> ..
> [Portals: 1]
> | | o- 0.0.0.0:3260 ..
> ...
> [OK]
> | o- iqn.2003-01.org.linux-iscsi.localhost.x8664:sn.a8d92ebb4ece
> ... [TPGs: 1]
> | o- tpg1
> .. [gen-acls, no-auth]
> | o- acls ..
>
> [ACLs: 0]
> | o- luns ..
>
> [LUNs: 3]
> | | o- lun0 ..
> .. [fileio/file3 (/tmp/lun3.img)
> (default_tg_pt_gp)]
> | o- portals ..
> ..
> [Portals: 1]
> | o- 0.0.0.0:3260 ..
> ...
> [OK]
>
> 2. Set iscsi secret.
> # cat iscsi-secret.xml
>
> iSCSI secret
>
> libvirtiscsi
>
>
> # virsh secret-define iscsi-secret.xml
> Secret 47bd2f3e-023f-44ba-85a3-e8fa7f16ff23 created
> # MYSECRET=`printf %s "redhat" | base64`
> # virsh secret-set-value 47bd2f3e-023f-44ba-85a3-e8fa7f16ff23 $MYSECRET
> Secret value set
>
> 3. Create backing chain.
> # qemu-img create -f qcow2 -b iscsi://redhat:redhat@10.66.7.
> 27:3260/iqn.2003-01.org.linux-iscsi.localhost.x8664:sn.9cba196611e6/0
> iscsi://10.66.7.27:3260/iqn.2003-01.org.linux-iscsi.localhost.x8664:sn.
> a8d92ebb4ece/0 -o backing_fmt=qcow2
>
> 4. Start guest.
> # qemu-img info iscsi://10.66.7.27:3260/iqn.2003-01.org.linux-iscsi.
> localhost.x8664:sn.a8d92ebb4ece/0 --backing-chainimage: json:{"driver":
> "qcow2", "file": {"lun": "0", "portal": "10.66.7.27:3260", "driver":
> "iscsi", "transport": "tcp", "target": "iqn.2003-01.org.linux-iscsi.
> localhost.x8664:sn.a8d92ebb4ece"}}
> file format: qcow2
> virtual size: 5.0G (5368709120 <0536%20870%209120> bytes)
> disk size: unavailable
> cluster_size: 65536
> backing file: iscsi://redhat:redhat@10.66.7.27:3260/iqn.2003-01.org.linux-
> iscsi.localhost.x8664:sn.9cba196611e6/0
> backing file format: qcow2
> Format specific information:
> compat: 1.1
> lazy refcounts: false
> refcount bits: 16
> corrupt: false
>
> image: json:{"driver": "qcow2", "file": {"lun": "0", "portal": "
> 10.66.7.27:3260", "driver": "iscsi", "transport": "tcp", "user":
> "redhat", "password": "redhat", "target": "iqn.2003-01.org.linux-iscsi.
> localhost.x8664:sn.9cba196611e6"}}
> file format: qcow2
> virtual size: 5.0G (5368709120