Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 50762 - Multiple static routes per interface (init scripts)
Summary: Multiple static routes per interface (init scripts)
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Gentoo's Team for Core System packages
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-05-11 09:19 UTC by dack
Modified: 2004-05-11 12:44 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description dack 2004-05-11 09:19:52 UTC
The init scripts and /etc/conf.d/net do not support more than one static route per interface.  For example, with two "routes_eth0" lines in /etc/conf.d/net, only the second one has any effect.

Reproducible: Always
Steps to Reproduce:
1. add more than 1 "routes_eth0" lines in /etc/conf.d/net
2. restart net.eth0
3. run "route" to see results
Actual Results:  
Only the last route is actually set.

Expected Results:  
Set each route specified in /etc/conf.d/net

Portage 2.0.50-r6 (default-x86-2004.0, gcc-3.3.2, glibc-2.3.2-r9, 2.4.25-gentoo-
r2)
=================================================================
System uname: 2.4.25-gentoo-r2 i686 Intel(R) Pentium(R) III CPU family      
1133MHz
Gentoo Base System version 1.4.10
ccache version 2.3 [enabled]
Autoconf: sys-devel/autoconf-2.58-r1
Automake: sys-devel/automake-1.8.3
ACCEPT_KEYWORDS="x86"
AUTOCLEAN="yes"
CFLAGS="-O2 -mcpu=i686 -fomit-frame-pointer"
CHOST="i686-pc-linux-gnu"
COMPILER="gcc3"
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3/share/config /usr/share/
config /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-O2 -mcpu=i686 -fomit-frame-pointer"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs ccache sandbox strict"
GENTOO_MIRRORS="http://gentoo.oregonstate.edu 
http://distro.ibiblio.org/pub/Linux/distributions/gentoo"
MAKEOPTS="-j4"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="arts avi berkdb crypt cups encode exiscan-acl foomaticdb gdbm gif gpm 
imlib jpeg libg++ libwww mad maildir mikmod motif mpeg mysql ncurses nls 
oggvorbis opengl oss pam perl png python quicktime readline sdl slang spell ssl 
svga tcpd truetype x86 xml2 xmms xv zlib"
Comment 1 Aron Griffis (RETIRED) gentoo-dev 2004-05-11 12:44:39 UTC
Your syntax is wrong.  I'm sorry there isn't an example yet in /etc/conf.d/net or this wouldn't be a problem.

routes_eth0=(
   "-net first route args"
   "-net second route args"
)

This creates a bash array variable called routes_eth0, then it will work for you.