[libvirt] Re: [Patch v0.4] iSCSI Multi-IQN (Libvirt Support)
Daniel P. Berrange
berrange at redhat.com
Wed Nov 18 11:17:18 UTC 2009
On Wed, Nov 18, 2009 at 04:37:02PM +0530, Shyam_Iyer at Dell.com wrote:
> > > 2) By using iscsiadm commands like the following
> > > # iscsiadm -m iface -I <iface_name> -o new
> > > # iscsiadm -m iface -I iface1 --op=update -n iface.initiatorname -v
> > > <iqnname>
> > In that case, why don't we make libvirt automatically set things up
> > this
> > way whenever it sees the IQN in the XML file.
> > > We don't change the default initiatorname with libvirt/virt manager
> > > today right ? So, we haven't added any apis to manage the iface file
> > > name using libvirt as such.
> > >
> > > But if required by virt-manager(to create a single window of
> > management)
> > > the iface file could be constructed using libvirt apis that call the
> > > iscsiadm commands detailed in method 2)
> > We don't need to add any new APIs for this - just automatically add
> > mapping whenever logging into a target with a IQN that we don't
> > know about
> How do we ensure that the iqn is not already known and libvirt is
> creating the corresponding iface file for the first time?
> That would mean searching through the IFACES_DIR which has been opposed
> in the thread...
Now that you've explained why this searching in IFACE_DIR was needed,
I've no problem with that approach. We should search through IFACES_DIR
to find the iface mapping, if none is found, then run those 2 commands
you show above in order to create a new mapping
> Also, how do we go about creating unique iface filenames when
> automatically creating them using libvirt ?
I don't know what naming convention is used in IFACES_DIR, but I'd say
just follow whatever's used already
|: Red Hat, Engineering, London -o- http://people.redhat.com/berrange/ :|
|: http://libvirt.org -o- http://virt-manager.org -o- http://ovirt.org :|
|: http://autobuild.org -o- http://search.cpan.org/~danberr/ :|
|: GnuPG: 7D3B9505 -o- F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505 :|
More information about the libvir-list