I am following the production installation guide to install Sitecore on AKS. I am at the step of Deploy the data initialization jobs. I have run the command and it created 2 jobs in kubernetes cluster, one for mssql-init, and another for solr-init. The solr-init job ran successfully and was completed. However, the mssql-init job is not completed as shown in the image below.

enter image description here

I have tried to check on the pod by using the describe command, but it does not show any errors as shown below.

enter image description here

I checked events to see if there are any errors there. However, I do not see any errors there as shown below

enter image description here

I have tried to see the logs of the pods, but it didn't show me any logs of the pod with the following message:

Error from server (BadRequest): previous terminated container "mssql-init" in pod "mssql-init-2jvw8" not found

Could someone please help me what the error is with mssql-init container and what needs to be done to go past this error? Thanks in advance.

Update on error: I have used Stern to see the logs and found that there is a SQL connection error. Here is the error: enter image description here

  • Hi @Prasanth Nittala Can you please try to answer my question sitecore.stackexchange.com/questions/27011/… it seems you passed the point that I'm stuck on Commented Dec 1, 2020 at 21:45
  • I tried to remove all the linefeed characters from my secret files but It didn't work, I still see the warning signs (please check my question) Thanks in advance Commented Dec 1, 2020 at 23:00
  • 1
    @Mohamed Ahmed, Updated my answer, after you remove linefeed characters, you have to rerun the following steps mentioned to reflect the updated secrets. Have looked at your issue, seems like it is failing to pull sitecore images. In my case, it was able to pull images fine. Commented Dec 2, 2020 at 1:15

1 Answer 1


There were linefeed characters in the secret files. Removing the linefeed characters resolved the issue and the sql server was reachable. Once you remove the line feed characters from the files, you need to rerun the

  1. kubectl apply -k ./secrets/
  2. kubectl delete -f ./external/mssql.yaml
  3. kubectl apply -f ./external/mssql.yaml
  4. kubectl delete -f ./init/mssql-init.yaml
  5. kubectl apply -f ./init/mssql-init.yaml
  6. delete and apply the cd.yaml, cm.yaml,id.yaml and ingress.yaml again in case you see errors connecting to DB on the cd, cm.

This makes sure the new passwords are updated and are used in the containers.

  • You are my hero of the day! Thanks! :) Commented Feb 14, 2021 at 23:22

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.