I installed a Debian Linux OS today, but found that the default text editor is nano, which I am not familiar with. After searching how to set text editor using google, I got the solution. Two environment variables can be… Read More
a few words about prometheus
A few days ago I implemented the horizontal pod auto scaling for our application based on customer metrics in the Kubernetes. During the implementation, I setup a Prometheus server to gather metrics from the application and setup a Prometheus-Adapter to… Read More
crd-install for apiextensions.k8s.io/v1 does not work in helm v2 command
A few days ago, when I tried to install the below application with the latest helm chart using helm v2 command, I got an error message complaining that the helm chart is a helm v3 chart. https://github.com/prometheus-community/helm-charts/tree/main/charts/kube-prometheus-stack After struggling for… Read More
boilerplate code for Linux getopt
Linux getopt command is often used to parse script options. I find a piece of boilerplate code for this command and mark it in this post for further reference. set -eu set +e options=$(getopt –name “demo.sh” -o “f:d” -l “file:,debug”… Read More
a few kubectl command examples
In this post, I will list a few examples for kubectl comman, which can be referenced in daily work. 1. create tls secret kubectl create secret tls secret-name –cert=/path/to/cert –key=/path/to/key 2. get information from pod get the ready status of… Read More
disk block size vs filesystem block size
In this post, I will briefly describe the differences between disk block size and filesystem block size. In the computer architecture, every byte in the main memory has a unique address. In x86 arch, the CPU can read 4 bytes… Read More
pitfalls and tips when using self-signed certificate
A few days ago, I encountered an issue when using a self-signed certificate. The use case of the self-signed certificate is simple. I created a self-signed certificate with openssl and configure it in the application. There is no issue on… Read More
avoid large size of helm chart
These days I am trying to integrate one helm chart as a sub chart into another helm chart. However, I encountered a installation problem after the integration. When I run the below command to install a release, I got the… Read More
extract files from rpm packages
These days I am developing a feature involving rpm packages. Sometimes I need to extract the files from the rpm package instead of installing it. I mark the command here for further reference. rpm2cpio demo.rpm | cpio -idmv
database transaction acid
A few days ago, I encountered the term ‘ACID’ when reading one article about database. I summarized the term in this post after searching it using google, so that it can be referenced later. Atomicity Transactions are often composed of… Read More