[Kimchi-devel] [PATCH] Refreshing an inactive pool causes exception

Daniel H Barboza danielhb at linux.vnet.ibm.com
Thu Mar 6 12:59:02 UTC 2014


Reviewed-by: Daniel Barboza <danielhb at linux.vnet.ibm.com>

Comment: this problem (refreshing an inactive pool) was one of the core 
issues of
the NFS bug I've worked on last week. I wasn't aware that this was 
happening with
non-NFS pools as well.

Good catch

On 03/06/2014 05:48 AM, Shu Ming wrote:
> When an update request to extend a inactive storagepool is
> finished sucessfully, an exception will be raised complaining
> the pool is inactive. The exception response to the clinet is
> quite misleading for a successful request.
> ---
>   src/kimchi/model/storagepools.py | 3 ++-
>   1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/src/kimchi/model/storagepools.py b/src/kimchi/model/storagepools.py
> index 8edf62e..b666209 100644
> --- a/src/kimchi/model/storagepools.py
> +++ b/src/kimchi/model/storagepools.py
> @@ -272,7 +272,8 @@ class StoragePoolModel(object):
>                                                      'err': error})
>           # refreshing pool state
>           pool = self.get_storagepool(pool_name, self.conn)
> -        pool.refresh(0)
> +        if pool.isActive():
> +            pool.refresh(0)
>
>       def update(self, name, params):
>           pool = self.get_storagepool(name, self.conn)




More information about the Kimchi-devel mailing list