Ubuntu client fails to join the UCS domain


#1

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!


#2

Hey,

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

m.


#3

Thank you for the sharp response.

The normal ssh’ing works.


#4

I forgot to mention to run that ssh as root.

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


#5

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.


#6

So what’s the error message now?


#7

Unfortunately the error is same.


#8

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?


#9

It shows the following message:

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


#10

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).


#11

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.

#12

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


#13

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.


#14

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).


#15

Yes, I think I should reinstall the machine.

Thank you!