aboutsummaryrefslogtreecommitdiffstats
path: root/cmd/geth/monitorcmd.go
diff options
context:
space:
mode:
authorPéter Szilágyi <peterke@gmail.com>2015-06-29 21:11:01 +0800
committerJeffrey Wilcke <geffobscura@gmail.com>2015-06-30 06:51:46 +0800
commit01fe97211354d13ecaba8a52c82b808b7a7e8393 (patch)
tree337e23800833c81e1d21f5850d4079c575e89ea7 /cmd/geth/monitorcmd.go
parentccbb56b4f2cdba352eaa859ce3e34f999287f5c0 (diff)
downloadgo-tangerine-01fe97211354d13ecaba8a52c82b808b7a7e8393.tar
go-tangerine-01fe97211354d13ecaba8a52c82b808b7a7e8393.tar.gz
go-tangerine-01fe97211354d13ecaba8a52c82b808b7a7e8393.tar.bz2
go-tangerine-01fe97211354d13ecaba8a52c82b808b7a7e8393.tar.lz
go-tangerine-01fe97211354d13ecaba8a52c82b808b7a7e8393.tar.xz
go-tangerine-01fe97211354d13ecaba8a52c82b808b7a7e8393.tar.zst
go-tangerine-01fe97211354d13ecaba8a52c82b808b7a7e8393.zip
cmd, core, eth, metrics, p2p: require enabling metrics
Diffstat (limited to 'cmd/geth/monitorcmd.go')
-rw-r--r--cmd/geth/monitorcmd.go7
1 files changed, 6 insertions, 1 deletions
diff --git a/cmd/geth/monitorcmd.go b/cmd/geth/monitorcmd.go
index 05965f009..6a7e1cbb4 100644
--- a/cmd/geth/monitorcmd.go
+++ b/cmd/geth/monitorcmd.go
@@ -75,7 +75,12 @@ func monitor(ctx *cli.Context) {
if len(monitored) == 0 {
list := expandMetrics(metrics, "")
sort.Strings(list)
- utils.Fatalf("No metrics specified.\n\nAvailable:\n - %s", strings.Join(list, "\n - "))
+
+ if len(list) > 0 {
+ utils.Fatalf("No metrics specified.\n\nAvailable:\n - %s", strings.Join(list, "\n - "))
+ } else {
+ utils.Fatalf("No metrics specified.\n\nNo metrics collected (--metrics)\n")
+ }
}
sort.Strings(monitored)
if cols := len(monitored) / ctx.Int(monitorCommandRowsFlag.Name); cols > 6 {