Re: Calling scaleVirtualMachine fails due to incorrect power state examination

2019-12-08 Thread Alireza Eskandari
Yes, as we told in github issue, we have test that api and it works fine.
As soon as VM state changes to stopped, the changeServiceForVirtualMachine
scales VM without any issue.
But changeServiceForVirtualMachine don't support live upgrade of VM, it
asks us to stop VM in any circumstance.

On Sun, Dec 8, 2019 at 9:56 PM Wei ZHOU  wrote:

> try another api?
>
>
> https://cloudstack.apache.org/api/apidocs-4.13/apis/changeServiceForVirtualMachine.html
>
> On Sunday, 8 December 2019, Alireza Eskandari 
> wrote:
>
> > No, I try to power off the VM from CS.
> >
> > On Sun, Dec 8, 2019 at 9:49 PM Andrija Panic 
> > wrote:
> >
> > > This is happening when VM is stopped out of band (outside CloudStack)?
> > >
> > > On Sun, 8 Dec 2019, 18:12 Alireza Eskandari, 
> > > wrote:
> > >
> > > > Hi guys,
> > > > Recently we try to upgrade our infra from 4.9 to 4.13
> > > > As we check the new version of CS in our lab, we face with a problem
> > > about
> > > > scaling VMs.
> > > > For example I shutdown a VM before downgrade, then I check its state
> to
> > > > ensure it is stopped.
> > > > After VM is fully stopped, (by checking listVirtualMachine API) I
> call
> > > > scaleVirtualMachine to downgrade it but I get error which says that
> VM
> > is
> > > > not stopped.
> > > > After a while (about 30s to 1min) I retry to downgrade it but this
> > > > everything goes as expected without error.
> > > > My investigation shows that a change from CS 4.9 is the root cause of
> > > this
> > > > problem.
> > > > I submit this problem as an issue in github:
> > > > https://github.com/apache/cloudstack/issues/3749
> > > > It will be nice if you resolve this bug in future release of CS 4.13.
> > > > Regards,
> > > > Alireza
> > > >
> > >
> >
>


Re: Calling scaleVirtualMachine fails due to incorrect power state examination

2019-12-08 Thread Wei ZHOU
try another api?

https://cloudstack.apache.org/api/apidocs-4.13/apis/changeServiceForVirtualMachine.html

On Sunday, 8 December 2019, Alireza Eskandari 
wrote:

> No, I try to power off the VM from CS.
>
> On Sun, Dec 8, 2019 at 9:49 PM Andrija Panic 
> wrote:
>
> > This is happening when VM is stopped out of band (outside CloudStack)?
> >
> > On Sun, 8 Dec 2019, 18:12 Alireza Eskandari, 
> > wrote:
> >
> > > Hi guys,
> > > Recently we try to upgrade our infra from 4.9 to 4.13
> > > As we check the new version of CS in our lab, we face with a problem
> > about
> > > scaling VMs.
> > > For example I shutdown a VM before downgrade, then I check its state to
> > > ensure it is stopped.
> > > After VM is fully stopped, (by checking listVirtualMachine API) I call
> > > scaleVirtualMachine to downgrade it but I get error which says that VM
> is
> > > not stopped.
> > > After a while (about 30s to 1min) I retry to downgrade it but this
> > > everything goes as expected without error.
> > > My investigation shows that a change from CS 4.9 is the root cause of
> > this
> > > problem.
> > > I submit this problem as an issue in github:
> > > https://github.com/apache/cloudstack/issues/3749
> > > It will be nice if you resolve this bug in future release of CS 4.13.
> > > Regards,
> > > Alireza
> > >
> >
>


Re: Calling scaleVirtualMachine fails due to incorrect power state examination

2019-12-08 Thread Alireza Eskandari
No, I try to power off the VM from CS.

On Sun, Dec 8, 2019 at 9:49 PM Andrija Panic 
wrote:

> This is happening when VM is stopped out of band (outside CloudStack)?
>
> On Sun, 8 Dec 2019, 18:12 Alireza Eskandari, 
> wrote:
>
> > Hi guys,
> > Recently we try to upgrade our infra from 4.9 to 4.13
> > As we check the new version of CS in our lab, we face with a problem
> about
> > scaling VMs.
> > For example I shutdown a VM before downgrade, then I check its state to
> > ensure it is stopped.
> > After VM is fully stopped, (by checking listVirtualMachine API) I call
> > scaleVirtualMachine to downgrade it but I get error which says that VM is
> > not stopped.
> > After a while (about 30s to 1min) I retry to downgrade it but this
> > everything goes as expected without error.
> > My investigation shows that a change from CS 4.9 is the root cause of
> this
> > problem.
> > I submit this problem as an issue in github:
> > https://github.com/apache/cloudstack/issues/3749
> > It will be nice if you resolve this bug in future release of CS 4.13.
> > Regards,
> > Alireza
> >
>


Re: Calling scaleVirtualMachine fails due to incorrect power state examination

2019-12-08 Thread Andrija Panic
This is happening when VM is stopped out of band (outside CloudStack)?

On Sun, 8 Dec 2019, 18:12 Alireza Eskandari, 
wrote:

> Hi guys,
> Recently we try to upgrade our infra from 4.9 to 4.13
> As we check the new version of CS in our lab, we face with a problem about
> scaling VMs.
> For example I shutdown a VM before downgrade, then I check its state to
> ensure it is stopped.
> After VM is fully stopped, (by checking listVirtualMachine API) I call
> scaleVirtualMachine to downgrade it but I get error which says that VM is
> not stopped.
> After a while (about 30s to 1min) I retry to downgrade it but this
> everything goes as expected without error.
> My investigation shows that a change from CS 4.9 is the root cause of this
> problem.
> I submit this problem as an issue in github:
> https://github.com/apache/cloudstack/issues/3749
> It will be nice if you resolve this bug in future release of CS 4.13.
> Regards,
> Alireza
>