I'm currently implementing the storage driver for ESX and have a
mapping problem.
libvirt storage pools can be either running or inactive just like the
domain. ESX is a bit different here. A datastore is always active. It
can be inaccessible, e.g. if an NFS is mounted as datastore but the
NFS server went unreachable. I discussed this with Daniel on IRC and
he summarized it like this:
<DV> they are defined, the system knows them, but they are not
available for use
The question is, what should the ESX driver do with inaccessible datastores?
Option 1: They could just be represented as inactive storage pools,
but libvirt's semantic for inactive storage pools includes that the
user can start an inactive storage pool. That's not possible for an
inaccessible datastore, so the driver would report an error if a user
tries to start an inaccessible storage pool.
Option 2: Just ignore inaccessible datastores and make the ESX storage
driver to pretend that they don't exist. But this would hide
information from the user.
Option 3: Extend libvirt's API for inaccessible storage pools.
There are possibly other options and I'd like to hear your comments
and suggestions.
Matthias