Telegraf stopped working after update to 2.7
-
@spaceboy I also have issues with the latest update of 2.7 well actually pfsense plus 23.05.01 which is 2.7 ce.
I had mine running fine and then I had to do a reinstall. Doing that broke everything. I know that I had pfsense running version after version going up.
-
@spaceboy please open a redmine with your php output..
-
@vasquezmi said in Telegraf stopped working after update to 2.7:
I had mine running fine and then I had to do a reinstall. Doing that broke everything. I know that I had pfsense running version after version going up.
pfSense 2.7.0 CE and pfSense Plus 23.01 made a big jump with the PHP language package from version 7.x to 8.1. The PHP upstream developer team made many alterations to the way PHP behaves. Chief among those were that it stopped automatically fixing things invisibly using its "best guest" of what the programmer may have intended. This involved automatic conversions between strings and numbers. It also started enforcing some formerly optional rules about how arrays were defined and accessed. What were once warnings that were suppressed unless optionally enabled became hard-stop errors with 8.x of PHP.
PHP is what the entire web GUI on pfSense is written in. So, that meant a ton of pfSense PHP code had to be changed. Little tidbits are still showing up in the pfSense base that need fixing. The third-party packages have issues as well. Some have been fixed, but certainly not all. It depends on whether the package has a currently active maintainer or not. If the maintainer is not highly involved and staying on top of the PHP changes, then his package will have problems on the newest pfSense versions.
-
@michmoor done! cheers
-
hello - sorry to say that this issue still persists.
i logged the issue with redmine https://redmine.pfsense.org/issues/14861 and as far as i can see i was told it was not reproducible. in the meantime i have updated to 2.7.2 but nothing has changed. Telegraf does not work and i still get the telegraf errors as previously reported.
in the meantime the following has also happened:
- the hard disk in my router died and when i restored a backup that included my Telegraf config, i could at least see the option to access it in the menu and the status of the service (stopped, would not start). i still got the PHP errors
- if i remove the Telegraf plugin the errors stop, but on reinstalling the plugin, i'm back to not being able to access the Telegraf config.
- i'm also getting other errors with the Telegraf plugin installed. randomly HaProxy and Snort services stop and HaProxy doesnt start automatically on boot, but does manually.
I'm honestly at the point of a clean start to see if i can get Telgraf working, because I'm already at the limit of my own knowledge. or does this seem recoverable? cheers
-
I want to report that I'm having the same issue with 23.09.1 on the 7100-1U. It's happening on multiple devices, and I think it's related to gateway alarms, but I can't say for sure.
The only fix for me at the time is service watchdog package.
-
Let me add some details ... I have two firewalls, both CE 2.7.2 but they have different built dates.
vault
zotac
On vault, I cannot install telegraf, it throws the php error, line 132 during pkg install.
On zotac, I CAN install telegraf, configure it to ping 8.8.8.8 and 1.1.1.1, it writes to the database and I can see the dashboard in grafana. But ... if I change telegraf settings and add at the custom box at the bottom
[[inputs.ping]]
urls = ["8.8.8.8","1.1.1.1"]
count = 5telegraf blows up with the php error 132
The different built dates are confusing, why are there two of them?
Both firewalls run the watchdog service to monitor unbound and restart it.
-
@spaceboy I experienced the same issue. I researched several articles to solve it and finally managed to fix it. I have summarized the solution on my blog. If you haven't solved it yet, I hope this helps!
-
@Vulcan_ thank you for the detailed analysis.
The question remains, why different built dates? 2.7.2 stable should have a frozen repo. All of us who d/l pfsense CE 2.7.2 should have the same built date.
Second, your analysis is very clear, how come the Developer on redmine claims he cannot reproduce the issue?
-
@pavlos said in Telegraf stopped working after update to 2.7:
The question remains, why different built dates? 2.7.2 stable should have a frozen repo. All of us who d/l pfsense CE 2.7.2 should have the same built date.
Very interesting. I stumbled upon this post looking for something else. Well, my build date is different from your two:
2.7.2-RELEASE (amd64)
built on Wed Dec 6 15:10:00 EST 2023
FreeBSD 14.0-CURRENTI wonder what's up with that.