Unable to log in to my LibreNMS

Hello,

I too woke up this morning unable to log in to my LibreNMS. Using the same credentials I’ve used since first set up. I’ve changed nothing on the server or Docker install/config. I’ve found nothing yet in the logs to indicate any error. I have seen a number of deprecation warnings but nothing that seems related to a problem connecting to the DB or other.

docker-compose.yml

version: "3.5"

x-env-global: &env-global
  - &MYSQL_DATABASE "librenms"
  - &MYSQL_USER "librenms"
  - &MYSQL_PASSWORD <obfuscated>
  - &TZ "America/Phoenix"
  - &PUID "1001"
  - &PGID "999"

x-envlibrenms: &envlibrenms
  MEMORY_LIMIT: "256M"
  UPLOAD_MAX_SIZE: "16M"
  OPCACHE_MEM_SIZE: "128"
  REAL_IP_FROM: "0.0.0.0/32"
  REAL_IP_HEADER: "X-Forwarded-For"
  LOG_IP_VAR: "remote_addr"
  LIBRENMS_SNMP_COMMUNITY: <obfuscated>
  MEMCACHED_HOST: "memcached"
  MEMCACHED_PORT: "11211"
  LIBRENMS_WEATHERMAP: "true"
  LIBRENMS_WEATHERMAP_SCHEDULE: "*/5 * * * *"

services:
  db:
    image: mariadb:10.4
    command:
      - "mysqld"
      - "--innodb-file-per-table=1"
      - "--lower-case-table-names=0"
      - "--character-set-server=utf8"
      - "--collation-server=utf8_unicode_ci"
    volumes:
      - ${PWD}/librenms/db:/var/lib/mysql
    environment:
      TZ: *TZ
      #MYSQL_ALLOW_EMPTY_PASSWORD: "yes"
      MYSQL_DATABASE: *MYSQL_DATABASE
      MYSQL_USER: *MYSQL_USER
      MYSQL_PASSWORD: *MYSQL_PASSWORD
      MYSQL_ROOT_PASSWORD: <obfuscated>
    networks:
      - librenms_network 
    restart: always

  memcached:
    image: memcached:alpine
    environment:
      TZ: *TZ
    networks:
      - librenms_network 
    restart: always

  redis:
    image: redis:5.0-alpine
    environment:
      TZ: *TZ
    restart: always

  librenms:
    image: librenms/librenms:edge
    hostname: librenms
    cap_add:
      - NET_ADMIN
      - NET_RAW
    ports:
      - 8999:8000
    depends_on:
      - db
      - memcached
    volumes:
      - ${PWD}/librenms/librenms:/data
      - ${PWD}/snmp_conf/snmpd.conf:/etc/snmp/snmpd.conf
    environment:
      <<: *envlibrenms
      TZ: *TZ
      PUID: *PUID
      PGID: *PGID
      DB_HOST: "db"
      DB_NAME: *MYSQL_DATABASE
      DB_USER: *MYSQL_USER
      DB_PASSWORD: *MYSQL_PASSWORD
      DB_TIMEOUT: "60"
    networks:
      - librenms_network 
    restart: always

  dispatcher:
    image: librenms/librenms:edge
    hostname: librenms-dispatcher-1234
    cap_add:
      - NET_ADMIN
      - NET_RAW
    depends_on:
      - librenms
      - redis
    volumes:
      - ${PWD}/librenms/librenms:/data
    environment:
      <<: *envlibrenms
      TZ: *TZ
      PUID: *PUID
      PGID: *PGID
      DB_HOST: "db"
      DB_NAME: *MYSQL_DATABASE
      DB_USER: *MYSQL_USER
      DB_PASSWORD: *MYSQL_PASSWORD
      DB_TIMEOUT: "60"
      DISPATCHER_NODE_ID: "dispatcher1234"
      REDIS_HOST: "redis"
      REDIS_PORT: "6379"
      REDIS_DB: "0"
      SIDECAR_DISPATCHER: "1"
    networks:
      - librenms_network 
    restart: always

  dispatcher2:
    image: librenms/librenms:edge
    hostname: librenms-dispatcher-5678
    cap_add:
      - NET_ADMIN
      - NET_RAW
    depends_on:
      - librenms
      - redis
    volumes:
      - ${PWD}/librenms/librenms:/data
    environment:
      <<: *envlibrenms
      TZ: *TZ
      PUID: *PUID
      PGID: *PGID
      DB_HOST: "db"
      DB_NAME: *MYSQL_DATABASE
      DB_USER: *MYSQL_USER
      DB_PASSWORD: *MYSQL_PASSWORD
      DB_TIMEOUT: "60"
      DISPATCHER_NODE_ID: "dispatcher5678"
      REDIS_HOST: "redis"
      REDIS_PORT: "6379"
      REDIS_DB: "0"
      SIDECAR_DISPATCHER: "1"
    networks:
      - librenms_network 
    restart: always

  syslogng:
    image: librenms/librenms:edge
    hostname: librenms-syslogng
    cap_add:
      - NET_ADMIN
      - NET_RAW
    depends_on:
      - librenms
    volumes:
      - ${PWD}/librenms/librenms:/data
    environment:
      <<: *envlibrenms
      TZ: *TZ
      PUID: *PUID
      PGID: *PGID
      DB_HOST: "db"
      DB_NAME: *MYSQL_DATABASE
      DB_USER: *MYSQL_USER
      DB_PASSWORD: *MYSQL_PASSWORD
      DB_TIMEOUT: "60"
      SIDECAR_SYSLOGNG: "1"
    networks:
      - librenms_network
    restart: always

networks:
  librenms_network:
    external:
      name: librenms_network

Enter LibreNMS container and run ./daily.sh and ./validate.php

services-admin@docker1:(10.0.2.249)~/DockerServices/librenms$ docker exec -it -u librenms librenms_librenms_1 bash
bash-5.0$ cd /opt/librenms/
bash-5.0$ ./daily.sh 
Updating SQL-Schema                                OK
Cleaning up DB                                     OK
bash-5.0$ ./validate.php 
====================================
Component | Version
--------- | -------
LibreNMS  | 1.70.1
DB Schema | 2021_02_09_084318_remove_perf_times (199)
PHP       | 7.3.25
Python    | 3.8.5
MySQL     | 10.4.17-MariaDB-1:10.4.17+maria~focal
RRDTool   | 1.7.2
SNMP      | NET-SNMP 5.8
OpenSSL   | 
====================================

[OK]    Installed from the official Docker image; no Composer required
[OK]    Database connection successful
[WARN]  Your database schema has extra migrations (2020_09_18_230114_create_service_templates_device_group_table, 2020_09_18_230114_create_service_templates_device_table, 2020_09_18_230114_create_service_templates_table, 2020_09_18_230114_extend_services_table_for_service_templates_table, 2020_09_19_230114_add_foreign_keys_to_service_templates_device_group_table, 2020_09_19_230114_add_foreign_keys_to_service_templates_device_table, 2021_02_08_224355_fix_invalid_dates, 2021_02_09_084318_remove_perf_times). If you just switched to the stable release from the daily release, your database is in between releases and this will be resolved with the next release.
[OK]    Database schema correct
[WARN]  IPv6 is disabled on your server, you will not be able to add IPv6 devices.
[WARN]  Log rotation not enabled, could cause disk space issues
        [FIX]: 
        sudo cp /opt/librenms/misc/librenms.logrotate /etc/logrotate.d/librenms
[WARN]  Updates are managed through the official Docker image
bash-5.0$ 

How is it that I see a [WARN] issue with the DB Schema and then the vary next line states [OK]? And still unable to log in.

Thank you

Hello,

I woke up this morning unable to log in to my LibreNMS. Using the same credentials I’ve used since first set up, about two months ago. I’m a 15 yr vet of Nagios w/ many custom checks I’ve written. I’ve changed nothing on the server or Docker install/config. I’ve found nothing yet in the logs to indicate any error. I have seen a number of deprecation warnings but nothing that seems related to a problem connecting to the DB or other. Since this is such a new install having to reinstall isn’t the end of the world, but as a SysAdmin, knowing and resolving the issue would be my preferred outcome. I don’t want to have to experience this issue again, for obvious reasons.

To start, does it have anything to do with …:edge release of the docker image? I, like a rookie, missed that in my initial deployment. Is there a stable? I’m thinking your “edge” tag is latest?

docker-compose.yml

version: "3.5"

x-env-global: &env-global
  - &MYSQL_DATABASE "librenms"
  - &MYSQL_USER "librenms"
  - &MYSQL_PASSWORD <obfuscated>
  - &TZ "America/Phoenix"
  - &PUID "1001"
  - &PGID "999"

x-envlibrenms: &envlibrenms
  MEMORY_LIMIT: "256M"
  UPLOAD_MAX_SIZE: "16M"
  OPCACHE_MEM_SIZE: "128"
  REAL_IP_FROM: "0.0.0.0/32"
  REAL_IP_HEADER: "X-Forwarded-For"
  LOG_IP_VAR: "remote_addr"
  LIBRENMS_SNMP_COMMUNITY: <obfuscated>
  MEMCACHED_HOST: "memcached"
  MEMCACHED_PORT: "11211"
  LIBRENMS_WEATHERMAP: "true"
  LIBRENMS_WEATHERMAP_SCHEDULE: "*/5 * * * *"

services:
  db:
    image: mariadb:10.4
    command:
      - "mysqld"
      - "--innodb-file-per-table=1"
      - "--lower-case-table-names=0"
      - "--character-set-server=utf8"
      - "--collation-server=utf8_unicode_ci"
    volumes:
      - ${PWD}/librenms/db:/var/lib/mysql
    environment:
      TZ: *TZ
      #MYSQL_ALLOW_EMPTY_PASSWORD: "yes"
      MYSQL_DATABASE: *MYSQL_DATABASE
      MYSQL_USER: *MYSQL_USER
      MYSQL_PASSWORD: *MYSQL_PASSWORD
      MYSQL_ROOT_PASSWORD: <obfuscated>
    networks:
      - librenms_network 
    restart: always

  memcached:
    image: memcached:alpine
    environment:
      TZ: *TZ
    networks:
      - librenms_network 
    restart: always

  redis:
    image: redis:5.0-alpine
    environment:
      TZ: *TZ
    restart: always

  librenms:
    image: librenms/librenms:edge
    hostname: librenms
    cap_add:
      - NET_ADMIN
      - NET_RAW
    ports:
      - 8999:8000
    depends_on:
      - db
      - memcached
    volumes:
      - ${PWD}/librenms/librenms:/data
      - ${PWD}/snmp_conf/snmpd.conf:/etc/snmp/snmpd.conf
    environment:
      <<: *envlibrenms
      TZ: *TZ
      PUID: *PUID
      PGID: *PGID
      DB_HOST: "db"
      DB_NAME: *MYSQL_DATABASE
      DB_USER: *MYSQL_USER
      DB_PASSWORD: *MYSQL_PASSWORD
      DB_TIMEOUT: "60"
    networks:
      - librenms_network 
    restart: always

  dispatcher:
    image: librenms/librenms:edge
    hostname: librenms-dispatcher-1234
    cap_add:
      - NET_ADMIN
      - NET_RAW
    depends_on:
      - librenms
      - redis
    volumes:
      - ${PWD}/librenms/librenms:/data
    environment:
      <<: *envlibrenms
      TZ: *TZ
      PUID: *PUID
      PGID: *PGID
      DB_HOST: "db"
      DB_NAME: *MYSQL_DATABASE
      DB_USER: *MYSQL_USER
      DB_PASSWORD: *MYSQL_PASSWORD
      DB_TIMEOUT: "60"
      DISPATCHER_NODE_ID: "dispatcher1234"
      REDIS_HOST: "redis"
      REDIS_PORT: "6379"
      REDIS_DB: "0"
      SIDECAR_DISPATCHER: "1"
    networks:
      - librenms_network 
    restart: always

  dispatcher2:
    image: librenms/librenms:edge
    hostname: librenms-dispatcher-5678
    cap_add:
      - NET_ADMIN
      - NET_RAW
    depends_on:
      - librenms
      - redis
    volumes:
      - ${PWD}/librenms/librenms:/data
    environment:
      <<: *envlibrenms
      TZ: *TZ
      PUID: *PUID
      PGID: *PGID
      DB_HOST: "db"
      DB_NAME: *MYSQL_DATABASE
      DB_USER: *MYSQL_USER
      DB_PASSWORD: *MYSQL_PASSWORD
      DB_TIMEOUT: "60"
      DISPATCHER_NODE_ID: "dispatcher5678"
      REDIS_HOST: "redis"
      REDIS_PORT: "6379"
      REDIS_DB: "0"
      SIDECAR_DISPATCHER: "1"
    networks:
      - librenms_network 
    restart: always

  syslogng:
    image: librenms/librenms:edge
    hostname: librenms-syslogng
    cap_add:
      - NET_ADMIN
      - NET_RAW
    depends_on:
      - librenms
    volumes:
      - ${PWD}/librenms/librenms:/data
    environment:
      <<: *envlibrenms
      TZ: *TZ
      PUID: *PUID
      PGID: *PGID
      DB_HOST: "db"
      DB_NAME: *MYSQL_DATABASE
      DB_USER: *MYSQL_USER
      DB_PASSWORD: *MYSQL_PASSWORD
      DB_TIMEOUT: "60"
      SIDECAR_SYSLOGNG: "1"
    networks:
      - librenms_network
    restart: always

networks:
  librenms_network:
    external:
      name: librenms_network

Enter LibreNMS container and run ./daily.sh and ./validate.php

services-admin@docker1:(10.0.2.249)~/DockerServices/librenms$ docker exec -it -u librenms librenms_librenms_1 bash
bash-5.0$ cd /opt/librenms/
bash-5.0$ ./daily.sh 
Updating SQL-Schema                                OK
Cleaning up DB                                     OK
bash-5.0$ ./validate.php 
====================================
Component | Version
--------- | -------
LibreNMS  | 1.70.1
DB Schema | 2021_02_09_084318_remove_perf_times (199)
PHP       | 7.3.25
Python    | 3.8.5
MySQL     | 10.4.17-MariaDB-1:10.4.17+maria~focal
RRDTool   | 1.7.2
SNMP      | NET-SNMP 5.8
OpenSSL   | 
====================================

[OK]    Installed from the official Docker image; no Composer required
[OK]    Database connection successful
[WARN]  Your database schema has extra migrations (2020_09_18_230114_create_service_templates_device_group_table, 2020_09_18_230114_create_service_templates_device_table, 2020_09_18_230114_create_service_templates_table, 2020_09_18_230114_extend_services_table_for_service_templates_table, 2020_09_19_230114_add_foreign_keys_to_service_templates_device_group_table, 2020_09_19_230114_add_foreign_keys_to_service_templates_device_table, 2021_02_08_224355_fix_invalid_dates, 2021_02_09_084318_remove_perf_times). If you just switched to the stable release from the daily release, your database is in between releases and this will be resolved with the next release.
[OK]    Database schema correct
[WARN]  IPv6 is disabled on your server, you will not be able to add IPv6 devices.
[WARN]  Log rotation not enabled, could cause disk space issues
        [FIX]: 
        sudo cp /opt/librenms/misc/librenms.logrotate /etc/logrotate.d/librenms
[WARN]  Updates are managed through the official Docker image
bash-5.0$ 

How is it that I see a [WARN] issue with the DB Schema and then the very next line states [OK]? And still unable to log in.

Thank you

UPDATE:

I did some additional poking around and can verify that the login request is making it’s way to the database. Since I didn’t change my login username:password, is there a problem with the LibreNMS (edge) code that handles the response from the SQL query to lookup a user or is the DB corrupt?

Connection activity initiated by a login attempt

root@7ceb0da3b8f3:/# apt update && apt install tcpdump
root@7ceb0da3b8f3:/# 
...
...
root@7ceb0da3b8f3:/# 
root@7ceb0da3b8f3:/# tcpdump -i eth0 -XX -vvvv dst port 3306 and src 192.168.9.4
tcpdump: listening on eth0, link-type EN10MB (Ethernet), capture size 262144 bytes
07:47:59.965061 IP (tos 0x0, ttl 64, id 39591, offset 0, flags [DF], proto TCP (6), length 60)
    librenms_librenms_1.librenms_network.56642 > 7ceb0da3b8f3.mysql: Flags [S], cksum 0x9385 (incorrect -> 0x4b2b), seq 51381272, win 64240, options [mss 1460,sackOK,TS val 2548688206 ecr 0,nop,wscale 7], length 0
        0x0000:  0242 c0a8 0902 0242 c0a8 0904 0800 4500  .B.....B......E.
        0x0010:  003c 9aa7 4000 4006 0cbe c0a8 0904 c0a8  .<..@.@.........
        0x0020:  0902 dd42 0cea 0310 0418 0000 0000 a002  ...B............
        0x0030:  faf0 9385 0000 0204 05b4 0402 080a 97e9  ................
        0x0040:  e54e 0000 0000 0103 0307                 .N........
07:47:59.965147 IP (tos 0x0, ttl 64, id 39592, offset 0, flags [DF], proto TCP (6), length 52)
    librenms_librenms_1.librenms_network.56642 > 7ceb0da3b8f3.mysql: Flags [.], cksum 0x937d (incorrect -> 0x518c), seq 51381273, ack 12692332, win 502, options [nop,nop,TS val 2548688206 ecr 168586012], length 0
        0x0000:  0242 c0a8 0902 0242 c0a8 0904 0800 4500  .B.....B......E.
        0x0010:  0034 9aa8 4000 4006 0cc5 c0a8 0904 c0a8  .4..@.@.........
        0x0020:  0902 dd42 0cea 0310 0419 00c1 ab6c 8010  ...B.........l..
        0x0030:  01f6 937d 0000 0101 080a 97e9 e54e 0a0c  ...}.........N..
        0x0040:  6b1c                                     k.
07:47:59.965556 IP (tos 0x0, ttl 64, id 39593, offset 0, flags [DF], proto TCP (6), length 52)
    librenms_librenms_1.librenms_network.56642 > 7ceb0da3b8f3.mysql: Flags [.], cksum 0x937d (incorrect -> 0x5117), seq 0, ack 116, win 502, options [nop,nop,TS val 2548688207 ecr 168586013], length 0
        0x0000:  0242 c0a8 0902 0242 c0a8 0904 0800 4500  .B.....B......E.
        0x0010:  0034 9aa9 4000 4006 0cc4 c0a8 0904 c0a8  .4..@.@.........
        0x0020:  0902 dd42 0cea 0310 0419 00c1 abdf 8010  ...B............
        0x0030:  01f6 937d 0000 0101 080a 97e9 e54f 0a0c  ...}.........O..
        0x0040:  6b1d                                     k.
07:47:59.965636 IP (tos 0x0, ttl 64, id 39594, offset 0, flags [DF], proto TCP (6), length 187)
    librenms_librenms_1.librenms_network.56642 > 7ceb0da3b8f3.mysql: Flags [P.], cksum 0x9404 (incorrect -> 0xcc23), seq 0:135, ack 116, win 502, options [nop,nop,TS val 2548688207 ecr 168586013], length 135
        0x0000:  0242 c0a8 0902 0242 c0a8 0904 0800 4500  .B.....B......E.
        0x0010:  00bb 9aaa 4000 4006 0c3c c0a8 0904 c0a8  ....@.@..<......
        0x0020:  0902 dd42 0cea 0310 0419 00c1 abdf 8018  ...B............
        0x0030:  01f6 9404 0000 0101 080a 97e9 e54f 0a0c  .............O..
        0x0040:  6b1d 8300 0001 8da2 1b00 0000 00c0 c000  k...............
        0x0050:  0000 0000 0000 0000 0000 0000 0000 0000  ................
        0x0060:  0000 0000 0000 6c69 6272 656e 6d73 0014  ......librenms..
        0x0070:  7d7c 0ed3 4a4c 699b d448 82ae 8943 6c83  }|..JLi..H...Cl.
        0x0080:  5f89 123d 6c69 6272 656e 6d73 006d 7973  _..=librenms.mys
        0x0090:  716c 5f6e 6174 6976 655f 7061 7373 776f  ql_native_passwo
        0x00a0:  7264 0025 0c5f 636c 6965 6e74 5f6e 616d  rd.%._client_nam
        0x00b0:  6507 6d79 7371 6c6e 640c 5f73 6572 7665  e.mysqlnd._serve
        0x00c0:  725f 686f 7374 0264 62                   r_host.db
07:47:59.966181 IP (tos 0x0, ttl 64, id 39595, offset 0, flags [DF], proto TCP (6), length 72)
    librenms_librenms_1.librenms_network.56642 > 7ceb0da3b8f3.mysql: Flags [P.], cksum 0x9391 (incorrect -> 0xa735), seq 135:155, ack 127, win 502, options [nop,nop,TS val 2548688207 ecr 168586013], length 20
        0x0000:  0242 c0a8 0902 0242 c0a8 0904 0800 4500  .B.....B......E.
        0x0010:  0048 9aab 4000 4006 0cae c0a8 0904 c0a8  .H..@.@.........
        0x0020:  0902 dd42 0cea 0310 04a0 00c1 abea 8018  ...B............
        0x0030:  01f6 9391 0000 0101 080a 97e9 e54f 0a0c  .............O..
        0x0040:  6b1d 1000 0000 0375 7365 2060 6c69 6272  k......use.`libr
        0x0050:  656e 6d73 603b                           enms`;
07:47:59.966402 IP (tos 0x0, ttl 64, id 39596, offset 0, flags [DF], proto TCP (6), length 99)
    librenms_librenms_1.librenms_network.56642 > 7ceb0da3b8f3.mysql: Flags [P.], cksum 0x93ac (incorrect -> 0xf659), seq 155:202, ack 138, win 502, options [nop,nop,TS val 2548688207 ecr 168586013], length 47
        0x0000:  0242 c0a8 0902 0242 c0a8 0904 0800 4500  .B.....B......E.
        0x0010:  0063 9aac 4000 4006 0c92 c0a8 0904 c0a8  .c..@.@.........
        0x0020:  0902 dd42 0cea 0310 04b4 00c1 abf5 8018  ...B............
        0x0030:  01f6 93ac 0000 0101 080a 97e9 e54f 0a0c  .............O..
        0x0040:  6b1d 2b00 0000 1673 6574 206e 616d 6573  k.+....set.names
        0x0050:  2027 7574 6638 2720 636f 6c6c 6174 6520  .'utf8'.collate.
        0x0060:  2775 7466 385f 756e 6963 6f64 655f 6369  'utf8_unicode_ci
        0x0070:  27                                       '
07:47:59.966736 IP (tos 0x0, ttl 64, id 39597, offset 0, flags [DF], proto TCP (6), length 66)
    librenms_librenms_1.librenms_network.56642 > 7ceb0da3b8f3.mysql: Flags [P.], cksum 0x938b (incorrect -> 0xb4c5), seq 202:216, ack 154, win 502, options [nop,nop,TS val 2548688208 ecr 168586014], length 14
        0x0000:  0242 c0a8 0902 0242 c0a8 0904 0800 4500  .B.....B......E.
        0x0010:  0042 9aad 4000 4006 0cb2 c0a8 0904 c0a8  .B..@.@.........
        0x0020:  0902 dd42 0cea 0310 04e3 00c1 ac05 8018  ...B............
        0x0030:  01f6 938b 0000 0101 080a 97e9 e550 0a0c  .............P..
        0x0040:  6b1e 0a00 0000 1749 7900 0000 0100 0000  k......Iy.......
07:47:59.966840 IP (tos 0x0, ttl 64, id 39598, offset 0, flags [DF], proto TCP (6), length 61)
    librenms_librenms_1.librenms_network.56642 > 7ceb0da3b8f3.mysql: Flags [P.], cksum 0x9386 (incorrect -> 0xb8b1), seq 216:225, ack 165, win 502, options [nop,nop,TS val 2548688208 ecr 168586014], length 9
        0x0000:  0242 c0a8 0902 0242 c0a8 0904 0800 4500  .B.....B......E.
        0x0010:  003d 9aae 4000 4006 0cb6 c0a8 0904 c0a8  .=..@.@.........
        0x0020:  0902 dd42 0cea 0310 04f1 00c1 ac10 8018  ...B............
        0x0030:  01f6 9386 0000 0101 080a 97e9 e550 0a0c  .............P..
        0x0040:  6b1e 0500 0000 1949 7900 00              k......Iy..
07:47:59.966935 IP (tos 0x0, ttl 64, id 39599, offset 0, flags [DF], proto TCP (6), length 217)
    librenms_librenms_1.librenms_network.56642 > 7ceb0da3b8f3.mysql: Flags [P.], cksum 0x9422 (incorrect -> 0x69fd), seq 225:390, ack 165, win 502, options [nop,nop,TS val 2548688208 ecr 168586014], length 165
        0x0000:  0242 c0a8 0902 0242 c0a8 0904 0800 4500  .B.....B......E.
        0x0010:  00d9 9aaf 4000 4006 0c19 c0a8 0904 c0a8  ....@.@.........
        0x0020:  0902 dd42 0cea 0310 04fa 00c1 ac10 8018  ...B............
        0x0030:  01f6 9422 0000 0101 080a 97e9 e550 0a0c  ...".........P..
        0x0040:  6b1e a100 0000 1673 6574 2073 6573 7369  k......set.sessi
        0x0050:  6f6e 2073 716c 5f6d 6f64 653d 274f 4e4c  on.sql_mode='ONL
        0x0060:  595f 4655 4c4c 5f47 524f 5550 5f42 592c  Y_FULL_GROUP_BY,
        0x0070:  5354 5249 4354 5f54 5241 4e53 5f54 4142  STRICT_TRANS_TAB
        0x0080:  4c45 532c 4e4f 5f5a 4552 4f5f 494e 5f44  LES,NO_ZERO_IN_D
        0x0090:  4154 452c 4e4f 5f5a 4552 4f5f 4441 5445  ATE,NO_ZERO_DATE
        0x00a0:  2c45 5252 4f52 5f46 4f52 5f44 4956 4953  ,ERROR_FOR_DIVIS
        0x00b0:  494f 4e5f 4259 5f5a 4552 4f2c 4e4f 5f41  ION_BY_ZERO,NO_A
        0x00c0:  5554 4f5f 4352 4541 5445 5f55 5345 522c  UTO_CREATE_USER,
        0x00d0:  4e4f 5f45 4e47 494e 455f 5355 4253 5449  NO_ENGINE_SUBSTI
        0x00e0:  5455 5449 4f4e 27                        TUTION'
07:47:59.967208 IP (tos 0x0, ttl 64, id 39600, offset 0, flags [DF], proto TCP (6), length 66)
    librenms_librenms_1.librenms_network.56642 > 7ceb0da3b8f3.mysql: Flags [P.], cksum 0x938b (incorrect -> 0xb3ed), seq 390:404, ack 181, win 502, options [nop,nop,TS val 2548688208 ecr 168586014], length 14
        0x0000:  0242 c0a8 0902 0242 c0a8 0904 0800 4500  .B.....B......E.
        0x0010:  0042 9ab0 4000 4006 0caf c0a8 0904 c0a8  .B..@.@.........
        0x0020:  0902 dd42 0cea 0310 059f 00c1 ac20 8018  ...B............
        0x0030:  01f6 938b 0000 0101 080a 97e9 e550 0a0c  .............P..
        0x0040:  6b1e 0a00 0000 174a 7900 0000 0100 0000  k......Jy.......
07:47:59.967318 IP (tos 0x0, ttl 64, id 39601, offset 0, flags [DF], proto TCP (6), length 61)
    librenms_librenms_1.librenms_network.56642 > 7ceb0da3b8f3.mysql: Flags [P.], cksum 0x9386 (incorrect -> 0xb7d9), seq 404:413, ack 192, win 502, options [nop,nop,TS val 2548688208 ecr 168586014], length 9
        0x0000:  0242 c0a8 0902 0242 c0a8 0904 0800 4500  .B.....B......E.
        0x0010:  003d 9ab1 4000 4006 0cb3 c0a8 0904 c0a8  .=..@.@.........
        0x0020:  0902 dd42 0cea 0310 05ad 00c1 ac2b 8018  ...B.........+..
        0x0030:  01f6 9386 0000 0101 080a 97e9 e550 0a0c  .............P..
        0x0040:  6b1e 0500 0000 194a 7900 00              k......Jy..
07:47:59.971030 IP (tos 0x0, ttl 64, id 39602, offset 0, flags [DF], proto TCP (6), length 107)
    librenms_librenms_1.librenms_network.56642 > 7ceb0da3b8f3.mysql: Flags [P.], cksum 0x93b4 (incorrect -> 0x6974), seq 413:468, ack 192, win 502, options [nop,nop,TS val 2548688212 ecr 168586014], length 55
        0x0000:  0242 c0a8 0902 0242 c0a8 0904 0800 4500  .B.....B......E.
        0x0010:  006b 9ab2 4000 4006 0c84 c0a8 0904 c0a8  .k..@.@.........
        0x0020:  0902 dd42 0cea 0310 05b6 00c1 ac2b 8018  ...B.........+..
        0x0030:  01f6 93b4 0000 0101 080a 97e9 e554 0a0c  .............T..
        0x0040:  6b1e 3300 0000 1673 656c 6563 7420 6063  k.3....select.`c
        0x0050:  6f6e 6669 675f 6e61 6d65 602c 2060 636f  onfig_name`,.`co
        0x0060:  6e66 6967 5f76 616c 7565 6020 6672 6f6d  nfig_value`.from
        0x0070:  2060 636f 6e66 6967 60                   .`config`
07:47:59.971379 IP (tos 0x0, ttl 64, id 39603, offset 0, flags [DF], proto TCP (6), length 66)
    librenms_librenms_1.librenms_network.56642 > 7ceb0da3b8f3.mysql: Flags [P.], cksum 0x938b (incorrect -> 0xb2e9), seq 468:482, ack 355, win 501, options [nop,nop,TS val 2548688212 ecr 168586018], length 14
        0x0000:  0242 c0a8 0902 0242 c0a8 0904 0800 4500  .B.....B......E.
        0x0010:  0042 9ab3 4000 4006 0cac c0a8 0904 c0a8  .B..@.@.........
        0x0020:  0902 dd42 0cea 0310 05ed 00c1 acce 8018  ...B............
        0x0030:  01f5 938b 0000 0101 080a 97e9 e554 0a0c  .............T..
        0x0040:  6b22 0a00 0000 174b 7900 0000 0100 0000  k".....Ky.......
07:47:59.971566 IP (tos 0x0, ttl 64, id 39604, offset 0, flags [DF], proto TCP (6), length 61)
    librenms_librenms_1.librenms_network.56642 > 7ceb0da3b8f3.mysql: Flags [P.], cksum 0x9386 (incorrect -> 0xb4ef), seq 482:491, ack 850, win 501, options [nop,nop,TS val 2548688213 ecr 168586019], length 9
        0x0000:  0242 c0a8 0902 0242 c0a8 0904 0800 4500  .B.....B......E.
        0x0010:  003d 9ab4 4000 4006 0cb0 c0a8 0904 c0a8  .=..@.@.........
        0x0020:  0902 dd42 0cea 0310 05fb 00c1 aebd 8018  ...B............
        0x0030:  01f5 9386 0000 0101 080a 97e9 e555 0a0c  .............U..
        0x0040:  6b23 0500 0000 194b 7900 00              k#.....Ky..
07:47:59.973321 IP (tos 0x0, ttl 64, id 39605, offset 0, flags [DF], proto TCP (6), length 84)
    librenms_librenms_1.librenms_network.56642 > 7ceb0da3b8f3.mysql: Flags [P.], cksum 0x939d (incorrect -> 0x30d5), seq 491:523, ack 850, win 501, options [nop,nop,TS val 2548688214 ecr 168586019], length 32
        0x0000:  0242 c0a8 0902 0242 c0a8 0904 0800 4500  .B.....B......E.
        0x0010:  0054 9ab5 4000 4006 0c98 c0a8 0904 c0a8  .T..@.@.........
        0x0020:  0902 dd42 0cea 0310 0604 00c1 aebd 8018  ...B............
        0x0030:  01f5 939d 0000 0101 080a 97e9 e556 0a0c  .............V..
        0x0040:  6b23 1c00 0000 1673 656c 6563 7420 2a20  k#.....select.*.
        0x0050:  6672 6f6d 2060 6772 6170 685f 7479 7065  from.`graph_type
        0x0060:  7360                                     s`
07:47:59.973520 IP (tos 0x0, ttl 64, id 39606, offset 0, flags [DF], proto TCP (6), length 66)
    librenms_librenms_1.librenms_network.56642 > 7ceb0da3b8f3.mysql: Flags [P.], cksum 0x938b (incorrect -> 0xaf18), seq 523:537, ack 1271, win 501, options [nop,nop,TS val 2548688215 ecr 168586020], length 14
        0x0000:  0242 c0a8 0902 0242 c0a8 0904 0800 4500  .B.....B......E.
        0x0010:  0042 9ab6 4000 4006 0ca9 c0a8 0904 c0a8  .B..@.@.........
        0x0020:  0902 dd42 0cea 0310 0624 00c1 b062 8018  ...B.....$...b..
        0x0030:  01f5 938b 0000 0101 080a 97e9 e557 0a0c  .............W..
        0x0040:  6b24 0a00 0000 174c 7900 0000 0100 0000  k$.....Ly.......
07:47:59.973653 IP (tos 0x0, ttl 64, id 39607, offset 0, flags [DF], proto TCP (6), length 61)
    librenms_librenms_1.librenms_network.56642 > 7ceb0da3b8f3.mysql: Flags [P.], cksum 0x9386 (incorrect -> 0xb16b), seq 537:546, ack 1690, win 501, options [nop,nop,TS val 2548688215 ecr 168586021], length 9
        0x0000:  0242 c0a8 0902 0242 c0a8 0904 0800 4500  .B.....B......E.
        0x0010:  003d 9ab7 4000 4006 0cad c0a8 0904 c0a8  .=..@.@.........
        0x0020:  0902 dd42 0cea 0310 0632 00c1 b205 8018  ...B.....2......
        0x0030:  01f5 9386 0000 0101 080a 97e9 e557 0a0c  .............W..
        0x0040:  6b25 0500 0000 194c 7900 00              k%.....Ly..
07:47:59.981039 IP (tos 0x0, ttl 64, id 39608, offset 0, flags [DF], proto TCP (6), length 102)
    librenms_librenms_1.librenms_network.56642 > 7ceb0da3b8f3.mysql: Flags [P.], cksum 0x93af (incorrect -> 0x242e), seq 546:596, ack 1690, win 501, options [nop,nop,TS val 2548688222 ecr 168586021], length 50
        0x0000:  0242 c0a8 0902 0242 c0a8 0904 0800 4500  .B.....B......E.
        0x0010:  0066 9ab8 4000 4006 0c83 c0a8 0904 c0a8  .f..@.@.........
        0x0020:  0902 dd42 0cea 0310 063b 00c1 b205 8018  ...B.....;......
        0x0030:  01f5 93af 0000 0101 080a 97e9 e55e 0a0c  .............^..
        0x0040:  6b25 2e00 0000 1673 656c 6563 7420 2a20  k%.....select.*.
        0x0050:  6672 6f6d 2060 6361 6368 6560 2077 6865  from.`cache`.whe
        0x0060:  7265 2060 6b65 7960 203d 203f 206c 696d  re.`key`.=.?.lim
        0x0070:  6974 2031                                it.1
07:47:59.981492 IP (tos 0x0, ttl 64, id 39609, offset 0, flags [DF], proto TCP (6), length 98)
    librenms_librenms_1.librenms_network.56642 > 7ceb0da3b8f3.mysql: Flags [P.], cksum 0x93ab (incorrect -> 0x1efa), seq 596:642, ack 1919, win 501, options [nop,nop,TS val 2548688223 ecr 168586028], length 46
        0x0000:  0242 c0a8 0902 0242 c0a8 0904 0800 4500  .B.....B......E.
        0x0010:  0062 9ab9 4000 4006 0c86 c0a8 0904 c0a8  .b..@.@.........
        0x0020:  0902 dd42 0cea 0310 066d 00c1 b2ea 8018  ...B.....m......
        0x0030:  01f5 93ab 0000 0101 080a 97e9 e55f 0a0c  ............._..
        0x0040:  6b2c 2a00 0000 174d 7900 0000 0100 0000  k,*....My.......
        0x0050:  0001 fd00 1b6c 6172 6176 656c 5f63 6163  .....laravel_cac
        0x0060:  6865 746f 6e79 647c 3130 2e30 2e32 2e35  hetonyd|10.0.2.5
07:47:59.981828 IP (tos 0x0, ttl 64, id 39610, offset 0, flags [DF], proto TCP (6), length 61)
    librenms_librenms_1.librenms_network.56642 > 7ceb0da3b8f3.mysql: Flags [P.], cksum 0x9386 (incorrect -> 0xaf22), seq 642:651, ack 2153, win 501, options [nop,nop,TS val 2548688223 ecr 168586029], length 9
        0x0000:  0242 c0a8 0902 0242 c0a8 0904 0800 4500  .B.....B......E.
        0x0010:  003d 9aba 4000 4006 0caa c0a8 0904 c0a8  .=..@.@.........
        0x0020:  0902 dd42 0cea 0310 069b 00c1 b3d4 8018  ...B............
        0x0030:  01f5 9386 0000 0101 080a 97e9 e55f 0a0c  ............._..
        0x0040:  6b2d 0500 0000 194d 7900 00              k-.....My..
07:47:59.982148 IP (tos 0x0, ttl 64, id 39611, offset 0, flags [DF], proto TCP (6), length 92)
    librenms_librenms_1.librenms_network.56642 > 7ceb0da3b8f3.mysql: Flags [P.], cksum 0x93a5 (incorrect -> 0x7894), seq 651:691, ack 2153, win 501, options [nop,nop,TS val 2548688223 ecr 168586029], length 40
        0x0000:  0242 c0a8 0902 0242 c0a8 0904 0800 4500  .B.....B......E.
        0x0010:  005c 9abb 4000 4006 0c8a c0a8 0904 c0a8  .\..@.@.........
        0x0020:  0902 dd42 0cea 0310 06a4 00c1 b3d4 8018  ...B............
        0x0030:  01f5 93a5 0000 0101 080a 97e9 e55f 0a0c  ............._..
        0x0040:  6b2d 2400 0000 1664 656c 6574 6520 6672  k-$....delete.fr
        0x0050:  6f6d 2060 6361 6368 6560 2077 6865 7265  om.`cache`.where
        0x0060:  2060 6b65 7960 203d 203f                 .`key`.=.?
07:47:59.982358 IP (tos 0x0, ttl 64, id 39612, offset 0, flags [DF], proto TCP (6), length 98)
    librenms_librenms_1.librenms_network.56642 > 7ceb0da3b8f3.mysql: Flags [P.], cksum 0x93ab (incorrect -> 0x1d7b), seq 691:737, ack 2205, win 501, options [nop,nop,TS val 2548688223 ecr 168586029], length 46
        0x0000:  0242 c0a8 0902 0242 c0a8 0904 0800 4500  .B.....B......E.
        0x0010:  0062 9abc 4000 4006 0c83 c0a8 0904 c0a8  .b..@.@.........
        0x0020:  0902 dd42 0cea 0310 06cc 00c1 b408 8018  ...B............
        0x0030:  01f5 93ab 0000 0101 080a 97e9 e55f 0a0c  ............._..
        0x0040:  6b2d 2a00 0000 174e 7900 0000 0100 0000  k-*....Ny.......
        0x0050:  0001 fd00 1b6c 6172 6176 656c 5f63 6163  .....laravel_cac
        0x0060:  6865 746f 6e79 647c 3130 2e30 2e32 2e35  hetonyd|10.0.2.5
07:47:59.983475 IP (tos 0x0, ttl 64, id 39613, offset 0, flags [DF], proto TCP (6), length 61)
    librenms_librenms_1.librenms_network.56642 > 7ceb0da3b8f3.mysql: Flags [P.], cksum 0x9386 (incorrect -> 0xae80), seq 737:746, ack 2216, win 501, options [nop,nop,TS val 2548688225 ecr 168586030], length 9
        0x0000:  0242 c0a8 0902 0242 c0a8 0904 0800 4500  .B.....B......E.
        0x0010:  003d 9abd 4000 4006 0ca7 c0a8 0904 c0a8  .=..@.@.........
        0x0020:  0902 dd42 0cea 0310 06fa 00c1 b413 8018  ...B............
        0x0030:  01f5 9386 0000 0101 080a 97e9 e561 0a0c  .............a..
        0x0040:  6b2e 0500 0000 194e 7900 00              k......Ny..
07:47:59.984970 IP (tos 0x0, ttl 64, id 39614, offset 0, flags [DF], proto TCP (6), length 179)
    librenms_librenms_1.librenms_network.56642 > 7ceb0da3b8f3.mysql: Flags [P.], cksum 0x93fc (incorrect -> 0xa031), seq 746:873, ack 2216, win 501, options [nop,nop,TS val 2548688226 ecr 168586030], length 127
        0x0000:  0242 c0a8 0902 0242 c0a8 0904 0800 4500  .B.....B......E.
        0x0010:  00b3 9abe 4000 4006 0c30 c0a8 0904 c0a8  ....@[email protected]......
        0x0020:  0902 dd42 0cea 0310 0703 00c1 b413 8018  ...B............
        0x0030:  01f5 93fc 0000 0101 080a 97e9 e562 0a0c  .............b..
        0x0040:  6b2e 7b00 0000 1673 656c 6563 7420 6075  k.{....select.`u
        0x0050:  7365 725f 6964 6020 6672 6f6d 2060 7573  ser_id`.from.`us
        0x0060:  6572 7360 2077 6865 7265 2028 6061 7574  ers`.where.(`aut
        0x0070:  685f 7479 7065 6020 3d20 3f20 6f72 2060  h_type`.=.?.or.`
        0x0080:  6175 7468 5f74 7970 6560 2069 7320 6e75  auth_type`.is.nu
        0x0090:  6c6c 206f 7220 6061 7574 685f 7479 7065  ll.or.`auth_type
        0x00a0:  6020 3d20 3f29 2061 6e64 2060 7573 6572  `.=.?).and.`user
        0x00b0:  6e61 6d65 6020 3d20 3f20 6c69 6d69 7420  name`.=.?.limit.
        0x00c0:  31                                       1
07:47:59.985317 IP (tos 0x0, ttl 64, id 39615, offset 0, flags [DF], proto TCP (6), length 87)
    librenms_librenms_1.librenms_network.56642 > 7ceb0da3b8f3.mysql: Flags [P.], cksum 0x93a0 (incorrect -> 0x65ee), seq 873:908, ack 2389, win 501, options [nop,nop,TS val 2548688226 ecr 168586032], length 35
        0x0000:  0242 c0a8 0902 0242 c0a8 0904 0800 4500  .B.....B......E.
        0x0010:  0057 9abf 4000 4006 0c8b c0a8 0904 c0a8  .W..@.@.........
        0x0020:  0902 dd42 0cea 0310 0782 00c1 b4c0 8018  ...B............
        0x0030:  01f5 93a0 0000 0101 080a 97e9 e562 0a0c  .............b..
        0x0040:  6b30 1f00 0000 174f 7900 0000 0100 0000  k0.....Oy.......
        0x0050:  0001 fd00 fd00 fd00 056d 7973 716c 0005  .........mysql..
        0x0060:  746f 6e79 64                             tonyd
07:47:59.985613 IP (tos 0x0, ttl 64, id 39616, offset 0, flags [DF], proto TCP (6), length 61)
    librenms_librenms_1.librenms_network.56642 > 7ceb0da3b8f3.mysql: Flags [P.], cksum 0x9386 (incorrect -> 0xacc8), seq 908:917, ack 2480, win 501, options [nop,nop,TS val 2548688227 ecr 168586032], length 9
        0x0000:  0242 c0a8 0902 0242 c0a8 0904 0800 4500  .B.....B......E.
        0x0010:  003d 9ac0 4000 4006 0ca4 c0a8 0904 c0a8  .=..@.@.........
        0x0020:  0902 dd42 0cea 0310 07a5 00c1 b51b 8018  ...B............
        0x0030:  01f5 9386 0000 0101 080a 97e9 e563 0a0c  .............c..
        0x0040:  6b30 0500 0000 194f 7900 00              k0.....Oy..
^C
80 packets captured
80 packets received by filter
0 packets dropped by kernel
root@7ceb0da3b8f3:/#

Is there a way I can update/create a user w/ level 10 from either the LibreNMS or DB CLI? That way I can confirm where the issue is at; a bad/corrupt/??? password in the database/users table or with the LIbreNMS php code that handles the Web GUI Authentication.

At this point all I know is that one morning I was no longer able to login. In the years that I used Nagios (which only uses simple HTTP Basic Auth), and Opsview (which uses a DB), I never ran into an issue that locked me out of my installation. So this is very concerning, if I’m to consider using LibreNMS to monitor and rely on notifications.

IMHO this can’t happen w/o 1) Someone changing a password or removing an account. I have confirmed, at least, that my login user still exists in the DB/users table. 2) DB/users table became corrupt, which I find highly unlikely. Never in my 30 yrs as a SysAdmin and Network Engineer have I seen this scenario happen. 3) A problem w/ connectivity to the DB, which I have tested and confirmed all is good. 4) A problem w/ the LibreNMS code.

Any help in resolving this would be greatly appreciated…

Thank you

td

After some additional Googling I found https://github.com/librenms/librenms/blob/master/adduser.php

Then found the adduser.php in the /opt/librenms directory. Using it I added a temp user w/ level 10. For anybody else running into this problem, you can issue the following to gain access. You have to have access to the server/shell of course.

./adduser.php <username> <password> <level> <email>

Following that I was able to log in and change/update my username and now I’m able to log in. Again, for emphasis, I did not change my username causing me to “forget” the password. But having lived in datacenters most of my life, I understand that would be a first go to explanation. I’m convinced something else took place in the background. But anyway, I’m resolve at this point.

It’s funny how one can spend hours Googling and not find what you’re looking for and then come back another time and think your’re basically doing the same search routine but then find something… perhaps missed the first time.

Thank you

2 Likes

This topic was automatically closed 186 days after the last reply. New replies are no longer allowed.