Bug 46045 - failed to create DC Slave (1) [E: Object exists: (uid) : oxs$]
failed to create DC Slave (1) [E: Object exists: (uid) : oxs$]
Status: CLOSED FIXED
Product: UCS
Classification: Unclassified
Component: System setup
UCS 4.2
Other Linux
: P5 normal (vote)
: UCS 4.3-1-errata
Assigned To: Richard Ulmer
Arvid Requate
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2018-01-15 16:47 CET by Johannes Keiser
Modified: 2019-03-12 22:25 CET (History)
3 users (show)

See Also:
What kind of report is it?: Bug Report
What type of bug is this?: 6: Setup Problem: Issue for the setup process
Who will be affected by this bug?: 1: Will affect a very few installed domains
How will those affected feel about the bug?: 3: A User would likely not purchase the product
User Pain: 0.103
Enterprise Customer affected?:
School Customer affected?:
ISV affected?:
Waiting Support:
Flags outvoted (downgraded) after PO Review:
Ticket number: 2018083021000661, 2018053021000497, 2018042621000498, 2018030521000716, 2017122421000282
Bug group (optional): External feedback
Max CVSS v3 score:


Attachments
return_to_role_page.patch (1.33 KB, patch)
2018-08-27 18:18 CEST, Arvid Requate
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Johannes Keiser univentionstaff 2018-01-15 16:47:58 CET
Version: 4.2-3 errata256 (Lesum)

Domain setup (this might take a while): failed to create DC Slave (1) [E: Object exists: (uid) : oxs$]
Comment 1 Johannes Keiser univentionstaff 2018-03-16 12:53:39 CET
Reported again: Version: 4.2-3 errata310 (Lesum)

Domain setup (this might take a while): failed to create DC Slave (1) [E: Object exists: (uid) : msg$]
Comment 2 Johannes Keiser univentionstaff 2018-05-02 18:55:34 CEST
Reported again: Version: 4.3-0 errata22 (Neustadt)

Domäneneinrichtung (Dies kann einige Zeit dauern): failed to create Member Server (1) [E: Object exists: (uid) : slave$]
Comment 3 Johannes Keiser univentionstaff 2018-07-31 15:05:25 CEST
Version: 4.3-0 errata89 (Neustadt)

Remark: Hi,
this seems to be a chicken-egg-problem.
I use UCS as domain controller for my home network.
When I want to create a new VM I add a new computer in UCS so the VM has DNS/DHCP _before_ it can join the domain. Then I boot and install UCS on the VM and want to join as member
server - joining complains that the entry already exists.
Expectation: Joining warns about existing entry and asks if it should delete_conflicting_entry or retry.

Thanks

Traceback(d41d8cd98f00b204e9800998ecf8427e):
Domain setup (this might take a while): failed to create Member Server (1) [E: Object exists: (mac)  ***]

Role: memberserver
Comment 4 Arvid Requate univentionstaff 2018-07-31 17:57:23 CEST
The traceback from Comment 3 should have gone to Bug 42124. I've used the ticket to ask for additional information.
Comment 5 Richard Ulmer univentionstaff 2018-08-02 09:47:42 CEST
When clicking "NEXT" on the "Host settings" page, it will now be checked if the uid for the given host name already exists.

univention-system-setup (11.0.5-13)
73dbb77c0df7 | Bug #46045: Merge branch 'rulmer/46045' into 4.3-1
108353ebdfce | Bug #46045: Add changelog entry
9ad54fc506b9 | Bug #46045: Check if uid is used in the system setup
282945b93dd6 | Bug #46045: Remove unreachable code
723e38e08d3c | Bug #46045: Add UMCP command for checking if uid already exists

univention-system-setup.yaml
e040c25e8482 | Bug #46045: Update yaml file
Comment 6 Richard Ulmer univentionstaff 2018-08-02 15:23:30 CEST
REOPEN: When the user chooses not to start the join at the end of the installation on the "Domain join information" page of the univention system setup, the user will get warned about the uid being used already.

The test should be skipped in this case, because the domain administrator's credentials are not available.
Comment 7 Richard Ulmer univentionstaff 2018-08-02 15:52:53 CEST
univention-system-setup (11.0.5-15)
8acaf5a1f87a | Bug #46045: Don't try to run checks with master if not joining

univention-system-setup.yaml
9cc498f4562e | Bug #46045: Update yaml file
Comment 8 Richard Ulmer univentionstaff 2018-08-06 14:23:00 CEST
I had broken the base system installation, so I fixed that.

univention-system-setup (11.0.5-16)
20907d5f1c0b | Bug #46045: Merge branch 'rulmer/46045' into 4.3-1
bc067ba0e2be | Bug #46045: Fix validation page of base system installation

univention-system-setup.yaml
c8fafb0e3bc3 | Bug #46045: Update yaml file
Comment 9 Richard Ulmer univentionstaff 2018-08-08 12:43:31 CEST
I had broken the admember installation, so I fixed that.

univention-system-setup (11.0.5-20)
e52ed36928d6 | Bug #46045: Don't run duplicate uid check on admember

univention-system-setup.yaml
e84d1f8883c7 | Bug #46045: Update yaml file
Comment 10 Arvid Requate univentionstaff 2018-08-21 13:32:15 CEST
I think we need to adjust this in the following two points:


1. make the check more precise, just checking the hostname will give false
   positives in UCS@school. It's ok if the hostname already exists, as long
   as the role matches. For Bug #42022 you implemented a -checkPrerequisites
   check for univention-join, I guess we should use something like that here too.


2. Re-think the error message from the point of view of a user.
   A user doesn't know why he gets a message like

   The uid 'newhostname$' is already used in the LDAP.

   I would rather say something like

   The hostname 'newhostname' already exists in the UCS domain.

   But this will have tho be adjusted anyway for point 1.
Comment 11 Arvid Requate univentionstaff 2018-08-21 13:42:27 CEST
Regarding Point 1: This bug is closely related to Bug 42124 that's listed here under "See Also". The backend checks check_uid / check_if_uid_is_available need to be adjusted to match those checks: If a hostname already exists, then the role must match. (Additionally the mac address must not be assigned to a different host.)
Comment 12 Richard Ulmer univentionstaff 2018-08-22 13:06:16 CEST
I have (temporarily) reverted the changes, to make the errata release today possible.

54325227b3 Bug #46045: Revert yaml changes
8f175b4655 Bug #46045: Add changelog entry
d14d00e237 Bug #46045: Temporarily revert all changes
Comment 13 Richard Ulmer univentionstaff 2018-08-23 16:00:53 CEST
It will now be checked if an existing LDAP-entry has the same role. No warning will be displayed if this is the case.

I also reworded the warning.

a4d40a276d Bug #46045: Add yaml entry
b4e4012720 Bug #46045: Merge branch 'rulmer/46045' into 4.3-1
c7f71de94f Bug #46045: Add changelog entry
a6cc2ce4c2 Bug #46045: Enable using a taken uid if the role is the same
f92c1546fd Bug #46045: Re-apply previously reverted changes
Comment 14 Arvid Requate univentionstaff 2018-08-23 17:30:38 CEST
As discussed, the univention-ssh tries to connect to the nameserver, but that may not be a UCS server, or it may not habe teh complete LDAP (UCS@school slave) and it may not have the credentials necessary for getAdminConnection().

Check out base/univention-lib/python/admember.py, where the python module "resolver" is used to lookup the _domaincontroller_master._tcp SRV record to find the name of the DC Master.
Comment 15 Richard Ulmer univentionstaff 2018-08-24 12:42:01 CEST
I have changed the server, to which a ssh connection is made, to the DC master. The name of the is already available in the front end, so I don't need to resolve the _domaincontroller_master._tcp SRV record.

a985d589df Bug #46045: Update yaml file
00227117a2 Bug #46045: Add changelog entry
19993e6dc0 Bug #46045: Fix used address for the DC master
Comment 16 Arvid Requate univentionstaff 2018-08-27 18:18:12 CEST
Created attachment 9643 [details]
return_to_role_page.patch

Ok, works, I would suggest the attached additional patch to make the "Adjust settings" choice actually return to the role selection page.
Comment 17 Richard Ulmer univentionstaff 2018-08-28 13:19:18 CEST
As discussed, I will not apply the patch, because the user is already on the page, where he can change the hostname, when pressing "Adjust settings".

In order to comply with our coding style I have removed the bind() function, I had previously introduced.

git commits (sorted from most recent to oldest):
da0e05894f Bug #46045: Update yaml file
a1f519f0bf Bug #46045: Add changelog entry
d015cc2548 Bug #46045: Avoid using bind()
Comment 18 Arvid Requate univentionstaff 2018-08-28 21:47:59 CEST
Ok, looks good.
Comment 19 Arvid Requate univentionstaff 2018-08-29 12:49:40 CEST
<http://errata.software-univention.de/ucs/4.3/226.html>
Comment 20 Johannes Keiser univentionstaff 2018-10-04 14:46:46 CEST
Reported again: Version: 4.2-4 errata500 (Lesum)

Domain setup (this might take a while): failed to create Member Server (1) [E: Object exists: (uid) : ucs-server02$]