Marius Tomaschewski changed bug 1202658
What Removed Added
Resolution FIXED DUPLICATE

Comment # 6 on bug 1202658 from
(In reply to Ralf Habacker from comment #5)
> (In reply to Marius Tomaschewski from comment #4)
> > The host _may_ receive something from DHCP server (at a random point of
> > time compared to apply time of the static settings) _or_ _not_ and it
> > _may_ (accidentially) provide also an IP address from a network that
> > matches the gateway from the static setup _or_ _not_.
> 
> So you are saying that internally it is not ensured that locally defined
> static routes are applied only after the full configuration is received from
> the dhcp server ?

The static config or lease and the dhcp requests are applied/requested
independently/in parallel as separate jobs (and static is the one that
is effectively applied first).

> > Because the static settings (static "lease") in ifroute files and
> > the dhcp lease are two different leases "config sets" and applied
> > independently of each other -- without conditions or dependencies
> > between them. 
> 
> This answers my question above
> 
> > Both capable to provide the complete configuration
> > and both need to be complete by themself.
> 
> Can an option be added to ensure that static routes are applied after
> receiving configuration from dhcp ? 

No, we do not plan to add such option. They're intentionally independent.

> > The clean way is to fix the dhcp server config to provide the
> > routes as described in bug 907495 to provide all routes via
> > dhcp (e.g. classless routes option).
> 
> Sorry, but this is not an option in our case, because every time the route
> is adjusted, the network would have to be restarted and clients would lose
> connections.

There is no need to restart the network.

You can call `wicked ifup eth0` also if the interface (eth0) is already
up -- "ifup" will send a config update to wickedd and  trigger a reapply.
In dhcp case, will send a dhcp (reboot) request and apply the updated
settings.

> The usual procedure in this case is:
> 1. activate the route manually with ip route 
> 2. add the new route to /etc/sysconfig/network/routes or
> /etc/sysconfig/network/ifroute-<dev so it will be set automatically on the
> next reboot.

Just add 2 lines every time you add the routes with gateway,
so there is an explicit route declaring that the gateway can
be reached  directly -- that's all that is needed here:

+    $gateway     -        # - $dev
     $destination $gateway # - $dev

-> prepend line with "+".

And just call ifup to apply -- no need to tweak manually with ip route.

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


You are receiving this mail because: