loki wrote:
> Nope. Then it wouldn't set up a route. For instance I'm setting up
> ifconfig.1.eth0
(SERVICE ipv4-static, ADDRESS 10.0.44.33/16) without a default gateway.



> Then in the next ifconfig.2.eth0 I want to setup a static route towards
> 192.168.0.0/16 through a router which is on 10.0.5.5/16 I have to put
> 10.0.5.5 as the gateway for this route

> with SERVICE ipv4-static-route and TYPE network and ADDRESS
> 192.168.0.0/16.

> Because of the /sbin/ifup script it won't be

> "ip r add 192.168.0.0/16 via 10.0.5.5 dev eth0" but it will be
> "ip r add default        via 10.0.5.5 dev eth0".

> But 10.0.5.5 is not my default
> gateway it's just a gateway for 192.168.0.0/16.

> I could circumvent that by renaming the ifconfig file that has the
> default gateway in it to be in the first place in the directory. The
> script as it is now with default gateway in /sbin/ifup
> will always put the very first GATEWAY that it comes accross as the
> default gateway. In my opinion the part for default gateway should go
> back to ipv4-static.

I think I see what you mean.  What happens if we add a new variable to 
the ifconfig script:

STATIC_GATEWAY=10.0.5.5

and change GATEWAY to STATIC_GATEWAY in the ipv4-static-route script?

A more intrusive change would be to change GATEWAY to DEFAULT_GATEWAY in 
all the other scripts, but I'd prefer not to do that.

We could also add a small check to ensure both GATEWAY and 
STATIC_GATEWAY are not both defined.  That would cause problems
when using the ipv4-static-route script.

   -- Bruce
-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page

Reply via email to