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

Add processes exporter #950

Merged
merged 3 commits into from
Jun 5, 2018
Merged

Conversation

pkutishch
Copy link
Contributor

Signed-off-by: Pavel Kutishchev pavel.kutishchev@olx.com

@SuperQ
Copy link
Member

SuperQ commented May 23, 2018

Test is failing with processes_linux_test.go:26: Cannot retrieve data from procfs getAllocatedThreads function: integer overflow on token 2573836288

@pkutishch
Copy link
Contributor Author

pkutishch commented May 23, 2018

Yes, i see this, trying to figure out why it fails

>> running tests
GO15VENDOREXPERIMENT=1 go test -short -race github.com/prometheus/node_exporter github.com/prometheus/node_exporter/collector
ok  	github.com/prometheus/node_exporter	(cached)
ok  	github.com/prometheus/node_exporter/collector	1.226s
>> running tests in 32-bit mode
ok  	github.com/prometheus/node_exporter	(cached)
ok  	github.com/prometheus/node_exporter/collector	0.117s
>> running end-to-end tests
./end-to-end-test.sh
root@12c9c9d715a9:/src/github.com/prometheus/node_exporter# go version
go version go1.10.2 linux/amd64

@SuperQ is that circle-ci issue? because i can see all stages build successfully on in this particular case it failed unit-tests on 32bit arch, but it there were a problem build would fail as well.

@SuperQ
Copy link
Member

SuperQ commented May 23, 2018

When I run the test locally, I get different values for the overflow on every run. It looks like you need to init the fixtures procPath.

Like in ipvs_linux_test.go

@SuperQ
Copy link
Member

SuperQ commented May 23, 2018

It looks like the path is wrong for the pid_max and threads-max fixtures files.

They need to go in collector/fixtures/proc/sys/kernel/

@pkutishch
Copy link
Contributor Author

@SuperQ thanks, i found this out 😄 has no committed yet, my mistake, got distracted and put it to wrong place

@SuperQ SuperQ changed the title Added processes exporter Add processes exporter May 23, 2018
@SuperQ
Copy link
Member

SuperQ commented May 23, 2018

Something is a little strange with the commits here. But the final diff looks OK. Not sure what is up with DCO not reporting.

@SuperQ
Copy link
Member

SuperQ commented May 23, 2018

@pkutishch, maybe if you give me access to your fork, I can poke around the git commit history?

@brian-brazil
Copy link
Contributor

The 3rd commit is a merge commit, and thus lacks the DCO. I'd suggest squashing.

Signed-off-by: Pavel Kutishchev <pavel.kutishchev@olx.com>
Signed-off-by: Ben Kochie <superq@gmail.com>
@SuperQ SuperQ force-pushed the process_exporter branch from 707860c to c90e688 Compare May 23, 2018 15:34
@SuperQ
Copy link
Member

SuperQ commented May 23, 2018

Ok, I squashed up the commits. Let's see if that makes the DCO bot happy.

SuperQ added 2 commits May 23, 2018 17:43
Signed-off-by: Ben Kochie <superq@gmail.com>
Signed-off-by: Ben Kochie <superq@gmail.com>
Copy link
Member

@SuperQ SuperQ left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@SuperQ
Copy link
Member

SuperQ commented May 23, 2018

@brian-brazil Even after rebase, the DCO bot seems stuck on this PR. And there's no debug link for it.

@SuperQ SuperQ requested a review from discordianfish May 23, 2018 19:14
@pkutishch
Copy link
Contributor Author

@SuperQ Thanks for your help!

@SuperQ
Copy link
Member

SuperQ commented Jun 4, 2018

Ping, @discordianfish, do you have any additional comments?

@discordianfish
Copy link
Member

LGTM, thanks!

@SuperQ SuperQ merged commit 456bf50 into prometheus:master Jun 5, 2018
@SuperQ SuperQ deleted the process_exporter branch June 5, 2018 17:38
@dswarbrick
Copy link
Contributor

I realise this has already been merged, and I welcome its inclusion, but doesn't it sort of make node_procs_running and node_procs_blocked redundant?

@SuperQ
Copy link
Member

SuperQ commented Oct 24, 2018

@dswarbrick Those come from /proc/stat, which is cheap and enabled by default. This collector is expensive and disabled by default. It's a tiny bit redundant, but not overly so.

oblitorum pushed a commit to shatteredsilicon/node_exporter that referenced this pull request Apr 9, 2024
* Add processes exporter

Signed-off-by: Pavel Kutishchev <pavel.kutishchev@olx.com>
Signed-off-by: Ben Kochie <superq@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants