I am not sure on the password but it is asking for itwhile running "sudo systemctl restart docker.socket"

Krishna Chaitanya Mallipeddi (Tech Mahindra Ltd) 0 Reputation points Microsoft Vendor
2024-04-15T23:30:08.02+00:00

Capture

Need help on resetting the password. Having the below issue while running the docker pull so using the above statement.
dockerpull

Thanks
Krishna

Azure Container Registry
Azure Container Registry
An Azure service that provides a registry of Docker and Open Container Initiative images.
420 questions
Azure Cloud Services
Azure Cloud Services
An Azure platform as a service offer that is used to deploy web and cloud applications.
665 questions
0 comments No comments
{count} votes

3 answers

Sort by: Most helpful
  1. hossein jalilian 4,690 Reputation points
    2024-04-15T23:55:13.2366667+00:00

    Thanks for posting your question in the Microsoft Q&A forum.

    You can create a new administrative/sudo user with an SSH key for authentication:

    az vm user update --resource-group myResourceGroup --name myVM --username myNewUser --ssh-key-value ~/.ssh/id_rsa.pub
    

    Please don't forget to close up the thread here by upvoting and accept it as an answer if it is helpful


  2. Anveshreddy Nimmala 3,460 Reputation points Microsoft Vendor
    2024-04-16T05:53:12.8333333+00:00

    Hello Krishna Chaitanya Mallipeddi (Tech Mahindra Ltd)

    You mentioned an issue with Docker that led you to try restarting the docker socket. If you're seeing an error with docker pull or other Docker commands,

    please provide the specific error message you're seeing. This will help diagnose the issue more accurately.

    Common Docker issues might include problems with permissions, Docker daemon not running, or network issues affecting pulls from Docker registries. Restarting the Docker service might help if the service is down.

    sudo systemctl restart docker

    If you can provide the exact error message from Docker or more details about what's going wrong, I can give you more specific advice on how to solve it.

    1.Reboot your computer.

    2.Hold or repeatedly press the key that brings up the boot menu (often F12, Esc, or Del), then select the option to boot into recovery mode

    3.Once in recovery mode, you may see an option to "access a root shell or terminal." Select this option

    4.At the root shell, enter the command to reset the password for your user account.

    passwd your_username

    5.Replace " your_username" with your actual username.

    6.It prompts to enter a new password.

    7.Restart the System.

    8.Once the password is reset, reboot the system normally.

    reboot

    If an answer has been helpful, please consider accepting the answer to help increase visibility of this question for other members of the Microsoft Q&A community. If not, please let us know what is still needed in the comments so the question can be answered. Thank you for helping to improve Microsoft Q&A!

    0 comments No comments

  3. mutaz-msft 2,341 Reputation points Microsoft Employee
    2024-04-16T09:00:24.65+00:00

    Hi @Krishna Chaitanya Mallipeddi (Tech Mahindra Ltd),

    It seems you are using Azure cloud shell, your user account in Cloud Shell is an unprivileged account. You can't use sudo or run any command that requires elevated permissions.
    Reference: https://video2.skills-academy.com/en-us/azure/cloud-shell/faq-troubleshooting#i-want-to-install-a-tool-in-cloud-shell-that-requires-sudo-is-that-possible

    The Docker CLI is installed in Azure cloud shell instances however the daemon is not. So things like docker pull, docker build, and docker push do not work.
    Reference: https://github.com/MicrosoftDocs/azure-docs/issues/8464

    You can install both the Azure CLI and the Docker engine on your local machine.

    Hope this helps.

    0 comments No comments