This guide provides solutions for common issues you might encounter when deploying and managing Kubesol clusters.
- Installation Issues
- Cluster Operations
- Networking Issues
- Storage Issues
- Component-Specific Issues
- Performance Issues
- Debugging Tools
Symptoms:
- Ansible playbook fails during RKE2 installation
- Node doesn't join the cluster
Possible Causes and Solutions:
-
System Requirements Not Met
- Ensure nodes meet minimum requirements (CPU, RAM, disk space)
- Check with:
free -m,df -h,nproc
-
Network Connectivity Issues
- Verify nodes can reach each other and the internet
- Check with:
ping,netcat,curl - Ensure required ports are open:
sudo iptables -n -v -L
-
Package Repository Issues
- Verify package repositories are accessible
- Try:
sudo apt update && sudo apt upgrade
-
Conflicting Software
- Check for other container runtimes or Kubernetes installations
- Remove with:
sudo apt remove docker kubelet kubeadm kubectl(adjust for your environment)
Symptoms:
- Ansible playbook fails with error messages
- Tasks timeout or hang
Possible Causes and Solutions:
-
SSH Connectivity Issues
- Verify SSH access to all nodes
- Check with:
ssh user@node - Ensure SSH keys are properly configured
-
Privilege Escalation Issues
- Ensure the Ansible user has sudo privileges
- Check sudoers configuration:
sudo visudo
-
Variable Configuration Issues
- Verify inventory variables are correctly set
- Check for typos or missing required variables
Symptoms:
- Node shows as "NotReady" in
kubectl get nodes - Pods scheduled to the node are stuck in "Pending" state
Possible Causes and Solutions:
-
Kubelet Service Issues
- Check kubelet status:
sudo systemctl status rke2-agentorsudo systemctl status rke2-server - View logs:
sudo journalctl -u rke2-agentorsudo journalctl -u rke2-server
- Check kubelet status:
-
Network Plugin Issues
- Check CNI plugin pods:
kubectl -n kube-system get pods | grep -i cni - View CNI logs:
kubectl -n kube-system logs <cni-pod-name>
- Check CNI plugin pods:
-
Resource Constraints
- Check node resources:
kubectl describe node <node-name> - Look for resource pressure conditions
- Check node resources:
Symptoms:
- Pods stuck in "Pending" state
- Pods frequently restarting
Possible Causes and Solutions:
-
Resource Constraints
- Check if the node has enough resources:
kubectl describe node <node-name> - Adjust pod resource requests and limits
- Check if the node has enough resources:
-
Node Affinity/Taints
- Check for node taints:
kubectl describe node <node-name> | grep Taints - Ensure pod tolerations match node taints
- Check for node taints:
-
PersistentVolume Issues
- Check PV/PVC status:
kubectl get pv,pvc - Ensure storage classes are available:
kubectl get sc
- Check PV/PVC status:
Symptoms:
- Services cannot be reached
- DNS resolution fails
Possible Causes and Solutions:
-
CoreDNS Issues
- Check CoreDNS pods:
kubectl -n kube-system get pods | grep coredns - View CoreDNS logs:
kubectl -n kube-system logs <coredns-pod-name>
- Check CoreDNS pods:
-
Service Configuration
- Verify service endpoints:
kubectl get endpoints <service-name> - Check service selectors match pod labels
- Verify service endpoints:
-
Network Policy Issues
- Check for restrictive network policies:
kubectl get networkpolicies --all-namespaces - Temporarily disable network policies to test
- Check for restrictive network policies:
Symptoms:
- Ingress resources don't route traffic
- SSL/TLS errors
Possible Causes and Solutions:
-
Ingress Controller Issues
- Check ingress controller pods:
kubectl -n kube-system get pods | grep ingress - View ingress controller logs:
kubectl -n kube-system logs <ingress-pod-name>
- Check ingress controller pods:
-
Certificate Issues
- Verify certificate status:
kubectl get certificates,certificaterequests,orders,challenges --all-namespaces - Check cert-manager logs:
kubectl -n cert-manager logs -l app=cert-manager
- Verify certificate status:
-
DNS Configuration
- Ensure DNS records point to the correct ingress IP
- Test with:
nslookup <hostname>ordig <hostname>
Symptoms:
- PVCs stuck in "Pending" state
- Volumes degraded or faulted
Possible Causes and Solutions:
-
Node Disk Issues
- Check node disk space:
df -h - Verify Longhorn node status in the Longhorn UI
- Check node disk space:
-
Replica Count Issues
- Check volume replica count in Longhorn UI
- Ensure enough nodes are available for the desired replica count
-
Filesystem Issues
- Check for filesystem errors:
sudo dmesg | grep -i error - Run filesystem checks:
sudo fsck -y /dev/<device>
- Check for filesystem errors:
For more Longhorn troubleshooting, see: Longhorn Troubleshooting
Symptoms:
- DirectPV drives not showing up
- PVCs using DirectPV stuck in "Pending"
Possible Causes and Solutions:
-
Drive Discovery Issues
- Check drive status:
kubectl -n directpv-io get directpvdrives - Manually discover drives:
kubectl -n directpv-io directpv discover --drives /dev/sd*
- Check drive status:
-
Drive Initialization Issues
- Check for drive initialization errors:
kubectl -n directpv-io logs -l app=directpv-controller - Manually initialize drives:
kubectl -n directpv-io directpv init --drives <drive-id>
- Check for drive initialization errors:
Symptoms:
- Certificates not being issued
- Certificate issuance errors
Possible Causes and Solutions:
-
Issuer Configuration
- Check issuer status:
kubectl get issuers,clusterissuers - Verify issuer configuration is correct
- Check issuer status:
-
ACME Challenges
- Check challenge status:
kubectl get challenges --all-namespaces - Ensure DNS or HTTP challenges can complete
- Check challenge status:
-
Rate Limiting
- Check for Let's Encrypt rate limiting
- Use staging environment for testing
For more cert-manager troubleshooting, see: Cert-Manager Troubleshooting
Symptoms:
- Prometheus alerts not firing
- Grafana dashboards not showing data
Possible Causes and Solutions:
-
Prometheus Issues
- Check Prometheus pods:
kubectl -n monitoring get pods | grep prometheus - View Prometheus logs:
kubectl -n monitoring logs <prometheus-pod-name>
- Check Prometheus pods:
-
Alertmanager Issues
- Check Alertmanager configuration:
kubectl -n monitoring get secret alertmanager-kube-prometheus-stack-alertmanager -o jsonpath='{.data.alertmanager\.yaml}' | base64 -d - Verify alert routing is correct
- Check Alertmanager configuration:
-
Grafana Issues
- Check Grafana datasources:
kubectl -n monitoring get secret grafana -o jsonpath='{.data.datasources\.yaml}' | base64 -d - Verify Grafana can reach Prometheus
- Check Grafana datasources:
Symptoms:
- High CPU/memory usage
- Slow response times
Possible Causes and Solutions:
-
Resource Contention
- Check node resource usage:
kubectl top nodes - Identify resource-intensive pods:
kubectl top pods --all-namespaces
- Check node resource usage:
-
Disk I/O Issues
- Check disk I/O:
iostat -x 1 - Consider using faster storage
- Check disk I/O:
-
Network Saturation
- Check network usage:
iftopornethogs - Consider network optimizations
- Check network usage:
Symptoms:
- Slow API server responses
- Etcd high latency alerts
Possible Causes and Solutions:
-
Database Size Issues
- Check etcd database size:
ETCDCTL_API=3 etcdctl --endpoints=https://127.0.0.1:2379 --cacert=/var/lib/rancher/rke2/server/tls/etcd/server-ca.crt --cert=/var/lib/rancher/rke2/server/tls/etcd/server-client.crt --key=/var/lib/rancher/rke2/server/tls/etcd/server-client.key endpoint status --write-out=table - Consider defragmentation or compaction
- Check etcd database size:
-
Disk Performance
- Ensure etcd is on SSD storage
- Check disk latency:
iostat -x 1
- kubectl describe:
kubectl describe <resource-type> <resource-name> - kubectl logs:
kubectl logs <pod-name> [-c <container-name>] - kubectl exec:
kubectl exec -it <pod-name> -- <command> - kubectl get events:
kubectl get events --sort-by='.lastTimestamp'
- journalctl:
journalctl -u rke2-server -f - dmesg:
dmesg | tail - top/htop:
top - iotop:
iotop
- tcpdump:
tcpdump -i <interface> port <port> - netstat:
netstat -tulpn - curl:
curl -v <url>
If you're unable to resolve an issue using this guide, consider:
- Checking the Kubesol FAQ
- Reviewing component-specific documentation
- Contacting commercial support if you have a support contract
- Opening an issue on the project repository
Remember to include:
- Detailed description of the issue
- Steps to reproduce
- Relevant logs and error messages
- Environment details (OS, Kubernetes version, etc.)