Problem
In MOSIPv1.1.4 we introduced kafka for processing packets but we see that the kafka pods are gets into crashloop backoff state and keeps on crashing. Even after restarts the pods do not come up.
Root cause
Kalfka takes time to synchronize when it starts hence we need to increase the initialDelaySeconds
for liveness and readinesss.
Solution
In order to resolve this issue you need to perform the below changes in your enviornment.
Add readiness and liveness probe for all your kafka services
livenessProbe: enabled: true initialDelaySeconds: 120 timeoutSeconds: 5 readinessProbe: enabled: true initialDelaySeconds: 120 failureThreshold: 6 timeoutSeconds: 5
To make sure kafka restarts properly,
Remove the kafka helm
Remove the pv (persistent volume) of kafka
Remove the pvc (persistent volume claim) of kafka
Remove the persisted kafka folders
Run the kafka playbook