Ubuntu 16.04 realm: Couldn't join realm: Necessary packages are not installed: sssd-tools sssd libnss-sss libpam-sss adcli

Asked by Chinnu

while joining Ubuntu 16.04 server to AD, we get the below error that packages are not installed, But when we check the packages are already installed on the server.

#realm join ad.testdomain.com -U Administrator --verbose
 * Resolving: _ldap._tcp.ad.testdomain.com
 * Performing LDAP DSE lookup on: 10.10.10.11
 * Performing LDAP DSE lookup on: 10.10.10.12
 * Successfully discovered: ad.testdomain.com
Password for Administrator:
 * Unconditionally checking packages
 * Resolving required packages
 ! Necessary packages are not installed: sssd-tools sssd libnss-sss libpam-sss adcli
realm: Couldn't join realm: Necessary packages are not installed: sssd-tools sssd libnss-sss libpam-sss adcli

#dpkg -l sssd-tools sssd libnss-sss libpam-sss adcli realmd samba-common-bin samba-libs krb5-user
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name Version Architecture Description
+++-====================================-=======================-=======================-=============================================================================
ii adcli 0.8.1-1 amd64 Tool for performing actions on an Active Directory domain
ii krb5-user 1.13.2+dfsg-5 amd64 Basic programs to authenticate using MIT Kerberos
ii libnss-sss:amd64 1.13.4-1ubuntu1 amd64 Nss library for the System Security Services Daemon
ii libpam-sss:amd64 1.13.4-1ubuntu1 amd64 Pam module for the System Security Services Daemon
ii realmd 0.16.2-2 amd64 DBus service for configuring kerberos and other online identities
ii samba-common-bin 2:4.3.9+dfsg-0ubuntu0.1 amd64 Samba common files used by both the server and the client
ii samba-libs:amd64 2:4.3.9+dfsg-0ubuntu0.1 amd64 Samba core libraries
ii sssd 1.13.4-1ubuntu1 amd64 System Security Services Daemon -- metapackage
ii sssd-tools 1.13.4-1ubuntu1 amd64 System Security Services Daemon -- tools

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu Edit question
Assignee:
No assignee Edit question
Solved by:
Chinnu
Solved:
Last query:
Last reply:
Revision history for this message
Manfred Hampl (m-hampl) said :
#1

For additional diagnostics, what is the output of

uname -a
lsb_release -crid
sudo dpkg --audit
dpkg -l realmd
file `which realm`

Revision history for this message
Anthony Kempski (akempski-u) said :
#2

a workaround I found is adding this to the end of the join command --install=/

Revision history for this message
Chinnu (panjalanaveen540) said :
#3

Thanks a lot Anthony!

It worked.

Revision history for this message
Teluka (mateusz-p) said :
#4

You just need to install packagekit so realm can deal with and install missing packages.

apt-get install realmd packagekit

Cheers.