[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Static route config



On Fri, Feb 22, 2002 at 08:01:40AM -0600, Jor-el wrote:
> Hi,
> 
> 	How do I configure a static route into the startup scripts / files
> so that the route is set at boot time? I dont think
> /etc/network/interfaces will work for this because none of the interfaces
> on the machine belong to the destination net. Here is the config I am
> working with :
> 
> eth0 - 192.168.0.0/24  <-- Uplink to the router
> eth1 - 192.168.1.0/24
> tr0  - 192.168.2.0/24 
> 
> I need to route packets destined for 192.168.10.0/8 onto eth1. I can
> define the route on the command line - just havent figured out where to
> define it so that the system comes up on a reboot with this route also
> defined.

/etc/network/if-up.d/yourscript

Your script will prolly have to check if eth0 is up when
it runs... There's an environment variable being set for you,
but it's not in the docs AFAIK. It's in the source though.
(There's a wishlist bug there for sure. :-)

-- 
-----------------------------------------------------------
Paul "TBBle" Hampson, MCSE
4th year CompSci/Asian Studies student, ANU
The Boss, Bubblesworth Pty Ltd (ABN: 51 095 284 361)
Paul.Hampson@Anu.edu.au

Of course Pacman didn't influence us as kids. If it did,
we'd be running around in darkened rooms, popping pills and
listening to repetitive music.

This email is licensed to the recipient for non-commercial
use, duplication and distribution.
-----------------------------------------------------------

Attachment: pgp971YFJ0P0k.pgp
Description: PGP signature


Reply to: