systemctl status nagflux.service[/b]
● nagflux.service - A connector which transforms performancedata from Nagios/Icinga(2)/Naemon to InfluxDB/Elasticsearch
Loaded: loaded (/usr/lib/systemd/system/nagflux.service; enabled; vendor preset: disabled)
Active: active (running) since Fri 2020-01-31 04:10:26 UTC; 12h ago
Docs: https://github.com/Griesbacher/nagflux
Main PID: 28895 (nagflux)
CGroup: /system.slice/nagflux.service
└─28895 /opt/nagflux/nagflux -configPath /opt/nagflux/config.gcfg
Jan 31 17:05:59 ip-172-31-0-145.ap-south-1.compute.internal nagflux[28895]: 2020-01-31 17:05:59 Critical: Connection type is unknown, options are: tcp, file. Input:
Jan 31 17:06:28 ip-172-31-0-145.ap-south-1.compute.internal nagflux[28895]: 2020-01-31 17:06:28 Critical: Connection type is unknown, options are: tcp, file. Input:
Jan 31 17:06:28 ip-172-31-0-145.ap-south-1.compute.internal nagflux[28895]: 2020-01-31 17:06:28 Critical: Connection type is unknown, options are: tcp, file. Input:
Jan 31 17:06:28 ip-172-31-0-145.ap-south-1.compute.internal nagflux[28895]: 2020-01-31 17:06:28 Critical: Connection type is unknown, options are: tcp, file. Input:
Jan 31 17:06:29 ip-172-31-0-145.ap-south-1.compute.internal nagflux[28895]: 2020-01-31 17:06:29 Critical: Connection type is unknown, options are: tcp, file. Input:
Jan 31 17:06:29 ip-172-31-0-145.ap-south-1.compute.internal nagflux[28895]: 2020-01-31 17:06:29 Critical: Connection type is unknown, options are: tcp, file. Input:
Jan 31 17:06:29 ip-172-31-0-145.ap-south-1.compute.internal nagflux[28895]: 2020-01-31 17:06:29 Critical: Connection type is unknown, options are: tcp, file. Input:
Jan 31 17:06:59 ip-172-31-0-145.ap-south-1.compute.internal nagflux[28895]: 2020-01-31 17:06:59 Critical: Connection type is unknown, options are: tcp, file. Input:
Jan 31 17:06:59 ip-172-31-0-145.ap-south-1.compute.internal nagflux[28895]: 2020-01-31 17:06:59 Critical: Connection type is unknown, options are: tcp, file. Input:
Jan 31 17:06:59 ip-172-31-0-145.ap-south-1.compute.internal nagflux[28895]: 2020-01-31 17:06:59 Critical: Connection type is unknown, options are: tcp, file. Input :
cat /opt/nagflux/config.gcfg
[main]
NagiosSpoolfileFolder = "/usr/local/nagios/var/spool/nagfluxperfdata"
NagiosSpoolfileWorker = 1
InfluxWorker = 2
MaxInfluxWorker = 5
DumpFile = "nagflux.dump"
NagfluxSpoolfileFolder = "/usr/local/nagios/var/nagflux"
FieldSeparator = "&"
BufferSize = 10000
FileBufferSize = 65536
DefaultTarget = "all"
[Log]
LogFile = ""
MinSeverity = "INFO"
[Livestatus]
# # tcp or file
Type = "file"
# # tcp: 127.0.0.1:6557 or file /var/run/live
file /usr/local/nagios/var/live.sock
# #Address = "127.0.0.1:6557"
# # The amount to minutes to wait for livestatus to come up, if set to 0 the detection is disabled
MinutesToWait = 2
# # Set the Version of Livestatus. Allowed are Nagios, Icinga2, Naemon.
# # If left empty Nagflux will try to detect it on it's own, which will not always work.
Version = ""
[InfluxDBGlobal]
CreateDatabaseIfNotExists = true
NastyString = ""
NastyStringToReplace = ""
HostcheckAlias = "hostcheck"
[InfluxDB "nagflux"]
Enabled = true
Version = 1.0
Address = "http://127.0.0.1:8086"
Arguments = "precision=ms&u=root&p=root&db=nagflux"
StopPullingDataIfDown = true
[InfluxDB "fast"]
Enabled = false
Version = 1.0
Address = "http://127.0.0.1:8086"
Arguments = "precision=ms&u=root&p=root&db=fast"
StopPullingDataIfDown = false
Livestatus live socker file is /usr/local/nagios/var/live.sock
srw-rw----. 1 nagios nagios 0 Jan 29 07:20 /usr/local/nagios/var/live.sock
I have enabled the below in /opt/nagflux/config.gcfg. nagflux service does not start at all.
CODE: SELECT ALL
[Livestatus]
# # tcp or file
Type = "file"
# # tcp: 127.0.0.1:6557 or file /var/run/live
file /usr/local/nagios/var/live.sock
# #Address = "127.0.0.1:6557"
# # The amount to minutes to wait for livestatus to come up, if set to 0 the detection is disabled
MinutesToWait = 2
# # Set the Version of Livestatus. Allowed are Nagios, Icinga2, Naemon.
# # If left empty Nagflux will try to detect it on it's own, which will not always work.
Version = ""
● nagflux.service - A connector which transforms performancedata from Nagios/Icinga(2)/Naemon to InfluxDB/Elasticsearch
Loaded: loaded (/usr/lib/systemd/system/nagflux.service; enabled; vendor preset: disabled)
Active: failed (Result: start-limit) since Fri 2020-01-31 17:10:48 UTC; 3s ago
Docs: https://github.com/Griesbacher/nagflux
Process: 10845 ExecStart=/opt/nagflux/nagflux -configPath /opt/nagflux/config.gcfg (code=exited, status=2)
Main PID: 10845 (code=exited, status=2)
Jan 31 17:10:48 ip-172-31-0-145.ap-south-1.compute.internal nagflux[10845]: main.main()
Jan 31 17:10:48 ip-172-31-0-145.ap-south-1.compute.internal nagflux[10845]: /root/gorepo/src/github.com/griesbacher/nagflux/main.go:68 +0x22e
Jan 31 17:10:48 ip-172-31-0-145.ap-south-1.compute.internal systemd[1]: Unit nagflux.service entered failed state.
Jan 31 17:10:48 ip-172-31-0-145.ap-south-1.compute.internal systemd[1]: nagflux.service failed.
Jan 31 17:10:48 ip-172-31-0-145.ap-south-1.compute.internal systemd[1]: nagflux.service holdoff time over, scheduling restart.
Jan 31 17:10:48 ip-172-31-0-145.ap-south-1.compute.internal systemd[1]: Stopped A connector which transforms performancedata from Nagios/Icinga(2)/Naemon to InfluxDB/Elasticsearch.
Jan 31 17:10:48 ip-172-31-0-145.ap-south-1.compute.internal systemd[1]: start request repeated too quickly for nagflux.service
Jan 31 17:10:48 ip-172-31-0-145.ap-south-1.compute.internal systemd[1]: Failed to start A connector which transforms performancedata from Nagios/Icinga(2)/Naemon to InfluxDB/Elasticsearch.
Jan 31 17:10:48 ip-172-31-0-145.ap-south-1.compute.internal systemd[1]: Unit nagflux.service entered failed state.
Jan 31 17:10:48 ip-172-31-0-145.ap-south-1.compute.internal systemd[1]: nagflux.service failed.
cat /var/log/nagflux.log
Feb 1 03:52:06 ip-172-31-0-145 nagflux: panic: invalid variable: section "Livestatus" subsection "" variable "File"
Feb 1 03:52:06 ip-172-31-0-145 nagflux: goroutine 1 [running]:
Feb 1 03:52:06 ip-172-31-0-145 nagflux: github.com/griesbacher/nagflux/config.InitConfig(0x7ffc00839f52, 0x18)
Feb 1 03:52:06 ip-172-31-0-145 nagflux: /root/gorepo/src/github.com/griesbacher/nagflux/config/ConfigProvider.go:18 +0xe7
Feb 1 03:52:06 ip-172-31-0-145 nagflux: main.main()
Feb 1 03:52:06 ip-172-31-0-145 nagflux: /root/gorepo/src/github.com/griesbacher/nagflux/main.go:68 +0x22e
Feb 1 03:52:06 ip-172-31-0-145 nagflux: panic: invalid variable: section "Livestatus" subsection "" variable "File"
Feb 1 03:52:06 ip-172-31-0-145 nagflux: goroutine 1 [running]:
Feb 1 03:52:06 ip-172-31-0-145 nagflux: github.com/griesbacher/nagflux/config.InitConfig(0x7ffe6cf9ef52, 0x18)
Feb 1 03:52:06 ip-172-31-0-145 nagflux: /root/gorepo/src/github.com/griesbacher/nagflux/config/ConfigProvider.go:18 +0xe7
Feb 1 03:52:06 ip-172-31-0-145 nagflux: main.main()
Feb 1 03:52:06 ip-172-31-0-145 nagflux: /root/gorepo/src/github.com/griesbacher/nagflux/main.go:68 +0x22e
Feb 1 03:52:07 ip-172-31-0-145 nagflux: panic: invalid variable: section "Livestatus" subsection "" variable "File"
Feb 1 03:52:07 ip-172-31-0-145 nagflux: goroutine 1 [running]:
Feb 1 03:52:07 ip-172-31-0-145 nagflux: github.com/griesbacher/nagflux/config.InitConfig(0x7ffc5468bf52, 0x18)
Feb 1 03:52:07 ip-172-31-0-145 nagflux: /root/gorepo/src/github.com/griesbacher/nagflux/config/ConfigProvider.go:18 +0xe7
Feb 1 03:52:07 ip-172-31-0-145 nagflux: main.main()
Feb 1 03:52:07 ip-172-31-0-145 nagflux: /root/gorepo/src/github.com/griesbacher/nagflux/main.go:68 +0x22e
Feb 1 03:52:07 ip-172-31-0-145 nagflux: panic: invalid variable: section "Livestatus" subsection "" variable "File"
Feb 1 03:52:07 ip-172-31-0-145 nagflux: goroutine 1 [running]:
Feb 1 03:52:07 ip-172-31-0-145 nagflux: github.com/griesbacher/nagflux/config.InitConfig(0x7fff1dc6bf52, 0x18)
Feb 1 03:52:07 ip-172-31-0-145 nagflux: /root/gorepo/src/github.com/griesbacher/nagflux/config/ConfigProvider.go:18 +0xe7
Feb 1 03:52:07 ip-172-31-0-145 nagflux: main.main()
Feb 1 03:52:07 ip-172-31-0-145 nagflux: /root/gorepo/src/github.com/griesbacher/nagflux/main.go:68 +0x22e
Feb 1 03:52:07 ip-172-31-0-145 nagflux: panic: invalid variable: section "Livestatus" subsection "" variable "File"
Feb 1 03:52:07 ip-172-31-0-145 nagflux: goroutine 1 [running]:
Feb 1 03:52:07 ip-172-31-0-145 nagflux: github.com/griesbacher/nagflux/config.InitConfig(0x7ffcd9ae2f52, 0x18)
Feb 1 03:52:07 ip-172-31-0-145 nagflux: /root/gorepo/src/github.com/griesbacher/nagflux/config/ConfigProvider.go:18 +0xe7
Feb 1 03:52:07 ip-172-31-0-145 nagflux: main.main()
Feb 1 03:52:07 ip-172-31-0-145 nagflux: /root/gorepo/src/github.com/griesbacher/nagflux/main.go:68 +0x22e
Feb 1 04:03:02 ip-172-31-0-145 nagflux: panic: invalid variable: section "Livestatus" subsection "" variable "File"
Feb 1 04:03:02 ip-172-31-0-145 nagflux: goroutine 1 [running]:
Feb 1 04:03:02 ip-172-31-0-145 nagflux: github.com/griesbacher/nagflux/config.InitConfig(0x7fff886e0f52, 0x18)
Feb 1 04:03:02 ip-172-31-0-145 nagflux: /root/gorepo/src/github.com/griesbacher/nagflux/config/ConfigProvider.go:18 +0xe7
Feb 1 04:03:02 ip-172-31-0-145 nagflux: main.main()
Feb 1 04:03:02 ip-172-31-0-145 nagflux: /root/gorepo/src/github.com/griesbacher/nagflux/main.go:68 +0x22e
Feb 1 04:03:02 ip-172-31-0-145 nagflux: panic: invalid variable: section "Livestatus" subsection "" variable "File"
Feb 1 04:03:02 ip-172-31-0-145 nagflux: goroutine 1 [running]:
Feb 1 04:03:02 ip-172-31-0-145 nagflux: github.com/griesbacher/nagflux/config.InitConfig(0x7ffc12375f52, 0x18)
Feb 1 04:03:02 ip-172-31-0-145 nagflux: /root/gorepo/src/github.com/griesbacher/nagflux/config/ConfigProvider.go:18 +0xe7
Feb 1 04:03:02 ip-172-31-0-145 nagflux: main.main()
Feb 1 04:03:02 ip-172-31-0-145 nagflux: /root/gorepo/src/github.com/griesbacher/nagflux/main.go:68 +0x22e
Feb 1 04:03:02 ip-172-31-0-145 nagflux: panic: invalid variable: section "Livestatus" subsection "" variable "File"
Feb 1 04:03:02 ip-172-31-0-145 nagflux: goroutine 1 [running]:
Feb 1 04:03:02 ip-172-31-0-145 nagflux: github.com/griesbacher/nagflux/config.InitConfig(0x7ffe67c3af52, 0x18)
Feb 1 04:03:02 ip-172-31-0-145 nagflux: /root/gorepo/src/github.com/griesbacher/nagflux/config/ConfigProvider.go:18 +0xe7
Feb 1 04:03:02 ip-172-31-0-145 nagflux: main.main()
Feb 1 04:03:02 ip-172-31-0-145 nagflux: /root/gorepo/src/github.com/griesbacher/nagflux/main.go:68 +0x22e
Feb 1 04:03:03 ip-172-31-0-145 nagflux: panic: invalid variable: section "Livestatus" subsection "" variable "File"
Feb 1 04:03:03 ip-172-31-0-145 nagflux: goroutine 1 [running]:
Feb 1 04:03:03 ip-172-31-0-145 nagflux: github.com/griesbacher/nagflux/config.InitConfig(0x7ffea93acf52, 0x18)
Feb 1 04:03:03 ip-172-31-0-145 nagflux: /root/gorepo/src/github.com/griesbacher/nagflux/config/ConfigProvider.go:18 +0xe7
Feb 1 04:03:03 ip-172-31-0-145 nagflux: main.main()
Feb 1 04:03:03 ip-172-31-0-145 nagflux: /root/gorepo/src/github.com/griesbacher/nagflux/main.go:68 +0x22e
Feb 1 04:03:03 ip-172-31-0-145 nagflux: panic: invalid variable: section "Livestatus" subsection "" variable "File"
Feb 1 04:03:03 ip-172-31-0-145 nagflux: goroutine 1 [running]:
Feb 1 04:03:03 ip-172-31-0-145 nagflux: github.com/griesbacher/nagflux/config.InitConfig(0x7fff36b98f52, 0x18)
Feb 1 04:03:03 ip-172-31-0-145 nagflux: /root/gorepo/src/github.com/griesbacher/nagflux/config/ConfigProvider.go:18 +0xe7
Feb 1 04:03:03 ip-172-31-0-145 nagflux: main.main()
Feb 1 04:03:03 ip-172-31-0-145 nagflux: /root/gorepo/src/github.com/griesbacher/nagflux/main.go:68 +0x22e
Hi
I am facing the below mentioned issue.
Livestatus live socker file is /usr/local/nagios/var/live.sock srw-rw----. 1 nagios nagios 0 Jan 29 07:20 /usr/local/nagios/var/live.sock
I have enabled the below in /opt/nagflux/config.gcfg. nagflux service does not start at all.
Thanks in Advance.
Best Regards,
Kaushal