1 |
On Thu, Apr 12, 2007 at 12:29:03PM -0400, Sascha Hlusiak wrote |
2 |
|
3 |
> Wow, got it solved with iproute2. Have these two statements in |
4 |
> the /etc/conf.d/net now: |
5 |
|
6 |
I've have to do something similar when I use my backup dialup account |
7 |
instead of eth0 to the router to ADSL. Here are my ~/bin/dialup and |
8 |
~/bin/dialdown scripts. Before dialup, I have to take down eth0 and set |
9 |
up ssmtp to use my dialup ISP's MTA... |
10 |
|
11 |
#!/bin/bash |
12 |
/usr/bin/sudo /sbin/ifconfig eth0 down |
13 |
/usr/bin/sudo /usr/bin/cp -f /etc/ssmtp/295.ssmtp.conf /etc/ssmtp/ssmtp.conf |
14 |
/usr/bin/sudo /usr/sbin/pon 295caext |
15 |
|
16 |
After hanging up after a dialup session, I have to reset ssmtp to use |
17 |
my ADSL provider's MTA server, and restart eth0... |
18 |
|
19 |
#!/bin/bash |
20 |
/usr/bin/sudo /usr/sbin/poff |
21 |
/usr/bin/sudo /usr/bin/cp -f /etc/ssmtp/istop.ssmtp.conf /etc/ssmtp/ssmtp.conf |
22 |
/usr/bin/sudo /etc/init.d/net.eth0 restart |
23 |
|
24 |
Is it possible to set things up so that... |
25 |
|
26 |
- when only eth0 is active, everything routes via 192.168.123.254 |
27 |
|
28 |
- when both eth0 and ppp0 are active, my little LAN on 192.168.123.248/29 |
29 |
(aka netmask 255.255.255.248) routes via 192.168.123.254 and everything |
30 |
else routes through ppp0? |
31 |
|
32 |
My current /etc/conf.d/net looks like so... |
33 |
|
34 |
config_eth0="192.168.123.252 broadcast 192.168.123.255 netmask 255.255.255.248 mtu 1452" |
35 |
routes_eth0=("default via 192.168.123.254") |
36 |
|
37 |
|
38 |
-- |
39 |
Walter Dnes <waltdnes@××××××××.org> In linux /sbin/init is Job #1 |
40 |
Q. Mr. Ghandi, what do you think of Microsoft security? |
41 |
A. I think it would be a good idea. |
42 |
-- |
43 |
gentoo-user@g.o mailing list |