cloudstack-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Valery Ciareszka (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CLOUDSTACK-4777) NullPointerException instead of working KVM HA
Date Thu, 03 Oct 2013 07:39:41 GMT

    [ https://issues.apache.org/jira/browse/CLOUDSTACK-4777?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13784895#comment-13784895
] 

Valery Ciareszka commented on CLOUDSTACK-4777:
----------------------------------------------

I was able to resolve this issue by modifying a/server/src/com/cloud/storage/VolumeManagerImpl.java

--- a/server/src/com/cloud/storage/VolumeManagerImpl.java
+++ b/server/src/com/cloud/storage/VolumeManagerImpl.java
@@ -2657,7 +2657,8 @@ public class VolumeManagerImpl extends ManagerBase implements VolumeManager
{
     public boolean canVmRestartOnAnotherServer(long vmId) {
         List<VolumeVO> vols = _volsDao.findCreatedByInstance(vmId);
         for (VolumeVO vol : vols) {
-            if (!vol.isRecreatable() && !vol.getPoolType().isShared()) {
+            StoragePoolVO storagePoolVO = _storagePoolDao.findById(vol.getPoolId());
+            if (!vol.isRecreatable() && storagePoolVO != null && storagePoolVO.getPoolType()
!= null && !(storagePoolVO.getPoolType().isShared())) {
                 return false;
             }
         }

this is commit from https://issues.apache.org/jira/browse/CLOUDSTACK-4627
But this bug is still present in latest cloudstack 4.2.0 source code (as well as in packages
from http://cloudstack.apt-get.eu/rhel/4.2/)

> NullPointerException instead of working KVM HA
> ----------------------------------------------
>
>                 Key: CLOUDSTACK-4777
>                 URL: https://issues.apache.org/jira/browse/CLOUDSTACK-4777
>             Project: CloudStack
>          Issue Type: Bug
>      Security Level: Public(Anyone can view this level - this is the default.) 
>          Components: Hypervisor Controller, KVM, Management Server
>    Affects Versions: 4.2.0
>         Environment: KVM (CentOS 6.4) with CloudStack 4.2
>            Reporter: Valery Ciareszka
>            Priority: Critical
>
> If  KVM host goes down, CloudStack management does not start HA-enabled VM on the other
hosts. There is NullPointerException in management.log:
> 2013-09-24 11:21:25,500 ERROR [cloud.ha.HighAvailabilityManagerImpl] (HA-Worker-4:work-4)
Terminating HAWork[4-HA-6-Running-Scheduled]
> java.lang.NullPointerException
>         at com.cloud.storage.VolumeManagerImpl.canVmRestartOnAnotherServer(VolumeManagerImpl.java:2641)
>         at com.cloud.ha.HighAvailabilityManagerImpl.restart(HighAvailabilityManagerImpl.java:516)
>         at com.cloud.ha.HighAvailabilityManagerImpl$WorkerThread.run(HighAvailabilityManagerImpl.java:831)
> see full log at http://pastebin.com/upnEA601



--
This message was sent by Atlassian JIRA
(v6.1#6144)

Mime
View raw message