devopsprodigy / kubegraf

Grafana-plugin for k8s' monitoring
MIT License
407 stars 45 forks source link

DevOpsProdigy KubeGraf version 1.5.2 usage issues #74

Closed yuan-01 closed 5 months ago

yuan-01 commented 7 months ago

1706685349128 1706685391409

As shown in the figure, I added the HTTPS address of kubernetes using the "kubectl cluster info" command, and then configured CA Cert, Client Cert, and Client Key using the "cat~/. kube/configure" and "echo" characters "| base64- d". When I clicked on save and test, an error "Bad Request" was reported.

This is the log I checked (/var/log/grafana/grafana. log): logger=plugins.update.checker t=2024-01-31T15:00:30.391351411+08:00 level=info msg="Update check succeeded" duration=745.94176ms logger=data-proxy-log userId=1 orgId=1 uname=admin path=/api/datasources/proxy/uid/b7be65be-fc2e-4d21-bde9-07c33ed18abe/api/v1/namespaces remote_addr=10.10.10.10 referer=http://10.10.10.21:3000/connections/datasources/edit/b7be65be-fc2e-4d21-bde9-07c33ed18abe t=2024-01-31T15:00:39.297287394+08:00 level=info msg="Authentication to data source failed" body="{\"kind\":\"Status\",\"apiVersion\":\"v1\",\"metadata\":{},\"status\":\"Failure\",\"message\":\"Unauthorized\",\"reason\":\"Unauthorized\",\"code\":401}\n" statusCode=401 logger=context userId=1 orgId=1 uname=admin t=2024-01-31T15:00:39.297432122+08:00 level=info msg="Request Completed" method=GET path=/api/datasources/proxy/uid/b7be65be-fc2e-4d21-bde9-07c33ed18abe/api/v1/namespaces status=400 remote_addr=10.10.10.10 time_ms=10 duration=10.821865ms size=36 referer=http://10.10.10.21:3000/connections/datasources/edit/b7be65be-fc2e-4d21-bde9-07c33ed18abe handler=/api/datasources/proxy/uid/:uid/*.

I really don't know what to do.

yuan-01 commented 5 months ago

It has been resolved. address:https://blog.csdn.net/weixin_46627652/article/details/128904527?ops_request_misc=%257B%2522request%255Fid%2522%253A%2522171090149316800185830717%2522%252C%2522scm%2522%253A%252220140713.130102334.pc%255Fblog.%2522%257D&request_id=171090149316800185830717&biz_id=0&utm_medium=distribute.pc_search_result.none-task-blog-2~blog~first_rank_ecpm_v1~rank_v31_ecpm-1-128904527-null-null.nonecase&utm_term=prometheus&spm=1018.2226.3001.4450