Hi Anderson,

Thanks for replying. I think this may require a bit more analysis of your 
database to figure out if this is a (a) issue in a few rows in the DB where 
there's something in them which causes response creation issue, or, (b) if 
there a schema issue (for ex. upgrade path didn't work for some reason). Was 
this environment upgraded from a non-standard version (such as CloudStack fork, 
for ex upgraded from CloudPlatfom etc?), or was the database hacked (for ex. 
manual update to VM related rows?).

If it is (a), you can try to paginate the list APIs (pass pagesize and page 
params in the API) or some other API parameter to triage if there are any 
specific VMs (rows in the DB) that may be causing some null issue.

Based on the exception you've shared seen in the log message, I think there's 
some number parsing [1] that may be causing this though I don't see a 
stacktrace to suggest what may be causing this and how to fix that.

[1] 
https://docs.oracle.com/javase/7/docs/api/java/lang/NumberFormatException.html


Regards.

________________________________
From: Anderson Soares Ferreira <anderson.soa...@embrapa.br.INVALID>
Sent: Friday, November 11, 2022 23:23
To: users@cloudstack.apache.org <users@cloudstack.apache.org>
Subject: Re: Problems upgrading Cloudstack from 4.15.2 to 4.17.1

Hi Rohit,

Answering your questions:

Our environment doesn't have any custom role.  We have few users with
standard roles and the problem occurs with all of them, even accounts with
Root Admin role.

The database system in use in our installation is MySQL 8.0.31

The problem seems to affect only the listVirtualMachines and
listVirtualMachinesMetrics APIs, to be precise. I haven't noticed any
problem in any other viewer/APIs

I've dropped and manually recreated the user_vm_view view, but the problem
is still present. Executing 'select * from user_vm_view' on the mysql shell
returns a list of VMs, as expected.

Another thing that I've realized while performing some tests using
cloudmonkey is that although 'list virtualmachines' fails while trying to
list all VMs, when I repeat the same command using a filter argument (name=
for instance), the query returns the information about the VM without any
error. I've also observed the same behavior in the UI, when using the
filter field of Instance page, when it appears.

Thank you for your help!

Regards,

----
Anderson Soares Ferreira - anderson.soa...@embrapa.br
Núcleo de Tecnologia da Informação - NTI
Embrapa Territorial
Tel.: (19) 3211-6200


Em sex., 11 de nov. de 2022 às 05:46, Rohit Yadav <rohit.ya...@shapeblue.com>
escreveu:

> Hi Anderson,
>
> Can you share some details about your environment, for ex:
>
>   *   Are you using any custom roles for your account that is used to
> logging in?
>   *   What database are you using with your ACS 4.15.2? (mysql-server 8.x
> or maria-db or something else?)
>   *   Is that a environment-wide issue or limited to specific account or
> VMs?
>   *   Is this limited to only the VM UI/API, any issues with other views
> or APIs?
>   *   Does it help if you re-run the user_vm_view view (i.e. drop and
> create it manually):
>   *
> https://github.com/apache/cloudstack/blob/main/engine/schema/src/main/resources/META-INF/db/schema-41610to41700.sql#L378
>
>
> Regards.
>
> ________________________________
> From: Anderson Soares Ferreira <anderson.soa...@embrapa.br.INVALID>
> Sent: Thursday, November 10, 2022 18:21
> To: users@cloudstack.apache.org <users@cloudstack.apache.org>
> Subject: Problems upgrading Cloudstack from 4.15.2 to 4.17.1
>
> Hello,
>
> I'm facing an error in the management UI after upgrading our Cloudstack
> installation from 4.15.2 to 4.17.1.
> The upgrading process occured as expected and the management server log
> showed that the database upgrade also terminated without any error.
> But, when I log in the management interface, the Compute > Instances page
> shows a "404 Error'' . A notification also appears briefly with the
> message: 'Request failed (431) For input string: "null"'.
>
> The management server's log shows the following message:
>
> 2022-11-10 09:28:09,986 INFO  [c.c.a.ApiServer]
> (qtp1443435931-29:ctx-38eefa4c ctx-903ab554) (logid:1c467882) For input
> string: "null"
>
> And the Api log shows:
>
> 2022-11-10 09:29:51,188 INFO  [a.c.c.a.ApiServer]
> (qtp169663597-362:ctx-e4f585c8 ctx-f41d60b4) (logid:3a722cf9) (userId=2
> accountId=2 sessionId=node01imyx6kxnjqrql48r91wm5zvk0)
> 2801:80:140c:11:0:0:0:b -- GET
>
> listall=true&page=1&pagesize=20&showIcon=true&command=listVirtualMachinesMetrics&response=json
> 431 For input string: "null"
> 2022-11-10 08:29:56,779 INFO  [a.c.c.a.ApiServer]
> (qtp169663597-30:ctx-3b183013 ctx-772dcce7) (logid:7df22a93) (userId=2
> accountId=2 sessionId=node01imyx6kxnjqrql48r91wm5zvk0)
> 2801:80:140c:11:0:0:0:b -- GET
>
> listall=true&page=1&pagesize=20&showIcon=true&command=listVirtualMachinesMetrics&response=json
> 431 For input string: "null"
>
> I've also noticed that cloudmonkey reports a similar error:
>
> 🙈 Error: (HTTP 431, error code 9999) For input string: "null"
>
> Since I haven't been able to identify what is causing that issue, I've
> restored the database backup, downgraded my installation back to 4.15.2 and
> everything started to work again.
>
> For one last test I decided to try to upgrade our installation again, but
> this time upgrading to the version 4.16.x, instead. The result was the same
> 404 page on the UI and same errors on the log files.
>
> One additional information, our installation is based on the Linux Ubuntu
> 20.04 distro.
>
> Has anyone experienced something like this? If so, how to fix it?
>
> Thank you in advance!
>
> ----
> Anderson Soares Ferreira - anderson.soa...@embrapa.br
> Núcleo de Tecnologia da Informação - NTI
> Embrapa Territorial
> Tel.: (19) 3211-6200
>
> --
> __________________________
> Aviso de confidencialidade
>
> Esta mensagem da
> Empresa  Brasileira de Pesquisa  Agropecuaria (Embrapa), empresa publica
> federal  regida pelo disposto  na Lei Federal no. 5.851,  de 7 de dezembro
> de 1972,  e  enviada exclusivamente  a seu destinatario e pode conter
> informacoes  confidenciais, protegidas  por sigilo profissional.  Sua
> utilizacao desautorizada  e ilegal e  sujeita o infrator as penas da lei.
> Se voce  a recebeu indevidamente, queira, por gentileza, reenvia-la ao
> emitente, esclarecendo o equivoco.
>
> Confidentiality note
>
> This message from
> Empresa  Brasileira de Pesquisa  Agropecuaria (Embrapa), a government
> company  established under  Brazilian law (5.851/72), is directed
> exclusively to  its addressee  and may contain confidential data,
> protected under  professional secrecy  rules. Its unauthorized  use is
> illegal and  may subject the transgressor to the law's penalties. If you
> are not the addressee, please send it back, elucidating the failure.
>
>
>
>

--
__________________________
Aviso de confidencialidade

Esta mensagem da
Empresa  Brasileira de Pesquisa  Agropecuaria (Embrapa), empresa publica
federal  regida pelo disposto  na Lei Federal no. 5.851,  de 7 de dezembro
de 1972,  e  enviada exclusivamente  a seu destinatario e pode conter
informacoes  confidenciais, protegidas  por sigilo profissional.  Sua
utilizacao desautorizada  e ilegal e  sujeita o infrator as penas da lei.
Se voce  a recebeu indevidamente, queira, por gentileza, reenvia-la ao
emitente, esclarecendo o equivoco.

Confidentiality note

This message from
Empresa  Brasileira de Pesquisa  Agropecuaria (Embrapa), a government
company  established under  Brazilian law (5.851/72), is directed
exclusively to  its addressee  and may contain confidential data,
protected under  professional secrecy  rules. Its unauthorized  use is
illegal and  may subject the transgressor to the law's penalties. If you
are not the addressee, please send it back, elucidating the failure.

 

Reply via email to