-
How to Connect to a CloudSQL MySQL Instance with Private IP
Not sure about everyone else, I wouldn’t run my MySQL server like a website with a public IP attached. Making the instance private is good as a security approach it is a bit inconvenient when I need to connect to it from my laptop. With Google Cloud CLI gcloud command, it’s very easy to connect…
-
Solved: HTTP 525/526 CloudFlare Errors
HTTP 525/526 errors are unofficial HTTP errors specific to CloudFlare. In a nut shell they mean HTTP TLS cert related errors when communicating with origin web servers. I got one of these from my sites so I took a look into this. I use cert-manager’s integration with Let’s Encrypt to automatically renew my TLS certs.…
-
MySQL Online DDL Operations Made Simple with gh-ost
What’s an online DDL operation? In a nut shell, a DDL(Data Definition Language) operation is something like alter table … which will change the data structure of a table. Some changes only touch metadata, eg. index, etc. so those can be updated in-place. But if a field definition needs to change, eg. UTF8mb3 –> UTF8mb4,…
-
How I Upgraded Sail Operator And How I Would Do It Next Time
It’s been a while since I installed Istio with Sail Operator in my home lab Kubernetes cluster. The version of Sail Operator was 0.2 and now 1.26 is available. There are so many releases between 0.2 and 1.26! Can I upgrade directly to the latest and skip all the middle ones? It’s my home lab…
-
Resource Optimisation Made Simple in Kubernetes Clusters
TL; DR: I made a shell script which prints out the CPU and memory usage vs allocation for each pod in a Kubernetes cluster. Then it’s easy to tell where to optimise. Here it is: Just in case, you need the metrics-server for the kubectl top command to function. 🙂
-
How to Upgrade Kubeadm Kubernetes Clusters The Fast Way
My home lab Kubernetes cluster built with kubeadm hasn’t got an upgrade for a while, still at 1.29 which was first released roughly 2 years ago. And the latest is 1.33 already. According to the official kubeadm docs Skipping MINOR versions when upgrading is unsupported. Which basically says, if you try to upgrade from 1.29…
-
Slow Refresh in ArgoCD? Scale It Up
TL; DR: I merged a few ArgoCD clusters together into a central ArgoCD last week, just to have 1 ArgoCD to manage multiple GKE clusters. Obviously this will cause some performance issue – the more apps I have, the longer it takes to refresh in ArgoCD. Here’s a simple way to scale it up. For…
-
How to Drop Unwanted Metrics with Google Managed Prometheus
TL; DR: some prometheus exporters such as kube-state-metrics do emit a LOT of metrics and that will make a difference in your next bill so here’s how to drop them. 🙂