AWS EC2 Ubuntu - Sonarqube 10.2 Default Login redirects back to login screen

34 views Asked by At
  • SonarQube 10.2 Community Edition
  • AWS EC2 Ubuntu 22.04
  • Java 17
  • Postgres 14
  • Setup Via Zip

Hi, I have spun up a AWS Instance and setup Sonarqube 10.2 LTS Community Edition with postgresSQL. When I try to use the default login admin/admin it redirects back to the login screen. I can see in the networks tab 401 Unauthorized for Current, Global and List.

Following error shows in the console outDUFI7UAQ.js:1031 Application failed to start Response {type: 'basic', url: 'http://3.94.106.255:9000/api/users/current', redirected: false, status: 401, ok: false, …}

I have tried to update the admin user as per documentation using

UPDATE users
SET crypted_password='100000$t2h8AtNs1AlCHuLobDjHQTn9XppwTIx88UjqUm4s8RsfTuXQHSd/fpFexAnewwPsO6jGFQUv/24DnO55hY6Xew==',
    salt='k9x9eN127/3e/hf38iNiKwVfaVk=',
    hash_method='PBKDF2',
    reset_password='true',
    user_local='true',
    active='true'
WHERE login = 'admin';

and also set a user_role for the admin.

INSERT INTO user_roles(uuid, user_uuid, role)
VALUES (uuid_generate_v4(),
        (select uuid from users where login='admin'),
        'admin');

There is also no proxy in front of it.

I have seen some posts here and in the sonarqube community that seem similar. But the solution suggested was to either upgrade, or the issue has been resolved but not how they have resolved it...

I have tried versions 9.9 and spun up this morning 10.2. I have 10.2 working in my local using Docker, but I have no clue as to why I cant login into the AWS setup.

The log is set to debug and I see in the

web.log

2023.11.14 12:08:32 DEBUG web[AYvNu17q9PHDM0S1AAAZ][auth.event] login failure [cause|User must be authenticated][method|BASIC][provider|LOCAL|local][IP|104.53.173.244|][login|]

sonar.log

2023.11.14 12:06:36 DEBUG app[][o.s.a.p.ManagedProcessLifecycle] EventWatcher[Web Server] tryToMoveTo Compute Engine from STARTING to STARTED => true
2023.11.14 12:06:37 WARN  app[][startup] ####################################################################################################################
2023.11.14 12:06:37 WARN  app[][startup] Default Administrator credentials are still being used. Make sure to change the password or deactivate the account.
2023.11.14 12:06:37 WARN  app[][startup] ####################################################################################################################
2023.11.14 12:06:42 INFO  app[][o.s.a.SchedulerImpl] Process[ce] is up
2023.11.14 12:06:42 DEBUG app[][o.s.a.p.ManagedProcessLifecycle] EventWatcher[Compute Engine] tryToMoveTo ElasticSearch from STARTED to STARTING => false
2023.11.14 12:06:42 DEBUG app[][o.s.a.p.ManagedProcessLifecycle] EventWatcher[Compute Engine] tryToMoveTo Web Server from STARTED to STARTING => false
2023.11.14 12:06:42 DEBUG app[][o.s.a.p.ManagedProcessLifecycle] EventWatcher[Compute Engine] tryToMoveTo Compute Engine from STARTED to STARTING => false
2023.11.14 12:06:42 DEBUG app[][o.s.a.NodeLifecycle] EventWatcher[Compute Engine] tryToMoveTo from STARTING to OPERATIONAL => true
2023.11.14 12:06:42 INFO  app[][o.s.a.SchedulerImpl] SonarQube is operational

While Elastic Search, Compute Engine and Webserver state from started to starting = false. I do see logs coming in from all three and the web server is up and running as I can see the login screen.

I don't understand why I can' t login and would really appreciate if someone could help.

0

There are 0 answers