DHCP Server not working - Service not Found

i can’t get the dhcp server to run, in my ucs management ui the univention-dhcp service is present and running, but no service is found on the console. the configuration seems to be good, but unfortunately no address is delivered to the client.
Any ideas why no service is found?

root@dc1:~# service univention-dhcp status
Unit univention-dhcp.service could not be found.
root@dc1:~# systemctl status univention-dhcp
Unit univention-dhcp.service could not be found.
root@dc1:~# 

Bildschirmfoto 2024-01-30 um 12.16.00
Bildschirmfoto 2024-01-30 um 12.15.37

Hi,

ich denke ein ähnliche Frage ist hier dokumentiert mit ein paar Infos mehr Info zum DHCP zu erhalten:

VG

Hi und danke, das Server Objekt hatte ich bereits angelegt und dem Subnetz als “DHCP:Server” und dem Namen “dc1” hinzugefügt und leider ohne Erfolg

Ok, hast Du die anderen Anweisungen im Artikel befolgt und evt. mehr debug Infos?

Ich habe folgendes in den Logs gefunden, dachte aber dass wenn ich den univention-dhcp als Paket installiere, ich den isc-dhcp-server nicht benötige (das Paket habe ich über univention auch nicht aktiv

Jan 31 10:11:01 dc1 dhcpd[21755]: exiting.
Jan 31 10:11:11 dc1 systemd[1]: isc-dhcp-server.service: Service RestartSec=10s expired, scheduling restart.
Jan 31 10:11:11 dc1 systemd[1]: isc-dhcp-server.service: Scheduled restart job, restart counter is at 5602.
Jan 31 10:11:11 dc1 dhcpd[21760]: Error: Cannot find LDAP entry matching (&(objectClass=dhcpServer)(cn=dc1))
Jan 31 10:11:11 dc1 dhcpd[21760]: Configuration file errors encountered -- exiting
Jan 31 10:11:11 dc1 dhcpd[21760]: 
Jan 31 10:11:11 dc1 dhcpd[21760]: If you think you have received this message due to a bug rather
Jan 31 10:11:11 dc1 dhcpd[21760]: than a configuration issue please read the section on submitting
Jan 31 10:11:11 dc1 dhcpd[21760]: bugs on either our web page at www.isc.org or in the README file
Jan 31 10:11:11 dc1 dhcpd[21760]: before submitting a bug.  These pages explain the proper
Jan 31 10:11:11 dc1 dhcpd[21760]: process and the information we find helpful for debugging.
Jan 31 10:11:11 dc1 dhcpd[21760]: 
Jan 31 10:11:11 dc1 dhcpd[21760]: exiting.
Jan 31 10:11:11 dc1 systemd[1]: isc-dhcp-server.service: Control process exited, code=exited, status=1/FAILURE
Jan 31 10:11:11 dc1 systemd[1]: isc-dhcp-server.service: Failed with result 'exit-code'.

Ok,

wenn ich das richtig sehe geht es auch dort um univention-dhcp.
Aber in deiner Log steht ja:

Jan 31 10:11:11 dc1 systemd[1]: isc-dhcp-server.service: Control process exited, code=exited, status=1/FAILURE

War isc-dhcp-server schon mal installiert?
Was sagt den:

dpkg-query -W -f=’${binary:Package}\n’ *dhcp*

mit diesem query habe ich leider nichts bekommen, mit dpkg-query -W | grep dhcp folgendes

root@dc1:~# dpkg-query -W | grep dhcp
isc-dhcp-client	4.4.1-2+deb10u3A~5.0.4.202303131602
isc-dhcp-client-ddns	4.4.1-2+deb10u3A~5.0.4.202303131602
isc-dhcp-server	4.4.1-2+deb10u3A~5.0.4.202303131602
isc-dhcp-server-ldap	4.4.1-2+deb10u3A~5.0.4.202303131602
univention-dhcp	14.0.7-1A~5.0.0.202302032008

ich habe über die GUI alle isc-dhcp Pakete deinstalliert und wollte univention-dhcp installieren - univention-dhcp Paket nimmt aber automatisch den isc-dhcp mit
Die Antwort auf die Frage: ja war schon mal installiert

Bildschirmfoto 2024-01-31 um 13.42.23

Mein Fehler :sweat_smile: falsche Quote. Habs korrigiert.
die Abfrage wäre

dpkg-query -W -f='${binary:Package}\n' *dhcp*

Evt mal alle Pakete komplett entfernen

apt-get remove --purge isc-dhcp*

Bitte vorher ein Backup machen.

Ok - jetzt sehe ich auch was :slight_smile:

root@dc1:~# dpkg-query -W -f='${binary:Package}\n' *dhcp*
dhcp-client
isc-dhcp-client
root@dc1:~# 

Um jetzt den DHCP Server neu / sauber zu installieren ?
univention-install univention-dhcp

Dann installiert er aber isc-dhcp-server wieder mit, ist das ok so ?

Wenn Du mit dhcp-client arbeiten willst würde ich erstmal isc-dhcp entfernen:

apt-get remove --purge isc-dhcp*

und dann nochmal checken ob die Abfrage so aussieht:

root@dc1:~# dpkg-query -W -f='${binary:Package}\n' *dhcp*
dhcp-client
root@dc1:~#

Ich glaube es gibt hier ein Missverständnis, ich möchte auf der UCS kein dhcp-client nutzen, sondern univention-dhcp als Server incl. DNS / LDAP Integration - dafür installiert das Paket univention-dhcp die entsprechenden isc-dhcp Pakete - so wie ich das sehe, ist bei der UCS konfigurierbare DHCP Server der isc-dhcp-Server - richtig ?

ich bekomme den isc-client aber auch nicht deinstalliert


root@dc1:~# dpkg-query -W -f='${binary:Package}\n' *dhcp*
dhcp-client
isc-dhcp-client
isc-dhcp-client-ddns
isc-dhcp-common

root@dc1:~# apt-get remove --purge isc-dhcp*

Do you want to continue? [Y/n] y
(Reading database ... 93107 files and directories currently installed.)
Removing isc-dhcp-client (4.4.1-2+deb10u3A~5.0.4.202303131602) ...
Removing isc-dhcp-common (4.4.1-2+deb10u3A~5.0.4.202303131602) ...
Processing triggers for man-db (2.8.5-2) ...
(Reading database ... 93085 files and directories currently installed.)
Purging configuration files for isc-dhcp-client (4.4.1-2+deb10u3A~5.0.4.202303131602) ...
root@dc1:~# 


root@dc1:~# dpkg-query -W -f='${binary:Package}\n' *dhcp*
dhcp-client
isc-dhcp-client
root@dc1:~# 

irgendwie scheint da was schief zu laufen - welche Pakete benötige ich um die UCS als DHCP Server für die Clients in unterschiedlichen Subnetzen zu nutzen ? natürlich auch mit ldap Anbindung für DHCP / DNS Policies.

wenn ich den isc-dhcp Server installiere und in der /etc/dhcp/dhcpd.conf die Netze eintrage, funktioniert alles, aber die UCS bekommt davon nichts mit hmm

Ok,
first let’s switch back to English… :man_facepalming:

You’re absolutely right, it’s a misinterpretation on my side. I have started no understanding correctly: in my ucs management ui the univention-dhcp service is present and running

To verify the packages to be installed, you can use the following command:

apt-get -s install univention-dhcp

And here’s what you’ll find:

The following additional packages will be installed: isc-dhcp-server isc-dhcp-server-ldap libirs-export161 libisccfg-export163 policycoreutils selinux-utils

Regardless, the first thing to resolve could be figuring out why isc-dhcp-client can’t be removed, and then remove it properly. Broken dependencies in apt are never a good basis for any installation.
Next, you could use the UCS Tools to install , following the recommendation to avoid using apt. The best approach is to follow the manual and start debugging from there if still needed. Hopefully, the issue is “only” with apt, and resolving this might lead to a clean installation.
Please let me know

kind regards

ps:

Check or send:

/var/log/univention/updater.log

use apt-debuging

and check or send:
apt-cache policy isc-dhcp-client

In case needed.

Ok, no problem, it should be more understandable for other users if we continue in English.

At first it’s a bit opaque, because when I check on the GUI also CLI, the package is not installed, but with your query it seems to be available - strange.

now I installed the univention dhcp package with all decencies and I have the same issue as before

root@dc1:~# apt-cache policy isc-dhcp-client
isc-dhcp-client:
  Installed: (none)
  Candidate: 4.4.1-2+deb10u3A~5.0.4.202303131602
  Version table:
     4.4.1-2+deb10u3A~5.0.4.202303131602 500
        500 https://updates.software-univention.de ucs506/main amd64 Packages
        
        
        

root@dc1:~# systemctl status isc-dhcp-server.service
● isc-dhcp-server.service - ISC DHCP Server for IPv4
   Loaded: loaded (/etc/init.d/isc-dhcp-server; generated)
  Drop-In: /usr/lib/systemd/system/isc-dhcp-server.service.d
           └─univention-dhcp.conf
   Active: inactive (dead) since Wed 2024-01-31 15:21:21 CET; 22h ago
Condition: start condition failed at Thu 2024-02-01 14:08:50 CET; 5s ago
           └─ ConditionPathExists=/var/univention-join/dhcp-server was not met
     Docs: man:systemd-sysv-generator(8)
           man:dhcpd(8)
    Tasks: 2 (limit: 4915)
   Memory: 9.8M
   CGroup: /system.slice/isc-dhcp-server.service
           ├─24218 /usr/sbin/dhcpd -4 -q -cf /etc/dhcp/dhcpd.conf ens21
           └─25643 /usr/sbin/dhcpd -4 -q -cf /etc/dhcp/dhcpd.conf ens21


root@dc1:~# service univention-dhcp status
Unit univention-dhcp.service could not be found.
root@dc1:~# 

what about “…CondutionalPathExists … was not met”

Ok,

I would help to see the apt debug info if you can, and another:
dpkg-query -W -f='${binary:Package}\n' *dhcp*
I case you can send it.
But please sende the status from:
univention-check-join-status
and any error from:
univention-run-diagnostic-checks

Looking first into the univention-join part in the error message, before dealing with ConditionPathExists.

thx

ok here my outputs

root@dc1:~# dpkg-query -W -f=’${binary:Package}\n’ dhcp

dhcp
dhcp-client
isc-dhcp-client
isc-dhcp-common
isc-dhcp-server
isc-dhcp-server-ldap
univention-dhcp

root@dc1:~# univention-check-join-status

Joined successfully

root@dc1:~# univention-run-diagnostic-checks

xecuting following checks: ['00_check_server_password', '01_ssh_connection', '02_certificate_check', '03_check_notifier_replication', '04_saml_certificate_check', '05_check_ldap_master', '10_gateway', '11_nameserver', '12_proxy', '20_check_nameservers', '21_check_join_status', '22_kdc_service', '23_check_update_sites', '30_disk_usage', '31_file_permissions', '32_security_limits', '40_samba_tool_dbcheck', '41_samba_tool_showrepl', '43_connectors4_rejects', '44_well_known_sid_check', '45_heimdal_on_samba4_dc', '46_kerberos_ddns_update', '50_check_ucr_templates', '51_hostname_check', '52_mail_acl_sync', '53_package_status', '54_sources_list_check', '55_user_migration', '56_univention_types', '57_univention_server_role_windows', '58_check_memberOf', '59_ldap_server_name', '60_old_schema_registration', '61_notifier_protocol_version', '62_check_slapschema', '63_proof_uniqueMembers', '64_check_ucr_types', '65_check_repository_config', '66_udm_country_remap_from_st_to_c', '67_postgresql_version']

You can find the logging messages of the diagnostic modules at /var/log/univention/management-console-module-diagnostic.log

ran 00_check_server_password successfully.

ran 01_ssh_connection successfully.

ran 02_certificate_check successfully.

ran 03_check_notifier_replication successfully.

ran 04_saml_certificate_check successfully.

ran 05_check_ldap_master successfully.

ran 10_gateway successfully.

ran 11_nameserver successfully.

ran 12_proxy successfully.

ran 20_check_nameservers successfully.

ran 21_check_join_status successfully.

ran 22_kdc_service successfully.

ran 23_check_update_sites successfully.

ran 30_disk_usage successfully.

ran 31_file_permissions successfully.

ran 32_security_limits successfully.

ran 40_samba_tool_dbcheck successfully.

ran 41_samba_tool_showrepl successfully.

ran 43_connectors4_rejects successfully.

ran 44_well_known_sid_check successfully.

ran 45_heimdal_on_samba4_dc successfully.

ran 46_kerberos_ddns_update successfully.

ran 50_check_ucr_templates successfully.

ran 51_hostname_check successfully.

ran 52_mail_acl_sync successfully.

ran 53_package_status successfully.

ran 54_sources_list_check successfully.

ran 55_user_migration successfully.

ran 56_univention_types successfully.

ran 57_univention_server_role_windows successfully.

ran 58_check_memberOf successfully.

ran 59_ldap_server_name successfully.

ran 60_old_schema_registration successfully.

ran 61_notifier_protocol_version successfully.

ran 62_check_slapschema successfully.

ran 63_proof_uniqueMembers successfully.

############################ Start 64_check_ucr_types ############################
## Check failed: 64_check_ucr_types - Check UCR variable values for correctness ##
Some UCR variables currently have invalid values.
This check has been added recently; some warning may be unproblematic.
Please investigate them if you experience any problems on this system.
Use the module {ucr} to correct their values.
The variable 'ucs/web/overview/entries/service/nextcloud/port_http' has the invalid value ''.
############################# End 64_check_ucr_types #############################

ran 65_check_repository_config successfully.

ran 66_udm_country_remap_from_st_to_c successfully.

ran 67_postgresql_version successfully.

ok,

the Nextcloud message is documented as false positive. I had it myself for a while. It can be temporarily removed with:
ucr set ucs/web/overview/entries/service/nextcloud/port_http='80'

To understand the persistent isc-dhcp-client you can throw the log output of:
apt-get -o Debug::pkgAutoRemove=true remove isc-dhcp-client
into a pastebin please, looking for the next step.

Let’s stay careful with apt and its dependencies, and I assume a current backup.

kind regards

thanks for your instructions, my first issue with nextcloud seems to be fixed, the second part “uninstall isc-dhcp” debug output looks also good, but i cant paste my content to platform which was proposed - no sufficiant rights

Bildschirmfoto 2024-02-02 um 08.52.22

Hmm… maybe this one.
And what do you mean with “looks also good…” ?

ok here you are

my output

And what do you mean with “looks also good…” ?
→ i see an output :slight_smile:

Ok,

I get this:

image

Mastodon