Author Topic: DHCP Server Multiple VLANs  (Read 1130 times)


  • Zen Apprentice
  • *
  • Posts: 2
  • Karma: +0/-0
    • View Profile
DHCP Server Multiple VLANs
« on: August 22, 2019, 03:29:21 am »
Can Zentyal only do DHCP on the internal interface when it has an IP on? I want to use it as and DHCP server for multiple VLANs from a Core switch that relay teh request t Zentyal that will the assign the IP addresses for each VLAN. From the documentation it looks like Zentyal can't be a DCHP server without an IP address in the subnet on a interface locally?

If there is any way of doing this please let me know. 


  • Zen Samurai
  • ****
  • Posts: 362
  • Karma: +91/-1
    • View Profile
Re: DHCP Server Multiple VLANs
« Reply #1 on: August 22, 2019, 10:51:54 am »


Zentyal implements a VLAN trunk type interface so, the only needed condition is that it has to have configured an static ip for his interface (documentation tell us "The DHCP service needs to be deployed on an interface configured with a static IP address. This interface should also be internal." but, actually the code checks only the static IP condition)

See /usr/share/perl5/EBox/

Code: [Select]
sub defaultGateway # (iface)
    my ($self, $iface) = @_;

    my $network = $self->global()->modInstance('network');

    #if iface doesn't exists throw exception
    if (not $iface or not $network->ifaceExists($iface)) {
        throw EBox::Exceptions::DataNotFound(data => __('Interface'),
                value => $iface);

    #if iface is not static, throw exception
    if($network->ifaceMethod($iface) ne 'static') {
        throw EBox::Exceptions::External(__x("{iface} is not static",
            iface => $iface));

    return $self->_getModel('Options', $iface)->defaultGateway();

You shouldn't have problems.

"Tanta salud goces como bondad abrigues en tu corazón"

Don Camilo.

"That place... is strong with the
dark side of the Force.  A domain
of evil it is.  In you must go."