PI zero 1 - failed to connect to localhost, influx 1.8.10

Hi everyone and merry Christmas !

So i had a problem almost a year ago, related in this post.

Basically after a reboot influxdb fail to connect to localhost:

dietpi@DietPi:~$ influx
Failed to connect to http://localhost:8086: Get http://localhost:8086/ping: dial tcp [::1]:8086: connect: connection refused
Please check your connection settings and ensure ‘influxd’ is running.

Influxd is speaking about the 88 port:

2022-12-27T08:50:35.642386Z info InfluxDB starting {“log_id”: “0f0hGTGW000”, “version”: “1.8.10”, “branch”: “1.8”, “commit”: “688e697c51fd”}
2022-12-27T08:50:35.642828Z info Go runtime {“log_id”: “0f0hGTGW000”, “version”: “go1.13.8”, “maxprocs”: 1}
run: open server: listen: listen tcp 127.0.0.1:8088: bind: address already in use

I see in htop after the boot that influx keep trying to initiate https but it set to false in my conf file.

doing the trick :

sudo chmod +x /usr/lib/influxdb/scripts/influxd-systemd-start.sh

Serve no purpose. The database will work after 1/4 hour and I don’t know why it doesn’t work right after reboot. Someone have an idea ? The database’s weight is 377ko so I doubt its the probleme during initialisation with cron.

Merry christmas and new year from france !!

Hello,
I’m not shure if I got your problem, I also have a Pi Zero W with InfluxDB and Grafana. When InfluxDB is starting, it reads many files in the database before providing service to Grafana or to the command influx in a shell. It may take many minutes before beeing ready. I can do a stop/start or both together with restart of the DB and then check my syslog with:

sudo systemctl restart influxdb
tail -f /var/log/syslog

There I see many lines from influxd-systemd-start.sh with …msg=“Opened shard”…, …msg=“Opened file”…, …InfluxDB API unavailable after 16 attempts… and finally InfluxDB started
You can also check afterwards the syslog, when InfluxDB is finally running.
Be patient! If there are many databases, influx has to read files of all of them, and there is a large _internal database, if you didn’t disable this self monitoring, see InfluxDB and Raspberry Pi Zero W

Happy new year!

Thanks ! I’ll check that ! The pi is almost always working so I dont have this problem very often. But it’s true that I don’t really need the internal db but I thought it was used by influx itself

You can check what internal db is for by checking this grafana dashboard btw !

You were right internal_db can be disabled without a problem !

Thanks for the tip. I just tested it and it’s weird how quicker the database is ready when i stop and start the service. My database is larger than the internal one.