diff --git a/mayastor/src/bdev/nexus/nexus_bdev.rs b/mayastor/src/bdev/nexus/nexus_bdev.rs index c42e23558..cd01ba861 100644 --- a/mayastor/src/bdev/nexus/nexus_bdev.rs +++ b/mayastor/src/bdev/nexus/nexus_bdev.rs @@ -556,7 +556,6 @@ impl Nexus { } if r.await.unwrap() { - info!("Nexus {} destroyed", self.name); Ok(()) } else { Err(Error::NexusDestroy { diff --git a/mayastor/src/grpc/nexus_grpc.rs b/mayastor/src/grpc/nexus_grpc.rs index 09658adca..1ef000d92 100644 --- a/mayastor/src/grpc/nexus_grpc.rs +++ b/mayastor/src/grpc/nexus_grpc.rs @@ -122,7 +122,12 @@ pub async fn nexus_add_child( /// Idempotent destruction of the nexus. pub async fn nexus_destroy(uuid: &str) -> Result<(), Error> { if let Ok(n) = nexus_lookup(uuid) { - n.destroy().await?; + let result = n.destroy().await; + if result.is_ok() { + info!("Nexus {} destroyed", uuid) + } else { + return result; + } }; Ok(()) }