Ad Widget

Collapse

Not able to log into frontend => login or passwd incorrect, but they are correct !

Collapse
This topic has been answered.
X
X
 
  • Time
  • Show
Clear All
new posts
  • CMD49
    Junior Member
    • Oct 2017
    • 4

    #1

    Not able to log into frontend => login or passwd incorrect, but they are correct !

    Hi all,

    Just upgrade my zabbix server.
    ubuntu 16 to 22 and Zabbix From 3.4 to 6.4
    passing by : ubuntu 18 / 20 and Zabbix 4 then 5.

    After upgrade, I went on http://zabbixserver/zabbix/setup.php
    All prerequisites were OK
    I connected successfully to DB

    PROBLEM :
    When I try to log on to frontend from my station: I just get "incorrect username or password or account locked" (in french).
    I tried with all accounts : same result


    I CHECKED :
    ufw disable
    password OK in DB (I try to reset them with UPDATE passwd from users.... => no change / Tried to clear password => same result)
    A login attempt update the "attempt_failed" field in the database (so frontend is challenging the password it considering it as "false")
    I checked in "private navigation" to avoid session problems

    LOGS :
    /var/log/apache2/access.log
    192.168.x.x - - [18/Nov/2022:10:17:54 +0100] "POST /zabbix/index.php HTTP/1.1" 200 2182 "http://zabbixserver/zabbix/index.php" "Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/107.0.0.0 Safari/537.36"
    192.168.x.x - - [18/Nov/2022:10:19:47 +0100] "POST /zabbix/index.php HTTP/1.1" 200 2199 "http://zabbixserver/zabbix/index.php" "Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/107.0.0.0 Safari/537.36"
    192.168.x.x - - [18/Nov/2022:10:20:38 +0100] "-" 408 0 "-" "-"


    /var/log/apache2/error.log
    [Fri Nov 18 09:51:13.756267 2022] [core:notice] [pid 4801] AH00094: Command line: '/usr/sbin/apache2'
    [Fri Nov 18 09:51:27.718920 2022] [php:warn] [pid 4827] [client 192.168.x.x:54815] PHP Warning: Trying to access array offset on value of type null in /usr/share/zabbix/include/classes/core/CCookieSession.php on line 194
    [Fri Nov 18 09:51:31.405795 2022] [php:warn] [pid 4827] [client 192.168.x.x:54815] PHP Warning: Trying to access array offset on value of type null in /usr/share/zabbix/include/classes/core/CCookieSession.php on line 194, referer: http://zabbixserver/zabbix/setup.php
    [Fri Nov 18 09:51:32.541824 2022] [php:warn] [pid 4827] [client 192.168.x.x:54815] PHP Warning: Trying to access array offset on value of type null in /usr/share/zabbix/include/classes/core/CCookieSession.php on line 194, referer: http://zabbixserver/zabbix/setup.php
    [Fri Nov 18 09:51:47.486190 2022] [php:warn] [pid 4826] [client 192.168.x.x:54843] PHP Warning: Trying to access array offset on value of type null in /usr/share/zabbix/include/classes/core/CCookieSession.php on line 194, referer: http://zabbixserver/zabbix/setup.php
    [Fri Nov 18 09:51:57.767201 2022] [php:warn] [pid 4829] [client 192.168.x.x:54856] PHP Warning: Trying to access array offset on value of type null in /usr/share/zabbix/include/classes/core/CCookieSession.php on line 194, referer: http://zabbixserver/zabbix/setup.php
    [Fri Nov 18 09:52:02.340035 2022] [php:warn] [pid 4829] [client 192.168.x.x:54856] PHP Warning: Trying to access array offset on value of type null in /usr/share/zabbix/include/classes/core/CCookieSession.php on line 194, referer: http://zabbixserver/zabbix/setup.php
    [Fri Nov 18 10:19:39.606009 2022] [mpm_prefork:notice] [pid 4801] AH00170: caught SIGWINCH, shutting down gracefully
    [Fri Nov 18 10:19:40.708964 2022] [mpm_prefork:notice] [pid 10692] AH00163: Apache/2.4.54 (Ubuntu) configured -- resuming normal operations
    [Fri Nov 18 10:19:40.709022 2022] [core:notice] [pid 10692] AH00094: Command line: '/usr/sbin/apache2'


    /var/log/mysql/error.log
    2022-11-18T08:41:35.627001Z 0 [Warning] [MY-010068] [Server] CA certificate ca.pem is self signed.
    2022-11-18T08:41:35.627054Z 0 [System] [MY-013602] [Server] Channel mysql_main configured to support TLS. Encrypted connections are now supported for this channel.
    2022-11-18T08:41:35.755600Z 0 [System] [MY-011323] [Server] X Plugin ready for connections. Bind-address: '127.0.0.1' port: 33060, socket: /var/run/mysqld/mysqlx.sock
    2022-11-18T08:41:35.755919Z 0 [System] [MY-010931] [Server] /usr/sbin/mysqld: ready for connections. Version: '8.0.31-0ubuntu0.22.04.1' socket: '/var/run/mysqld/mysqld.sock' port: 3306 (Ubuntu).


    /var/log/zabbix/zabbix_server.log
    1222:20221118:100013.831 Zabbix Server stopped. Zabbix 6.4.0beta3 (revision 2aeaf5a6e70).
    6161:20221118:100013.875 Starting Zabbix Server. Zabbix 6.4.0beta3 (revision 2aeaf5a6e70).
    6161:20221118:100013.875 ****** Enabled features ******
    6161:20221118:100013.875 SNMP monitoring: YES
    6161:20221118:100013.875 IPMI monitoring: YES
    6161:20221118:100013.875 Web monitoring: YES
    6161:20221118:100013.875 VMware monitoring: YES
    6161:20221118:100013.875 SMTP authentication: YES
    6161:20221118:100013.875 ODBC: YES
    6161:20221118:100013.875 SSH support: YES
    6161:20221118:100013.875 IPv6 support: YES
    6161:20221118:100013.875 TLS support: YES
    6161:20221118:100013.875 ******************************
    6161:20221118:100013.875 using configuration file: /etc/zabbix/zabbix_server.conf
    6161:20221118:100013.932 current database version (mandatory/optional): 06030063/06030063
    6161:20221118:100013.932 required mandatory version: 06030063
    6161:20221118:100013.942 database could be upgraded to use primary keys in history tables
    6161:20221118:100013.985 database is not upgraded to use double precision values
    6164:20221118:100013.989 starting HA manager
    6164:20221118:100014.022 HA manager started in active mode


    CONF:
    /etc/zabbix/zabbix_server.conf
    LogFile=/var/log/zabbix/zabbix_server.log
    LogFileSize=0
    PidFile=/var/run/zabbix/zabbix_server.pid
    DBHost=localhost
    DBName=zabbix
    DBUser=zabbix
    DBPassword=MyZabbixPasswordWichIsNotThisOne
    DBSocket=/var/run/mysqld/mysqld.sock
    StartPollersUnreachable=4
    StartTrappers=8
    StartPingers=10
    StartDiscoverers=10
    StartEscalators=4
    StartVMwareCollectors=1
    CacheSize=512M
    StartDBSyncers=8
    HistoryCacheSize=160M
    HistoryIndexCacheSize=40M
    TrendCacheSize=40M
    ValueCacheSize=80M
    Timeout=6
    AlertScriptsPath=/usr/lib/zabbix/alertscripts
    ExternalScripts=/usr/lib/zabbix/externalscripts
    FpingLocation=/usr/bin/fping
    LogSlowQueries=3000

    Here is my conf :
    Ubuntu 22.04.1 LTS
    Server version: Apache/2.4.54 (Ubuntu)
    PHP 8.1.12 (cli) (built: Oct 28 2022 17:39:57) (NTS)
    mysql Server version: 8.0.31-0ubuntu0.22.04.1 (Ubuntu)
    zabbix_server (Zabbix) 6.4.0beta3

    Thank's a lot for your help....

    SOLVED: hashing problem using MD5 instead of bcrypt / check : https://www.zabbix.com/forum/zabbix-...zabbix-lts-5-0
    Last edited by CMD49; 18-11-2022, 12:29.
  • Answer selected by CMD49 at 18-11-2022, 12:29.
    cyber
    Senior Member
    Zabbix Certified SpecialistZabbix Certified Professional
    • Dec 2006
    • 4807

    There was a password hashing change somewhere in between those versions... from md5 to bcrypt.. And there were some notes about this, which I cannot find right now.. Something updating it to correct one during first use...
    And going to beta versions ... for playground fine, but not for prod env....

    Comment

    • cyber
      Senior Member
      Zabbix Certified SpecialistZabbix Certified Professional
      • Dec 2006
      • 4807

      #2
      There was a password hashing change somewhere in between those versions... from md5 to bcrypt.. And there were some notes about this, which I cannot find right now.. Something updating it to correct one during first use...
      And going to beta versions ... for playground fine, but not for prod env....

      Comment

      • CMD49
        Junior Member
        • Oct 2017
        • 4

        #3
        Hi, and thank's for your answer, I'm going to check into this !
        That's the best hope I've seen so far ! (I'm on this since 6 hours !).
        Yes beta release is a bad move... But I dit not specifically choose it, I did an apt install zabbix_server, perhaps with the wrong repository (???)
        I'm not an expert in linux...

        EDIT: password hashing => OK, but how could it explain login incorrect even with no password or in Guest?
        EDIT2: what is the "good" release to have in my case? Can I downgrade without risk?

        EDIT3:You're the guy !!!! problem solved ! Change hashing in DB, and get successull login ! Thank's a lot for your help.
        Last edited by CMD49; 18-11-2022, 12:24.

        Comment

        • cyber
          Senior Member
          Zabbix Certified SpecialistZabbix Certified Professional
          • Dec 2006
          • 4807

          #4
          Glad I could help...

          Safest release is always LTS, currently 6.0LTS. There is also 6.2 out. which is probably a bit more cutting edge than 6.0, but may have a bit more bugs also. New features, developed with 6.2 and 6.4 will end up in 7.0LTS, but will not be backported to 6.0..

          Comment

          Working...