Ben Ocean <[EMAIL PROTECTED]> writes:

> Harry Putnam writes, in essence:
>
>  > Let's see your netstat -nr:
>
> Destination     Gateway Genmask Flags   MSS  Window  irtt    Iface
> 192.168.1.0     0.0.0.0         255.255.255.0   U  40   0 0  eth0
> 216.9.0.0       0.0.0.0         255.255.255.0   U  40   0 0  eth1
> 127.0.0.0       0.0.0.0         255.0.0.0       U  40  0 0   lo
> 0.0.0.0         206.9.0.1       0.0.0.0         UG 40 0 0    eth1
>

Ben, I made an attempt above to reformat your netstat -nr output so
that it stays unwrapped and readable, not sure it it will work but
maybe.

I'm getting very confused here.  It's not that easy to unravel this
thread and determine what is really set and what is not.  Especially
since I'm not a network maven.

What follows is a long winded account of what should happen and how to
make it happen.  It requests that you start from scratch. After the
verbose discussion is brief summary outline of what needs to be done.

Maybe a rehash but in simplified format this is what needs to happen:

First ... for the moment diregard MASQ forwarding and pretend it isn't
a factor.  Then shut everything down that involves networking.
Flush any stray ipchains rules

These commands should clear the deck:
   ifconfig eth0 down
   ifcongig eth1 down

   ipchains -F
   ipchains -X

Make sure with:
     ifconfig <no flags>
You should only see output for `lo' (loop back)

Now lets discuss eth0 for a moment.

On the linux box, on eth0, you should have the gateway your DSL
provider gives you set as gateway .. if that is 206.9.0.1 like above
then that is fine.  You mentioned that you get a dynamic IP so I guess
it is negotiated with dhcpd or similar.  I think you showed that
somewhere in the thread.

Your IP has given you nameservers so those should appear in
resolv.conf of the linux box.  You say you can surf the net from that
box so that is apparently set up OK.

In brief: If you restart eth0, with:
   ifconfig eth0 up

You see normal connectivity to internet from the linux box.
You can ping your DSL provided gateway (206.9.0.1) nearly
instantaneously and see very short time frames.  Something on this
order: time=29.730 msec

With out rechecking the thread I'll guess your internet connection is
on eth0 as shown in the netstat -nr output.

Leaving eth0 now, its working, and setting up eth1 (your connection to
the windows box from the linux box):

Netstat -nr ouput shows  216.9.0.0 as eth1 IP address. Maybe a typo
and is really 209.9.0.1 but either way that is wrong.

Eth1 IP should be set to an address you've choosen for your internal
network.  Something in the 192 range like 192.168.0.1.  If I remember
correctly, there will be no gateway for eth1.
Test it with:
     ifconfig eth1 up
     ping 192.168.0.1  (or what ever number you've chosen)
if that works, shut it back down
     ifconfig eth1 down

With eth1 setup on linux box... Now proceeding to windows box:
Set the ip to another number in the range 192, like 192.168.0.2
Set the gateway to 192.168.0.1 (The IP address of eth1 on linux box)
Set dns servers to those provided by DSL server.

Return to the linux box and put a few things in /etc/hosts
After first copying your original to a backup
    cp -a /etc/hosts /etc/hosts_orig
Comment out anything in /etc/hosts and put stuff in this format
Putting your numbers/names in place

   127.0.0.1       localhost
   192.168.0.1     MY_linux.host.name        MY_linux
   192.168.0.2     MY_windows.host.name      MY_windows

run these commands:
   ifconfig eth1 down
   ifconfig eth1 up

   Check with `ifconfig <no flags>' that it is up

If this turns into a mess run:
   ps waux|grep eth1  (or maybe ifcfg)
and kill -9 everthing that shows up, then start over with:
    ifconfig eth1 down
    ifconfig eth1 up

(Still no forwarding involved yet)

Now you should be able to ping the windows box from linux and the
linux box from windows.  
> From linux you should be able to use alphabetic names to ping on
If you cannot, then report here your errors.

If that much works.  Then try to set up basic minimal IP Masquerade

(still not internet connected on DSL)

Run these commands on the linux box:
 (Make sure ipchains is flushed as above)

   /bin/echo "1" > /proc/sys/net/ipv4/ip_forward
   /sbin/ipchains -P forward DENY
   /sbin/ipchains -A forward -s 192.168.1.0/24 -j MASQ
NOTE:
Not sure these are still the same since 6.2 days but if not maybe
someone will correct me

Now reconnect to the internet at DSL connection (eth0) and try surfing
from your windows box.

Let us know how it goes.

Summary:  Begin by shutting down all connections and flushing ipchains

          Setup eth0 or check to make sure it agrees with above
          discussion

          Setup eth1 in accordance with outline discussed
  
          REstart eth1
          Test that pinging works to/from either box to the other.

          Run minimal masquerade commands shown

          restart eth0

          Test connectivity from windows box to internet

Only now start to worry about a better ipchains setup.



_______________________________________________
Redhat-list mailing list
[EMAIL PROTECTED]
https://listman.redhat.com/mailman/listinfo/redhat-list

Reply via email to