Ubuntu client fails to join the UCS domain

Hello!

I am having a project and currently I am in a stage where I need to join Ubuntu clients to UCS domain.
I have successfully joined around half of them but one of them fails with the following error.

File “/usr/sbin/univention-domain-join”, line 506, in check_if_ssh_works_with_given_account
raise DomainJoinException

(‘It’s not possible to connect to the DC master via ssh, with the given credentials.’)

Looking forward to a fruitful response.

Thank you in advance!

Hey,

try ssh’ing into the DC Master manually, e.g. ssh root@<hostnameOfYourDCMaster> and see what happens.

m.

Thank you for the sharp response.

The normal ssh’ing works.

I forgot to mention to run that ssh as root.

Does ssh <usernameGivenDuringJoin>@<hostnameOfYourDCMaster> work, too? That user name is most likely administrator.

No I was not able to ssh with ‘administrator’, but I just troubleshooted it.

Now I am also able to ssh with administrator, but still not able to join the client.

So what’s the error message now?

Unfortunately the error is same.

Look at /var/log/auth.log on your DC Master when you try to join the client. It should show messages from sshd. What are they?

It shows the following message:

ucs-master CRON[14974]: pam_unix(cron:session): session closed for user root

The last line isn’t necessarily interesting; the ones from sshd are. If there aren’t any from around the time you tried the join, then no connection was actually attempted.

The join client creates log files. Please post their output. They’re stored in /var/log/univention on the client you’re trying to join (on the server a directory with the same name exists, too, but that one isn’t important for now).

The error I posted is from the same log file. Following are the complete details from the log file.

Traceback (most recent call last):
  File "/usr/sbin/univention-domain-join", line 457, in run
    distribution_joiner = self.get_joiner_for_this_distribution(self.master_ip, self.admin_username, self.admin_pw)
  File "/usr/sbin/univention-domain-join", line 484, in get_joiner_for_this_distribution
    self.check_if_ssh_works_with_given_account(master_ip, master_username, master_pw)
  File "/usr/lib/python2.7/dist-packages/univention_domain_join/utils/general.py", line 40, in root_wrapper
    return_value = func(*args, **kwargs)
  File "/usr/sbin/univention-domain-join", line 506, in check_if_ssh_works_with_given_account
    raise DomainJoinException('It\'s not possible to connect to the DC master via ssh, with the given credentials.')
DomainJoinException: It's not possible to connect to the DC master via ssh, with the given credentials.

Have you considered simply reinstalling the machine instead of spending a lot of time trying to hunt down the cause of the problem?

Of course that may work, but I thought of troubleshooting the error and learning something.

Because reinstalling the machine can not always be the right solution.

Well, you could try running strace on the join process and analyze the output. Or modify the Python files and add a lot of debugging output.

Problem is that the most obvious ways to debug this aren’t working or don’t offer new insight (log file, test connection via ssh).

Yes, I think I should reinstall the machine.

Thank you!

Mastodon