This is an automated email from the ASF dual-hosted git repository.

sureshanaparti pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/cloudstack.git


The following commit(s) were added to refs/heads/main by this push:
     new 9fee6dae34c Fix local storage pool disconnect issue (#11200)
9fee6dae34c is described below

commit 9fee6dae34cc233ee6644ed6fe5499d3103f9f3a
Author: Harikrishna <harikrishna.patn...@gmail.com>
AuthorDate: Mon Jul 28 19:41:12 2025 +0530

    Fix local storage pool disconnect issue (#11200)
---
 .../src/main/java/com/cloud/storage/listener/StoragePoolMonitor.java  | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git 
a/server/src/main/java/com/cloud/storage/listener/StoragePoolMonitor.java 
b/server/src/main/java/com/cloud/storage/listener/StoragePoolMonitor.java
index 01fcb43c4c4..b432858f2e0 100644
--- a/server/src/main/java/com/cloud/storage/listener/StoragePoolMonitor.java
+++ b/server/src/main/java/com/cloud/storage/listener/StoragePoolMonitor.java
@@ -168,7 +168,6 @@ public class StoragePoolMonitor implements Listener {
                     throw new ConnectionException(true, String.format("Unable 
to prepare OCFS2 nodes for pool %s", pool));
                 }
 
-                Long hostId = host.getId();
                 if (logger.isDebugEnabled()) {
                     logger.debug("Host {} connected, connecting host to shared 
pool {} and sending storage pool information ...", host, pool);
                 }
@@ -185,6 +184,9 @@ public class StoragePoolMonitor implements Listener {
             // Disconnect any pools which are not expected to be connected
             for (StoragePoolHostVO poolToDisconnect: previouslyConnectedPools) 
{
                 StoragePoolVO pool = 
_poolDao.findById(poolToDisconnect.getPoolId());
+                if (!pool.isShared()) {
+                    continue;
+                }
                 try {
                     _storageManager.disconnectHostFromSharedPool(host, pool);
                     
_storagePoolHostDao.deleteStoragePoolHostDetails(host.getId(), pool.getId());

Reply via email to