Skip to main content

Posts

Showing posts with the label Kubernetes

When Sitecore 10.4.1 Sneaked Into a Sitecore AKS Cluster and broke it: A Troubleshooting Tale

Sitecore 10.4.1 is finally here! Everyone's excited about the new release—but with every update, sometimes surprises sneak in. And we’ve got one such story for you. This happened on a Sitecore 10.4.0 instance running in an Azure Kubernetes Service (AKS) cluster. One day, a fellow Sitecorian reached out to me and told that things just… broke. The Problem He said it was supposed to be a normal release. A developer pushed changes, the pipeline ran, and then— boom —errors everywhere. So we started looking into it. For your context, we got the below error - The Analysis Our First Guess: Maybe It’s the Code? We thought maybe the issue was in the new Pull Request (PR). We checked the changes, but everything looked okay. Just to be sure, we  reverted the PR  and tried the release again. Same error. Then we tried releasing an  older build  (before the error started). That one worked just fine. So now we knew—this wasn’t caused by code changes. The Solution Soon, w...

Sitecore Pod deployment not updating to the latest image in Kubernetes

A fellow Sitecorian reached out to me for help on an issue related to Sitecore pod deployments in Kubernetes. They built a web application based on Sitecore 10.4 Headless SXA on Azure Kubernetes Services Cluster and used Azure DevOps for CICD> The Problem We found that the latest code is not getting released to our Sitecore pods. We checked the release pipelines and Deploy Application Specifications steps has logs that mentioned that cm and cd pods are unchanged which means it did not find any differences in the build deployed to Sitecore pods and the build downloaded in pipeline. The Solution We discussed this with our Sitecore rep and he mentioned this is a known issue with Kuberenetes and it occurs as latest tag is used for fetching images from Container Repository. These images get cached and there are chances that the latest image is not picked correctly from Container Registry.  I tried googling for it and I found the following stackoverflow link talks about similar issue ...

Sitecore AKS - Collection shard cluster health check completed with status Unhealthy and Health check for shard cluster is failed.

The Problem While running the installation steps for setting up Sitecore XP in AKS, we found that the CM/CD pods are not running. This was primarily due to the fact that CM/CD pods were waiting on other pods like xDBsearch to come to running state due to wait-initialization. After waiting for significant time, we found that xDBsearch pod is not coming up and it probably has an issue. Ran kubectl logs command to check xdbsearch logs and found below entries -  The Solution This error definitely implied that the shard databases have some issue. We deleted the shard databases and ran the init job again. When the init job completes, it is advisable to check logs by running kubectl logs command. This will inform if the job was successful or did it errored out at some point. Once the shard databases were recreated, we recreated the pods and this time the xdbsearch pods came up fine. Thanks for reading :)

Installing Sitecore 10.4 on Kubernetes: A Step-by-Step Guide

Introduction Recently, a community member attempted to install Sitecore 10.4 on a Kubernetes (K8s) cluster and reached out to me regarding the challenges they faced. Despite following Sitecore's standard installation document, they encountered issues due to their limited knowledge of Kubernetes. This blog post summarizes their experience and serves as a reference for other developers in a similar situation. Steps for Installation To successfully set up a Sitecore instance in a K8s cluster, follow these detailed steps: Prerequisites Access to Azure Kubernetes Service (AKS) : Ensure you have the ability to create namespaces and clusters in AKS. Having a team member knowledgeable in Kubernetes is highly beneficial. Local Tools : Install Azure CLI, Chocolatey, and Helm on your local machine. You'll be needing these while executing commands in PowerShell. Cluster Specifications Ensure your cluster meets these specifications: Kubernetes 1.27.x or later Windows Server 2019 version 18...