Istio is an alternative to Linkerd and represents a dedicated level of infrastructure called Service Mesh. It helps manage communication between services, handle retries, timeouts, and automatically encrypt connections.
Installing the Istio add-on component provides balancing of gRPC traffic when scaling HUMMIX services. It also provides telemetry — success rates, latencies, etc.
Service Mesh is a necessary component to enable support for scaling services on the side of the HUMMIX application. Without an installed Service Mesh, traffic balancing when scaling HUMMIX microservices will not work correctly.
Installation consists of five steps:
- Modify kernel parameters on worker nodes (optional).
- Downloading the Helm chart and configuration file.
- Fill out the configuration file.
- Install the Istio chart using helm in the Kubernetes cluster
- Enable Istio in the namespace with the HUMMIX application.
Step 1: Modify kernel parameters on worker nodes (optional)
Before installation, ensure that the operating system parameters are set correctly. If parameters for increasing inotify limits are not set, add them to the configuration file /etc/sysctl.conf:
sudo nano /etc/sysctl.conf
fs.inotify.max_user_instances = 1024
fs.inotify.max_user_watches = 1048576
Update the parameter values with the following command:
sysctl -p
Step 2: Download the Helm chart and configuration file
For installation via the internet, get the configuration file values-istio.yaml by executing the command:
helm repo add hummix https://charts.hummix.co
helm repo update
helm show values hummix/istio > values-istio.yaml
helm repo add hummix https://charts.hummix.co For more details, see Download HUMMIX images.
tar -xf istio-X.Y.Z.tgz |
Step 3: Fill out the configuration file
Fill out the configuration file values-istio.yaml for the installation of the Istio service.
For the istioNamespace parameter, specify the namespace in which Istio is being installed.
To ensure high availability of Istio:
- enable service autoscaling and set the minimum and maximum number of replicas in the parameters
pilot.autoscaleMinandpilot.autoscaleMax; - without autoscaling, set the number of service replicas in the parameter
pilot.replicaCount.
# Istio settings
global:
# namespace for Istio (must be created before installation using kubectl create ns)
istioNamespace: istio-system
...
istiod:
pilot:
# service autoscaling
autoscaleEnabled: true
# minimum and maximum number of replicas
autoscaleMin: 1
autoscaleMax: 5
# number of service replicas without autoscaling
replicaCount: 1
...
# Istio settings Where repository format is:
|
Step 4: Install the Istio chart using helm in the Kubernetes cluster
Install the Istio chart in namespace istio-system. Namespace will be created during installation if it was not previously created.
For installation via the internet:
helm upgrade --install istio hummix/istio -f values-istio.yaml -n istio-system --create-namespace
For offline installation without internet access, go to the directory with the downloaded chart and execute the command:
helm upgrade --install istio ./istio -f values-istio.yaml -n istio-system --create-namespace
Step 5: Enable Istio in the namespace with the HUMMIX application
In the described example, the HUMMIX application is installed in namespace hummix.
Attention
The concurrent operation of multiple Service Meshes is not allowed.
Important: before enabling Istio, you must check and disable other Service Mesh in the namespace where the HUMMIX application is installed.
To disable Linkerd, remove the namespace annotation with the HUMMIX application:
kubectl annotate namespace hummix linkerd.io/inject-
Add a label to the namespace with the HUMMIX application for automatic injection of Istio-proxy containers into the HUMMIX services using the command:
kubectl label namespace hummix istio-injection=enabled --overwrite
Restart all HUMMIX application services using the command:
kubectl rollout restart deploy [-n namespace] && kubectl rollout restart ds [-n namespace]
Delete the Istio chart using helm in the Kubernetes cluster
Attention
Before removing the Istio add-on component, disable autoscaling on the side of the HUMMIX application.
To delete the Istio chart in the namespace istio-system, execute the command:
helm uninstall istio -n istio-system