Comment 2 for bug 1980246

Revision history for this message
Andreas Hasenack (ahasenack) wrote :

This was fixed in debians samba package 4.17.3-3[1], by having the libnss-winbind postinst handle /etc/nsswitch.conf:

if [ "$1" = configure ] && [ -z "$2" ]; then
    echo "First installation detected, adding winbind to /etc/nsswitch.conf..."
    if ! [ -e /etc/nsswitch.conf ]; then
        echo "Could not find /etc/nsswitch.conf."
    else
        sed -r -i \
          -e '/^(passwd|group):.*[[:space:]]winbind\b/b' \
          -e 's/^(passwd|group):.*/& winbind/' \
          /etc/nsswitch.conf
    fi
fi

This change is available in lunar and later.
1. https://launchpad.net/debian/+source/samba/2:4.17.3+dfsg-3
2. https://git.launchpad.net/ubuntu/+source/samba/tree/debian/libnss-winbind.postinst?h=import/2%254.17.3%2bdfsg-3