frezes 谢谢,解决了,但是安装到最后阶段 monitoring 出错了,
Waiting for all tasks to be completed ...
task openpitrix status is successful (1/4)
task network status is successful (2/4)
task multicluster status is successful (3/4)
task monitoring status is failed (4/4)
**************************************************
Collecting installation results ...
Task 'monitoring' failed:
******************************************************************************************************
{
"counter": 117,
"created": "2023-02-03T13:49:24.655686",
"end_line": 112,
"event": "runner_on_failed",
"event_data": {
"duration": 53.624667,
"end": "2023-02-03T13:49:24.655533",
"event_loop": null,
"host": "localhost",
"ignore_errors": null,
"play": "localhost",
"play_pattern": "localhost",
"play_uuid": "8219b820-73af-ffef-3dd1-000000000005",
"playbook": "/kubesphere/playbooks/monitoring.yaml",
"playbook_uuid": "d6a39677-0904-4bfa-aa9a-c2301c5131ac",
"remote_addr": "127.0.0.1",
"res": {
"changed": true,
"msg": "All items completed",
"results": [
{
"_ansible_item_label": "prometheus",
"_ansible_no_log": false,
"ansible_loop_var": "item",
"attempts": 5,
"changed": true,
"cmd": "/usr/local/bin/kubectl apply -f /kubesphere/kubesphere/prometheus/prometheus",
"delta": "0:00:00.963054",
"end": "2023-02-03 21:49:00.006501",
"failed": true,
"failed_when_result": true,
"invocation": {
"module_args": {
"_raw_params": "/usr/local/bin/kubectl apply -f /kubesphere/kubesphere/prometheus/prometheus",
"_uses_shell": true,
"argv": null,
"chdir": null,
"creates": null,
"executable": null,
"removes": null,
"stdin": null,
"stdin_add_newline": true,
"strip_empty_ends": true,
"warn": true
}
},
"item": "prometheus",
"msg": "non-zero return code",
"rc": 1,
"start": "2023-02-03 21:48:59.043447",
"stderr": "error: unable to recognize \\"/kubesphere/kubesphere/prometheus/prometheus/prometheus-podDisruptionBudget.yaml\\": no matches for kind \\"PodDisruptionBudget\\" in version \\"policy/v1beta1\\"",
"stderr_lines": [
"error: unable to recognize \\"/kubesphere/kubesphere/prometheus/prometheus/prometheus-podDisruptionBudget.yaml\\": no matches for kind \\"PodDisruptionBudget\\" in version \\"policy/v1beta1\\""
],
"stdout": "clusterrole.rbac.authorization.k8s.io/kubesphere-prometheus-k8s unchanged\\nclusterrolebinding.rbac.authorization.k8s.io/kubesphere-prometheus-k8s unchanged\\nprometheus.monitoring.coreos.com/k8s unchanged\\nprometheusrule.monitoring.coreos.com/prometheus-k8s-prometheus-rules unchanged\\nrolebinding.rbac.authorization.k8s.io/prometheus-k8s-config unchanged\\nrole.rbac.authorization.k8s.io/prometheus-k8s-config unchanged\\nservice/prometheus-k8s unchanged\\nserviceaccount/prometheus-k8s unchanged\\nservicemonitor.monitoring.coreos.com/prometheus-k8s unchanged",
"stdout_lines": [
"clusterrole.rbac.authorization.k8s.io/kubesphere-prometheus-k8s unchanged",
"clusterrolebinding.rbac.authorization.k8s.io/kubesphere-prometheus-k8s unchanged",
"prometheus.monitoring.coreos.com/k8s unchanged",
"prometheusrule.monitoring.coreos.com/prometheus-k8s-prometheus-rules unchanged",
"rolebinding.rbac.authorization.k8s.io/prometheus-k8s-config unchanged",
"role.rbac.authorization.k8s.io/prometheus-k8s-config unchanged",
"service/prometheus-k8s unchanged",
"serviceaccount/prometheus-k8s unchanged",
"servicemonitor.monitoring.coreos.com/prometheus-k8s unchanged"
]
},
{
"_ansible_item_label": "prometheus",
"_ansible_no_log": false,
"ansible_loop_var": "item",
"attempts": 5,
"changed": true,
"cmd": "/usr/local/bin/kubectl apply -f /kubesphere/kubesphere/prometheus/prometheus",
"delta": "0:00:01.147543",
"end": "2023-02-03 21:49:24.582794",
"failed": true,
"failed_when_result": true,
"invocation": {
"module_args": {
"_raw_params": "/usr/local/bin/kubectl apply -f /kubesphere/kubesphere/prometheus/prometheus",
"_uses_shell": true,
"argv": null,
"chdir": null,
"creates": null,
"executable": null,
"removes": null,
"stdin": null,
"stdin_add_newline": true,
"strip_empty_ends": true,
"warn": true
}
},
"item": "prometheus",
"msg": "non-zero return code",
"rc": 1,
"start": "2023-02-03 21:49:23.435251",
"stderr": "error: unable to recognize \\"/kubesphere/kubesphere/prometheus/prometheus/prometheus-podDisruptionBudget.yaml\\": no matches for kind \\"PodDisruptionBudget\\" in version \\"policy/v1beta1\\"",
"stderr_lines": [
"error: unable to recognize \\"/kubesphere/kubesphere/prometheus/prometheus/prometheus-podDisruptionBudget.yaml\\": no matches for kind \\"PodDisruptionBudget\\" in version \\"policy/v1beta1\\""
],
"stdout": "clusterrole.rbac.authorization.k8s.io/kubesphere-prometheus-k8s unchanged\\nclusterrolebinding.rbac.authorization.k8s.io/kubesphere-prometheus-k8s unchanged\\nprometheus.monitoring.coreos.com/k8s unchanged\\nprometheusrule.monitoring.coreos.com/prometheus-k8s-prometheus-rules unchanged\\nrolebinding.rbac.authorization.k8s.io/prometheus-k8s-config unchanged\\nrole.rbac.authorization.k8s.io/prometheus-k8s-config unchanged\\nservice/prometheus-k8s unchanged\\nserviceaccount/prometheus-k8s unchanged\\nservicemonitor.monitoring.coreos.com/prometheus-k8s unchanged",
"stdout_lines": [
"clusterrole.rbac.authorization.k8s.io/kubesphere-prometheus-k8s unchanged",
"clusterrolebinding.rbac.authorization.k8s.io/kubesphere-prometheus-k8s unchanged",
"prometheus.monitoring.coreos.com/k8s unchanged",
"prometheusrule.monitoring.coreos.com/prometheus-k8s-prometheus-rules unchanged",
"rolebinding.rbac.authorization.k8s.io/prometheus-k8s-config unchanged",
"role.rbac.authorization.k8s.io/prometheus-k8s-config unchanged",
"service/prometheus-k8s unchanged",
"serviceaccount/prometheus-k8s unchanged",
"servicemonitor.monitoring.coreos.com/prometheus-k8s unchanged"
]
}
]
},
"resolved_action": "shell",
"role": "ks-monitor",
"start": "2023-02-03T13:48:31.030866",
"task": "Monitoring | Installing Prometheus",
"task_action": "shell",
"task_args": "",
"task_path": "/kubesphere/installer/roles/ks-monitor/tasks/prometheus.yaml:2",
"task_uuid": "8219b820-73af-ffef-3dd1-000000000042",
"uuid": "d05cb401-8641-495a-88d2-94ab5a5ae0c0"
},
"parent_uuid": "8219b820-73af-ffef-3dd1-000000000042",
"pid": 2901,
"runner_ident": "monitoring",
"start_line": 112,
"stdout": "",
"uuid": "d05cb401-8641-495a-88d2-94ab5a5ae0c0"
}
************************************************************************************