Page 2 of 2

Re: PC appears disconnected since update to 2.2

Published: July 6, 2022 - 2:26 PM
by dcardon
What version of PostgreSQL is currently running (not the installed versions)?

Code: Select all

sudo -u postgres psql template1 -c "SELECT version();"
Could you retrieve the exception corresponding to the error returned ("ERROR: syntax error on or near...") in /var/log/waptserver.log.

By the way, it seems your server is installed in a French locale, which doesn't meet the documentation requirements... It's not best practice...

Sincerely,

Denis

Re: PC appears disconnected since update to 2.2

Published: July 7, 2022 - 9:11 AM
by Alex
- The version is PostgreSQL 9.4.19

- Here's what I retrieved from the logs:

Code: Select all

Jul  3 00:04:05 EOS waptserver[1047]: 2022-07-03 00:04:05,930 [waptserver     ] CRITICAL Get_websocket_auth_token failed ProgrammingError("ERREUR:  erreur de syntaxe sur ou près de « ON »\nLINE 1: ...519b9b0-d697-11e7-8d03-000c2954dc5e', 1656799445) ON CONFLIC...\n                                                             ^\n")
Jul  3 00:04:06 EOS waptserver[1047]: 2022-07-03 00:04:06,936 [waptserver     ] CRITICAL Get_websocket_auth_token failed ProgrammingError("ERREUR:  erreur de syntaxe sur ou près de « ON »\nLINE 1: ...519b9b0-d697-11e7-8d03-000c2954dc5e', 1656799446) ON CONFLIC...\n                                                             ^\n")
Jul  3 00:04:07 EOS waptserver[1047]: 2022-07-03 00:04:07,399 [waptdb         ] CRITICAL Unable to update installed_softwares for 4C4C4544-0053-5210-804C-B6C04F32344A: ProgrammingError: ERREUR:  erreur de syntaxe sur ou près de « on »
Jul  3 00:04:07 EOS waptserver[1047]: LINE 3:               on conflict (host_id,software_id) do update
- Regarding the language, I just switched back to LANG=en_US.UTF-8

Re: PC appears disconnected since update to 2.2

Published: July 7, 2022 - 6:11 PM
by dcardon
You need at least PostgreSQL 9.6. Please upgrade PostgreSQL (by default, Debian installs the new version during a major distribution upgrade but doesn't switch over and keeps the old version in production on port 5432).

Regards,

Denis

Re: PC appears disconnected since update to 2.2

Published: July 8, 2022 - 11:32 AM
by Alex
Like this?

Code: Select all

9.4 main    5432 online postgres /var/lib/postgresql/9.4/main /var/log/postgresql/postgresql-9.4-main.log
11  main    5433 online postgres /var/lib/postgresql/11/main  /var/log/postgresql/postgresql-11-main.log
But that doesn't change anything... is there a specific procedure to follow?

Re: PC appears disconnected since update to 2.2

Published: July 8, 2022 - 7:28 PM
by dcardon
The problem doesn't depend on wapt, but on the Debian upgrade process. You need to use the `pg_upgradecluster` command to update the data to version 11.

You can refer to:

https://gist.github.com/dmitrykustov/27 ... c830910019.

At the end of the process, it should be PostgreSQL 11 listening on port 5432 with the wapt database, and you can then remove the PostgreSQL 9.4 packages.

Denis

Re: PC appears disconnected since update to 2.2

Published: July 11, 2022 - 09:21
by Alex
Ah, after that, it's much better! The upgraded machines are now showing as OK!

Thank you so much.
Have a good day.

Re: PC appears disconnected since update to 2.2

Published: July 11, 2022 - 09:28
by dcardon
Okay, good news. So the problem was that the Postgres database hadn't been upgraded during the Debian distribution upgrade. As a reminder, you need Postgres version 9.6 or higher to run the WAPT server.

I'm marking this as resolved.

Regards,

Denis