Bug 37149

Summary: dhcpd fails to start: subnet & netmask != network
Product: UCS Reporter: Philipp Hahn <hahn>
Component: DHCPAssignee: UCS maintainers <ucs-maintainers>
Status: RESOLVED DUPLICATE QA Contact:
Severity: normal    
Priority: P5 CC: best, gohmann
Version: UCS 4.1   
Target Milestone: UCS 4.0-x   
Hardware: Other   
OS: Linux   
See Also: https://forge.univention.org/bugzilla/show_bug.cgi?id=32995
What kind of report is it?: --- What type of bug is this?: ---
Who will be affected by this bug?: --- How will those affected feel about the bug?: ---
User Pain: Enterprise Customer affected?:
School Customer affected?: ISV affected?:
Waiting Support: Flags outvoted (downgraded) after PO Review:
Ticket number: Bug group (optional):
Max CVSS v3 score:

Description Philipp Hahn univentionstaff 2014-12-02 15:35:09 CET
I accidentally created a subnet 10.200.36.0/16, where

# ipcalc 10.200.36.0/16
Address:   10.200.36.0          00001010.11001000. 00100100.00000000
Netmask:   255.255.0.0 = 16     11111111.11111111. 00000000.00000000
Wildcard:  0.0.255.255          00000000.00000000. 11111111.11111111
=>
Network:   10.200.0.0/16        00001010.11001000. 00000000.00000000
HostMin:   10.200.0.1           00001010.11001000. 00000000.00000001
HostMax:   10.200.255.254       00001010.11001000. 11111111.11111110
Broadcast: 10.200.255.255       00001010.11001000. 11111111.11111111
Hosts/Net: 65534                 Class A, Private Internet

dhcpd fails to start:
# tail /var/log/daemon.log
Dec  2 15:25:18 test35 dhcpd: subnet 10.200.36.0 netmask 255.255.0.0 
Dec  2 15:25:18 test35 dhcpd:                                      ^
Dec  2 15:25:18 test35 dhcpd: LDAP: cannot parse dhcpService entry 'cn=phahn.qa,cn=dhcp,dc=phahn,dc=qa'
Dec  2 15:25:18 test35 dhcpd: Configuration file errors encountered -- exiting

This happens because of subnet & netasmk != subnet.
Changing /16 to /24 allows the server to start again.

UMC should detect this mis-configuration and prevent generating such an invalid configuration.
Comment 1 Florian Best univentionstaff 2014-12-02 15:45:37 CET
(In reply to Philipp Hahn from comment #0)
> UMC should detect this mis-configuration and prevent generating such an
> invalid configuration.
yes! we should also fix Bug #32995.
Comment 2 Philipp Hahn univentionstaff 2017-04-07 12:39:33 CEST

*** This bug has been marked as a duplicate of bug 44135 ***