Pironman V2 auto-start at boot not working

Summary of complete solution to “Missing Dashboard” and “InfluxDB High I/O” problem:

Complete all of the numbered [1.], [2.], [3.] steps.

[1.] Pironman5 service re-installation Instructions:

sudo git clone -b max  https://github.com/sunfounder/pironman5.git` --depth 1 
cd /pironman5 
sudo python3 install.py`

[2.] Published work-around to dashboard missing.

Thank you to original forum solution at this link: https://forum.sunfounder.com/t/pironman-5-dashboard-empty/1218/51

sudo service pironman5 stop
rm -rf /var/lib/influxdb/data/pironman5
rm -rf /var/lib/influxdb/wal/pironman5
influx
> USE pironman5;
> CREATE RETENTION POLICY "7d" ON "pironman5" DURATION 7d REPLICATION 1 DEFAULT;
> exit
sudo nano /opt/pironman5/venv/lib/python3.*/site-packages/pironman5/config.json
--> edit file to change "data_interval": value from 1 to 5 or 10
--> Ctrl-X to save change
cat /opt/pironman5/venv/lib/python3.*/site-packages/pironman5/config.json
sudo systemctl restart influxdb
sudo systemctl restart pironman5
sudo pironman5 -c

Recommended Values:
data_interval = 1: Default (writes to InfluxDB every second) - High resource usage
data_interval = 5: Good balance - reduces writes by 80%
data_interval = 10: Recommended for resource savings - reduces writes by 90%
data_interval = 60: Minimal resource usage - only writes once per minute

[3.] Work-around to move the InfluxDB meta, data, and wal directories off the rootfs.

The default Pironman InfluxDB database is located in rootfs /var/lib/influxdb on the 32GB micro SD flash drive. Since I do not want to hammer this flash drive with constant writes (and thus increase the wear rate and reduce its useful life), it is important to redirect the DB writes to another disk. (It isn’t like this monitoring history is critical, but the life of the micro SD flash drive is!) The procedure below updates the influxdb.conf to change the default location for the meta, data, and wal folders. Most of the commands must be run from elevated sudo (root). Your data disk UUID will vary, and of course, you can use a different name for your folders. The shell commands below are unique to my Raspberry Pi 5.


 blkid
	/dev/nvme0n1p1: UUID="8d7f318f-4fa6-4621-b0e6-5203134f3b22" BLOCK_SIZE="4096" TYPE="ext4" PARTUUID="775b5f67-1175-4004-a04e-7c4558df4fe7"
	/dev/mmcblk0p1: LABEL_FATBOOT="bootfs" LABEL="bootfs" UUID="EACA-13DA" BLOCK_SIZE="512" TYPE="vfat" PARTUUID="b74c16a4-01"
	/dev/mmcblk0p2: LABEL="rootfs" UUID="21724cc6-e5a3-48a1-8643-7917dba3a9fb" BLOCK_SIZE="4096" TYPE="ext4" PARTUUID="b74c16a4-02"
	/dev/sda1: UUID="2602bb14-2801-4226-b3eb-817478e4022d" BLOCK_SIZE="4096" TYPE="ext4" PARTUUID="8ff4e689-e105-404e-b939-ef28a61427c3"
	/dev/loop0: TYPE="swap"
	/dev/zram0: LABEL="zram0" UUID="48438c5f-e25c-4805-a901-cb84331b2984" TYPE="swap"

 cat /etc/fstab
	proc            /proc           proc    defaults          0       0
	PARTUUID=b74c16a4-01  /boot/firmware  vfat    defaults          0       2
	PARTUUID=b74c16a4-02            /       ext4    noatime,nodiratime,defaults     0 1
	# >>> [openmediavault]
	/dev/disk/by-uuid/8d7f318f-4fa6-4621-b0e6-5203134f3b22          /srv/dev-disk-by-uuid-8d7f318f-4fa6-4621-b0e6-5203134f3b22      ext4    defaults,nofail,user_xattr,usrquota,grpquota,acl        0 2
	/dev/disk/by-uuid/2602bb14-2801-4226-b3eb-817478e4022d          /srv/dev-disk-by-uuid-2602bb14-2801-4226-b3eb-817478e4022d      ext4    defaults,nofail,user_xattr,usrquota,grpquota,acl        0 2
	# <<< [openmediavault]

 cat /etc/influxdb/influxdb.conf
	### Welcome to the InfluxDB configuration file.
	#
	...
	[meta]
	# Where the metadata/raft database is stored
	dir = "/var/lib/influxdb/meta"
	...
	[data]
	# The directory where the TSM storage engine stores TSM files.
	dir = "/var/lib/influxdb/data"
	# The directory where the TSM storage engine stores WAL files.
	wal-dir = "/var/lib/influxdb/wal"
	...

 ls -ld /var/lib/influxdb/meta
	drwxr-xr-x 2 influxdb influxdb 4096 Feb 21 17:35 meta
 ls -ld /var/lib/influxdb/data
	drwxr-xr-x 4 influxdb influxdb 4096 Feb 18 15:15 data
 ls -ld /var/lib/influxdb/wal
	drwx------ 4 influxdb influxdb 4096 Feb 18 15:15 wal

 cd /srv/dev-disk-by-uuid-8d7f318f-4fa6-4621-b0e6-5203134f3b22
 mkdir pironman
 cd pironman
 mkdir influxdb
 cd influxdb
 mkdir meta
 mkdir data
 mkdir wal

 chown influxdb:influxdb /srv/dev-disk-by-uuid-8d7f318f-4fa6-4621-b0e6-5203134f3b22/pironman/influxdb
 chown influxdb:influxdb /srv/dev-disk-by-uuid-8d7f318f-4fa6-4621-b0e6-5203134f3b22/pironman/influxdb/meta
 chown influxdb:influxdb /srv/dev-disk-by-uuid-8d7f318f-4fa6-4621-b0e6-5203134f3b22/pironman/influxdb/data
 chown influxdb:influxdb /srv/dev-disk-by-uuid-8d7f318f-4fa6-4621-b0e6-5203134f3b22/pironman/influxdb/wal

 ls -ld influxdb
	drwxr-xr-x 5 influxdb influxdb 4096 Feb 21 18:24 influxdb
 ls -ld influxdb/meta
	drwxr-xr-x 2 influxdb influxdb 4096 Feb 21 18:23 influxdb/meta
 ls -ld influxdb/data
	drwxr-xr-x 2 influxdb influxdb 4096 Feb 21 18:24 influxdb/data
 ls -ld influxdb/wal
	drwxr-xr-x 2 influxdb influxdb 4096 Feb 21 18:24 influxdb/wal
	
 cd /etc/influxdb
 nano influxdb.conf
 cat influxdb.conf
	...
	[meta]
	# dir = "/var/lib/influxdb/meta" (DEFAULT VALUE)
	dir = "/srv/dev-disk-by-uuid-8d7f318f-4fa6-4621-b0e6-5203134f3b22/pironman/influxdb/meta"
	...
	[data]
	# dir = "/var/lib/influxdb/data" (DEFAULT VALUE)
	dir = "/srv/dev-disk-by-uuid-8d7f318f-4fa6-4621-b0e6-5203134f3b22/pironman/influxdb/data"
	# wal-dir = "/var/lib/influxdb/wal" (DEFAULT VALUE)
	wal-dir = "/srv/dev-disk-by-uuid-8d7f318f-4fa6-4621-b0e6-5203134f3b22/pironman/influxdb/wal"
	...