pt-stalk --no-stalk silently clobbers other options, acts magically
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Percona Toolkit moved to https://jira.percona.com/projects/PT |
Fix Released
|
Medium
|
Daniel Nichter |
Bug Description
pt-stalk exists "because no more iterations" incorrectly:
pi@raspberrypi ~ $ ./pt-stalk --version
pt-stalk 2.1.9
pi@raspberrypi ~ $ PTDEBUG=1 ./pt-stalk --collect --no-stalk --interval=1 --iterations=3600
2013_02_14_15_23_00 Starting ./pt-stalk --function=status --variable=
2013_02_14_15_23_00 Not running with root privileges!
2013_02_14_15_23_00 Not stalking; collect triggered immediately
2013_02_14_15_23_00 Collect 1 triggered
2013_02_14_15_23_00 Collect 1 PID 30319
2013_02_14_15_23_00 Collect 1 done
2013_02_14_15_23_01 Waiting up to 90 seconds for collectors to finish...
2013_02_14_15_24_33 Killing collector 30319
2013_02_14_15_24_33 Exiting because no more iterations
2013_02_14_15_24_33 ./pt-stalk exit status 0
Note that it's --iterations=3600 in my command, but --iterations=1 in what was invoked. I'm confused.
Related branches
- Daniel Nichter: Pending requested
-
Diff: 13 lines (+2/-1)1 file modifiedbin/pt-stalk (+2/-1)
- Daniel Nichter: Approve
-
Diff: 731 lines (+283/-161)5 files modifiedbin/pt-stalk (+208/-149)
lib/bash/collect.sh (+3/-11)
lib/bash/subshell.sh (+66/-0)
t/lib/bash/collect.sh (+1/-0)
t/pt-stalk/pt-stalk.t (+5/-1)
summary: |
- pt-stalk --no-stalk silently clobbers explicit --iterations + pt-stalk --no-stalk clobbers other options |
summary: |
- pt-stalk --no-stalk clobbers other options + pt-stalk --no-stalk silently clobbers other options, acts magically |
Changed in percona-toolkit: | |
status: | Triaged → Fix Committed |
Changed in percona-toolkit: | |
status: | Fix Committed → Fix Released |
I think --no-stalk is the reason: iirc, that option causes the tool to collect once (hence --iterations=1) and exit.