facing problems in configuring two (PPP, Eth) interfaces.

facing problems in configuring two (PPP, Eth) interfaces.

Post by Sreenivas Devall » Mon, 15 Jun 1998 04:00:00



Hi All,

        I have a small subnet at home with TWO machines in it.  One is a
Linux box and the other one is NT4.0 server. Both machines have ethernet
card and the Linux machine has modem.
     Recently I have taken dedicated access from my ISP.Now I have THREE
valid  static IP addresses.  I have tried to configure Linux as a
router/gateway  so that both my machines will be on internet. But it
didn;t work.

      ----------                                     -------------
      |                     |          Ethernet
|                             |    ppp
      |   WinNT      | <-------------> |   Linux                |
------------->   ISP
      |                     |
|                             |
       ---------                                         -----------

        This is the configutation of my network.
        My problem here is to keep both my machines on internet, so that
I can access these machines from Internet also.

        Thanks in advance.

Sreenivas Devalla
Lucent Technologies

 
 
 

1. route based on incoming eth out ppp - two eth / two ppp

I have two ethernet connections to an internal lan and two
outbound connections via ppp - two seperate isp's

I need to be able to route traffic based on incoming source.

                   25
 ------->| eth0    | --------->ppp0 ---------> Internet
              |    80        |
              |              |
              |    26        |
 ------->| eth0:1  | --------->ppp1 ---------> Internet
                  8080  

I have two squid and two sendmail daemons running each
bound to it's interface.
Outbound mail needs to be able to go through it's
respective isp's smtp server as a smart host - hence
the traffic shaping.

I have scripted the connection and then added the following
iptables setup. Unfortunately it is not working.

#/bin/bash!
p0=`/sbin/ifconfig |grep P-t-P | awk '{print $2}' \
|sed -e 's/addr\://g;' |grep 209`
p1=`/sbin/ifconfig |grep P-t-P | awk '{print $2}' \
|sed -e 's/addr\://g;' |grep 129`
#
echo $p0
echo $p1
# Setup IPTABLES
                iptables -t mangle -A PREROUTING -i eth0 -j MARK --set-mark 20
                iptables -t mangle -A PREROUTING -i eth1 -j MARK --set-mark 21
                ip route add default via $p0 dev ppp0 table 22
                ip route add default via $p1 dev ppp1 table 23
                ip rule add fwmark 20 table 22
                ip rule add fwmark 21 table 23

Can anyone see where i have made a mistake in this?

Thanks for any and all help,

Cheers,

Chris

2. Can't access public_html directory

3. Router dropping packets from eth interface to ppp interface

4. command to check linked file

5. Two eth interfaces, only one works at a time

6. 2.4 + generic HDLC update? Any ideas?

7. two eth interfaces, on dhcp, one static?

8. Solaris 8 / SendMail question

9. Need help:routing table for 1 eth and n ppp interfaces

10. Create routing table for 1 eth and multiple ppp interface

11. routing out two ppp lines via source eth - iptables

12. Configuring PPP for two PPP connections

13. facing problem while configuring the cyclade z card with redhat 6.2