Random error Email not sent

Hello, i have this issue for a while now (months), for any alert at any time, i will tell “random” since i cannot pinpoint the cause, i have an error and the mail for the alert isn’t sent. Curiously, the recovery mail is always sent. The error is flawed, since i can always reach the SMTP server

So regulary, i only have recovery mail for a device and the alert linked…

I decided to fully reinstall LNMS from scratch on another physical site with another independant SMTP server, and i discovered the same error… I don’t know if it’s linked, but i use two pollers with the master LNMS.

I searched for errors or logs in GUI and CLI, but no luck to find an interesting log.

I found a lots of posts with similar subjects, but never with a fix excepted “it’s now patched”. But i have the problem for about 4 monts now, and i just created a full new LNMS with the same problem, i don’t have the impression to have done any specific configuration..

Could someone help me on finding the source of the probleme so i could fix it ?

Thanks in advance for any advices !!

ERROR

|

2026-05-18 12:39:06 #0 /opt/librenms/LibreNMS/Alert/RunAlerts.php(665): LibreNMS\Alert\Transport\Mail->deliverAlert() #1 /opt/librenms/LibreNMS/Alert/RunAlerts.php(289): LibreNMS\Alert\RunAlerts->extTransports() #2 /opt/librenms/LibreNMS/Alert/RunAlerts.php(620): LibreNMS\Alert\RunAlerts->issueAlert() #3 /opt/librenms/alerts.php(61): LibreNMS\Alert\RunAlerts->runAlerts() #4 {main} Transport delivery failed with 0 for MAIL-Tech-Supervision: SMTP Error: Could not connect to SMTP host. Failed to connect to server
2026-05-18 12:39:06 Could not issue critical alert for rule ‘GENERAL_Sensor over limit - Check Device Health Settings’ to transport ‘mail’ Error: Transport delivery failed with 0 for MAIL-Tech-Supervision: SMTP Error: Could not connect to SMTP host. Failed to connect to server

EMAIL CONFIGURATION

./validate.php server 01

Component Version
LibreNMS 26.3.1 (2026-03-17T18:03:38+01:00)
DB Schema 2026_04_02_141445_add_ssl_certificate_update_permission (383)
PHP 8.3.29
Python 3.12.12
Database MariaDB 10.11.16-MariaDB-ubu2204
RRDTool 1.9.0
SNMP 5.9.4
===========================================

[OK] Installed from the official Docker image; no Composer required
[OK] Database Connected
[WARN] Your database schema has extra migrations (2025_07_07_130106_modify_transceiver_date_column, 2026_01_16_091417_add_ent_physical_mfg_date_to_ent_physical_table, 2026_03_13_120000_create_ssl_certificates_table, 2026_03_18_120000_alert_operations, 2026_03_25_120000_add_alert_operation_permissions, 2026_03_25_120000_add_ssl_certificate_permissions, 2026_03_27_000000_remove_state_draw_graph_from_state_translations_table, 2026_04_02_122359_expand_ssl_certificates_authority_key_identifier, 2026_04_02_141445_add_ssl_certificate_update_permission). 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] SQL Server meets minimum requirements
[OK] lower_case_table_names is enabled
[OK] MySQL engine is optimal
[OK] MySQL and PHP time match
[OK] Distributed Polling setting is enabled globally
[FAIL] You have not enabled rrdcached
[FIX]:
lnms config:set rrdcached
[OK] Active pollers found
[OK] Dispatcher Service is enabled
[OK] Locks are functional
[OK] No python wrapper pollers found
[OK] Redis is functional
[OK] rrd_dir is writable
[OK] rrdtool version ok
[WARN] Updates are managed through the official Docker image/opt/librenms $ ./validate.php

Component Version
LibreNMS 26.3.1 (2026-03-17T18:03:38+01:00)
DB Schema 2026_04_02_141445_add_ssl_certificate_update_permission (383)
PHP 8.3.29
Python 3.12.12
Database MariaDB 10.11.16-MariaDB-ubu2204
RRDTool 1.9.0
SNMP 5.9.4
===========================================

[OK] Installed from the official Docker image; no Composer required
[OK] Database Connected
[WARN] Your database schema has extra migrations (2025_07_07_130106_modify_transceiver_date_column, 2026_01_16_091417_add_ent_physical_mfg_date_to_ent_physical_table, 2026_03_13_120000_create_ssl_certificates_table, 2026_03_18_120000_alert_operations, 2026_03_25_120000_add_alert_operation_permissions, 2026_03_25_120000_add_ssl_certificate_permissions, 2026_03_27_000000_remove_state_draw_graph_from_state_translations_table, 2026_04_02_122359_expand_ssl_certificates_authority_key_identifier, 2026_04_02_141445_add_ssl_certificate_update_permission). 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] SQL Server meets minimum requirements
[OK] lower_case_table_names is enabled
[OK] MySQL engine is optimal
[OK] MySQL and PHP time match
[OK] Distributed Polling setting is enabled globally
[FAIL] You have not enabled rrdcached
[FIX]:
lnms config:set rrdcached
[OK] Active pollers found
[OK] Dispatcher Service is enabled
[OK] Locks are functional
[OK] No python wrapper pollers found
[OK] Redis is functional
[OK] rrd_dir is writable
[OK] rrdtool version ok
[WARN] Updates are managed through the official Docker image

./validate.php Server 02

===========================================

Component Version
LibreNMS 26.5.1-dev.95+ef0dab0c7 (2026-05-17T08:13:40+02:00)
DB Schema 2026_05_06_145721_regenerate_devices_table_display_field (387)
PHP 8.3.6
Python 3.12.3
Database MariaDB 10.11.14-MariaDB-0ubuntu0.24.04.1
RRDTool 1.7.2
SNMP 5.9.4.pre2
===========================================

[OK] Composer Version: 2.9.7
[OK] Dependencies up-to-date.
[OK] Database Connected
[OK] Database Schema is current
[OK] SQL Server meets minimum requirements
[OK] lower_case_table_names is enabled
[OK] MySQL engine is optimal
[OK] Database and column collations are correct
[OK] Database schema correct
[OK] MySQL and PHP time match
[OK] Distributed Polling setting is enabled globally
[OK] Connected to rrdcached
[OK] Active pollers found
[OK] Dispatcher Service not detected
[OK] Locks are functional
[OK] Python poller wrapper is polling
[OK] Redis is functional
[OK] rrdtool version ok
[OK] Connected to rrdcached

I mean your error is pretty self explanatory. LibreNMS can’t connect via smtp at the time it’s trying to send the email

I understand, but i tried with two differents SMTP servers, and when i conduct a surveillance of connections to the servers, it’s always available, and the LNMS are the only ones to have a pseudo problem of connection..

I would like to know how to investigate further, and understand why it says this, because it does not seem to be the real root causes of the problem