3.4-next hits more race conditions than 3.3 - The MAAS server gave an unexpected response: 502

Bug #2031842 reported by Nobuto Murata
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
MAAS
Invalid
Undecided
Unassigned

Bug Description

maas: 1:3.4.0~rc1-14298-g.8b414218b-0ubuntu1~22.04.1

When testing 3.4-next, I'm seeing more race conditions compared to 3.3.

Here is one simple example to trigger one of the race conditions.

1. prepare a jammy VM

uvt-kvm create \
    --cpu 4 --memory 8192 --disk 32 \
    --unsafe-caching \
    maas-test \
    release=jammy

uvt-kvm wait maas-test

2. install MAAS from ppa:maas/3.4-next and try to login from the API client

uvt-kvm ssh maas-test '
set -x
sudo apt update && sudo apt upgrade -y

sudo apt-add-repository -y ppa:maas/3.4-next

sudo apt install -y maas

sudo maas createadmin \
    --username ubuntu --password ubuntu \
    --email <email address hidden> \
    && \
    maas login admin http://localhost:5240/MAAS "$(sudo maas apikey --username ubuntu)"
' |& tee maas-test.log

maas login admin http://localhost:5240/MAAS aqtmzKnDVsqCPRrn8R:E8B56R9zjkUN5dMwEK:79db4vegmXjrwmxMTu6VbrCgmptxCgWR
-> The MAAS server gave an unexpected response: 502

Revision history for this message
Nobuto Murata (nobuto) wrote :
Revision history for this message
Nobuto Murata (nobuto) wrote :
Revision history for this message
Nobuto Murata (nobuto) wrote :

Logs of 3.3 just for a comparison.

Revision history for this message
Jacopo Rota (r00ta) wrote :

I suspect that when you call `maas login admin` the maas processes are not operational yet. I think we should add an `health` endpoint and improve the response message

Revision history for this message
Jacopo Rota (r00ta) wrote :

Hi @nobuto,

Did you hit the issue on the 3.3 run for which you uploaded the sos report?

Revision history for this message
Nobuto Murata (nobuto) wrote : Re: [Bug 2031842] Re: 3.4-next hits more race conditions than 3.3 - The MAAS server gave an unexpected response: 502

2023年9月22日(金) 18:46 Jacopo Rota <email address hidden>:

> Hi @nobuto,
>
> Did you hit the issue on the 3.3 run for which you uploaded the sos
> report?
>

Nope. It was just for a comparison. I hit the issue only with 3.4-next.

Jacopo Rota (r00ta)
Changed in maas:
status: New → Invalid
Revision history for this message
Jacopo Rota (r00ta) wrote :

Marking this as invalid as it seems to be a transient failure. If you can't reach MAAS for a reasonable amount of time then I would consider this a bug.

Feel free to reopen it in case you have an update or if you expect another behaviour

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.