[TASK] add nproc to database (#129)

This commit is contained in:
Martin/Geno 2018-02-25 17:59:28 +01:00 committed by Geno
parent 50e4dbb75a
commit c18b24cf6c
2 changed files with 2 additions and 0 deletions

View File

@ -92,6 +92,7 @@ func (c *Connection) InsertNode(node *runtime.Node) {
}
addField("load", stats.LoadAverage)
addField("nproc", nodeinfo.Hardware.Nproc)
addField("time.up", int64(stats.Uptime))
addField("time.idle", int64(stats.Idletime))
addField("proc.running", stats.Processes.Running)

View File

@ -61,6 +61,7 @@ func (conn *Connection) InsertNode(node *runtime.Node) {
}
// Hardware
tags.SetString("model", nodeinfo.Hardware.Model)
fields["nproc"] = nodeinfo.Hardware.Nproc
tags.SetString("firmware_base", nodeinfo.Software.Firmware.Base)
tags.SetString("firmware_release", nodeinfo.Software.Firmware.Release)
if nodeinfo.Software.Autoupdater.Enabled {