Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature parity with the node_exporter #6

Open
SuperQ opened this issue Jan 4, 2020 · 7 comments
Open

Feature parity with the node_exporter #6

SuperQ opened this issue Jan 4, 2020 · 7 comments
Labels
help wanted Extra attention is needed

Comments

@SuperQ
Copy link
Contributor

SuperQ commented Jan 4, 2020

It would be good for this exporter to reach feature parity with the node_exporter's systemd collector.

Once this issue is complete, we can remove systemd support from the node_exporter and link to this one.

@povilasv
Copy link
Contributor

povilasv commented Jan 6, 2020

Thanks for creating this issue. This definitely needs to be looked at

@povilasv povilasv added the help wanted Extra attention is needed label Jan 6, 2020
@povilasv
Copy link
Contributor

povilasv commented Apr 21, 2020

I've looked at it. Comparing v0.4.0 systemd vs prometheus/node_exporter@fa4edd7

We could potentially have feature parity in v0.5.0

I plan to add a README section on differences, so that people can easily migrate if they choose to do so.

From flags perspective:

Flags change from:

  • --collector.systemd.enable-restarts-metrics => --collector.enable-restart-count

and

  • --collector.systemd.private => --collector.private
  • --collector.systemd.unit-blacklist => --collector.unit-blacklist
  • --collector.systemd.unit-whitelist => collector.unit-whitelist

We don't have:

--collector.systemd.enable-start-time-metrics
--collector.systemd.enable-task-metrics

As these features are enabled by default, with no option to disable it.

From metrics perspective:

We have same exact metrics but different namespace (node_exporter has node_systemd_units, we have systemd_unit_info:

  • unit_state
  • unit_tasks_current
  • service_restart_total
  • timer_last_trigger_seconds
  • socket_accepted_connections_total
  • socket_current_connections
  • socket_refused_connections_total

Differences:

  • unit_start_time_seconds, we have additional type label
  • unit_tasks_max, we have additional type label

We don't have:

  • system_running - Whether the system is operational (see 'systemctl is-system-running').
  • systemd_units, example:
node_systemd_units{state="activating"} 1
node_systemd_units{state="active"} 221
node_systemd_units{state="deactivating"} 0
node_systemd_units{state="failed"} 0
node_systemd_units{state="inactive"} 67
  • node_systemd_version

Example:

node_systemd_version 244

We add:

  • unit_info
  • process_cpu_seconds_total
  • unit_cpu_seconds_total
  • process_open_fds
  • process_max_fds
  • process_virtual_memory_bytes
  • process_virtual_memory_max_bytes
  • process_resident_memory_bytes
  • service_ip_ingress_bytes
  • service_ip_egress_bytes
  • service_ip_ingress_packets_total
  • service_ip_egress_packets_total
  • prommod metrics.

@SuperQ
Copy link
Contributor Author

SuperQ commented Apr 21, 2020

Awesome, thanks for the update.

Can node_systemd_units be derived from other metrics? Maybe it's unnecessary to add if you can do something like count by (state) (systemd_unit_state)?

For system_running, the typical pattern for an exporter like this would be to expose a system_up metric. We do this in other exporters like mysql_up.

@SuperQ
Copy link
Contributor Author

SuperQ commented Apr 21, 2020

One minor naming convention thing I noticed in this. We like to put the "unit" at the end of the metric name for consistency/clarity.

  • unit_tasks_current -> unit_current_tasks
  • unit_tasks_max -> unit_max_tasks

Kinda like process_max_fds

@sichvoge
Copy link

@povilasv Has there been any progress on this ticket?

@povilasv
Copy link
Contributor

@sichvoge not really, busy with other stuff. Feel free to pick it up.

@sichvoge
Copy link

Thanks a lot @povilasv. Unfortunately, I am not an Engineer anymore and I watch this from a project point of view at the moment. :)

Anyways, thanks for all your hard work. Really appreciate it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

3 participants