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 in progress operation metrics #1

Open
flaviostutz opened this issue Sep 14, 2020 · 1 comment
Open

Add in progress operation metrics #1

flaviostutz opened this issue Sep 14, 2020 · 1 comment

Comments

@flaviostutz
Copy link
Contributor

db.currentOp().inprog.length

SHOW LONG RUNNING

db.currentOp().inprog.forEach(
function(op) {
if(op.secs_running > 5) printjson(op);
}
)

SHOW CURRENT LOCKS

db.currentOp(
{
$and: [
{"waitingForLock" : true},
{"ns" : "edidatico.testes-estudantes"}
]
}
)

db.currentOp(
{
$and: [
{"waitingForLock" : true},
{"ns" : "edidatico.testes-cadastro"}
]
}
)

@tregubov-av
Copy link

I agree, very useful functionality.
I made an implementation in percona mongodb_exporter
Might be useful for you
issues: percona/mongodb_exporter#704
PR: percona/mongodb_exporter#706

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

No branches or pull requests

2 participants