Details
-
Improvement
-
Status: Closed
-
Minor
-
Resolution: Fixed
-
None
Description
While collecting logs with invalid -operator-image-name argument, we should get valid warnings for deployment log collection failure.
And while using invalid -operartor-rest-port argument, we are getting deployment logs without extended debug info files with multiple port-forwarding errors. We should log readable errors here and user must be notified for not collecting the extended debug files from operator.
couchbase-operator]$ ./build/bin/cbopinfo --version
|
cbopinfo version 1.1.0 (master 0b42a37d3d3628c7c506d18fc2dc48a5e342ddda)
|
Console prints while using invalid image name,
couchbase-operator]$ ./build/bin/cbopinfo -namespace ashwin -operator-image couchbase/couchbase-operator-internal:invalid -operator-rest-port 8080 -namespace ashwin
|
no CouchbaseCluster resources discovered in name space ashwin
|
Wrote cluster information to cbopinfo-20181008T121006+0530.tar.gz
|
Console prints while using invalid operator port value,
couchbase-operator]$ ./build/bin/cbopinfo -namespace ashwin -operator-image couchbase/couchbase-operator:v1 -operator-rest-port 8081 -namespace ashwin
|
no CouchbaseCluster resources discovered in name space ashwin
|
E1008 12:12:50.028442 29274 portforward.go:331] an error occurred forwarding 8081 -> 8081: error forwarding port 8081 to pod a028564aa49eeb05ec31dd06b1b45f1f5fed23a76f8e19d645ce308f8eb37b9e, uid : exit status 1: 2018/10/08 06:42:49 socat[29313] E connect(5, AF=2 127.0.0.1:8081, 16): Connection refused
|
unable to collect http://localhost:8081//debug/pprof/block?debug=1 for pod couchbase-operator-6cc895594f-whzwt
|
E1008 12:12:50.036189 29274 portforward.go:331] an error occurred forwarding 8081 -> 8081: error forwarding port 8081 to pod a028564aa49eeb05ec31dd06b1b45f1f5fed23a76f8e19d645ce308f8eb37b9e, uid : exit status 1: 2018/10/08 06:42:49 socat[29314] E connect(5, AF=2 127.0.0.1:8081, 16): Connection refused
|
unable to collect http://localhost:8081//debug/pprof/goroutine?debug=1 for pod couchbase-operator-6cc895594f-whzwt
|
E1008 12:12:50.041954 29274 portforward.go:331] an error occurred forwarding 8081 -> 8081: error forwarding port 8081 to pod a028564aa49eeb05ec31dd06b1b45f1f5fed23a76f8e19d645ce308f8eb37b9e, uid : exit status 1: 2018/10/08 06:42:49 socat[29315] E connect(5, AF=2 127.0.0.1:8081, 16): Connection refused
|
unable to collect http://localhost:8081//debug/pprof/heap?debug=1 for pod couchbase-operator-6cc895594f-whzwt
|
E1008 12:12:50.048694 29274 portforward.go:331] an error occurred forwarding 8081 -> 8081: error forwarding port 8081 to pod a028564aa49eeb05ec31dd06b1b45f1f5fed23a76f8e19d645ce308f8eb37b9e, uid : exit status 1: 2018/10/08 06:42:49 socat[29316] E connect(5, AF=2 127.0.0.1:8081, 16): Connection refused
|
unable to collect http://localhost:8081//debug/pprof/mutex?debug=1 for pod couchbase-operator-6cc895594f-whzwt
|
E1008 12:12:50.054299 29274 portforward.go:331] an error occurred forwarding 8081 -> 8081: error forwarding port 8081 to pod a028564aa49eeb05ec31dd06b1b45f1f5fed23a76f8e19d645ce308f8eb37b9e, uid : exit status 1: 2018/10/08 06:42:49 socat[29317] E connect(5, AF=2 127.0.0.1:8081, 16): Connection refused
|
unable to collect http://localhost:8081//debug/pprof/threadcreate?debug=1 for pod couchbase-operator-6cc895594f-whzwt
|
E1008 12:12:50.060181 29274 portforward.go:331] an error occurred forwarding 8081 -> 8081: error forwarding port 8081 to pod a028564aa49eeb05ec31dd06b1b45f1f5fed23a76f8e19d645ce308f8eb37b9e, uid : exit status 1: 2018/10/08 06:42:49 socat[29318] E connect(5, AF=2 127.0.0.1:8081, 16): Connection refused
|
unable to collect http://localhost:8081//v1/stats/cluster for pod couchbase-operator-6cc895594f-whzwt
|
Wrote cluster information to cbopinfo-20181008T121249+0530.tar.gz
|
Attachments
For Gerrit Dashboard: K8S-620 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
102211,3 | K8S-620: Warn In No Operator in cbopinfo | master | couchbase-operator | Status: MERGED | +2 | +1 |
102311,2 | K8S-620: Shut Portforwarder Up | master | couchbase-operator | Status: MERGED | +2 | +1 |
I think more generally, if cbopinfo does not collect ANY operator images (there should be at least one in every circumstance), we should log a warning.
I've seen issues out in the field where the operator is not getting picked up due to a change in naming scheme and other than inspecting the contents there is no way to know that.
Would be nice to get it into 1.1 if possible given it'd just be an extra log line if there's no operator image found.