Share via

Error Loading Shared Libraries in Azure Linux VM

Swaroop Gowda D 25 Reputation points
2025-07-16T09:20:15.0666667+00:00

Encountering the following error on an Azure Linux VM:

/bin/login: error while loading shared libraries: libc.so.6: failed to map segment from shared object

The VM's agent is operational, and the boot diagnostics show a login prompt. What steps can be taken to resolve this issue?

Azure Virtual Machines
Azure Virtual Machines

An Azure service that is used to provision Windows and Linux virtual machines.

0 comments No comments

1 answer

Sort by: Most helpful
  1. Nikhil Duserla 9,940 Reputation points Microsoft External Staff Moderator
    2025-07-16T12:34:17.34+00:00

    Hello @Swaroop Gowda D,

    On an Azure Linux VM, issues related to libc.so.6 typically indicate a problem with the glibc library, which is essential for basic system operations. Here's how to troubleshoot it:

    Filesystem mounted with noexec

    Cause: Prevents execution of binaries or shared libraries from the affected filesystem.

    Action: Remount the filesystem without the noexec option if necessary:

    sudo mount -o remount,exec /path/to/mount
    
    

    Try to reinstall glibc using your package manager:

    sudo yum reinstall glibc  # for RHEL/CentOS
    sudo apt-get install --reinstall libc6  # for Debian/Ubuntu
    

    Check disk health: dmesg | grep -i error

    Run memory tests or consider redeploying the VM if corruption is suspected.

    If you have any further queries, do let us know.

    Was this answer helpful?

    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.