/* HINT: Search archives @ http://www.indyramp.com/masq/ before posting! */


----- Original Message -----
From: Tudor Oprea <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, February 10, 2000 1:29 AM
Subject: [Masq] FORWARDING not working


> /* HINT: Search archives @ http://www.indyramp.com/masq/ before posting!
*/
>
>
> Hi all,
>
> This is my first post, and it's going to sound familiar to a lot of you...
>
> I'm running  a fresh install (3 hours old) of RH6.1 on a Celeron with 1
> pci network card and 1 isa (set for
> non-PnP mode).  Both seem to work just fine, I've switched them around and
> tested them in both roles.  I connect through an ADSL connection, but my
> DHCP lease is fairly long (3 days) so I don't really get any ip switching.
>
> I've set up eth0 as my external interface on the pci card, and eth1 as the
> internal one.  eth0 is configured fine using DHCP, and eth1 is set to
> 192.168.1.1, netmask 255.255.255.0.  I followed the old mini-HOWTO
> (v1.50) step by step, and it seems that the RH6.1 kernel comes with all
> the forwarding/masquerading options modularized (I haven't recompiled it
> yet, maybe there's one I missed?)
>

You DO NOT need to recompile the Stock Kernel that comes with RH6.1


> I also checked ipmasq.cjb.net and looked at the new HOWTO, tried the
> default script for kernel 2.2.0+.  I uncommented the line for DHCP, and
> put in eth0 in the right place there.
>
> To cut to the chase...  I have a win98 box I'm trying to route, with a
> working network card.  I've set it up as 192.168.1.2, gateway 192.168.1.1,
> netmask 255.255.255.0, and the DNS server of my ADSL provider.  I can ping
> between the two boxes fine, I can telnet from the win98 machine to the
> Linux server.  The external interface works great from the linux box, I
> can see and ping everything in sight.
>
> The problem is, it's not really forwarding/masquerading any packets.  From
> the win98 box, I can't reach either hosts or ip addresses (so it's not a
> dns problem).  I can't ping anything except the gateway.  I've tried a
> zillion scripts sent to me by various lucky friends.  I've echoed "1" to
> /proc/sys/net/ipv4/ip_forwarding, and set FORWARD_IPV4 to "yes" under
> /etc/sysconfig/network.  Still no luck.
>
Setting the FORWARD_IPV4=yes, sets IP Forwarding.  This causes the
Networking Configuration Processing to execute the echo command you
indicated (the parameter is "ip_forward" not "ip_forwarding"):
     echo "1" > /proc/sys/net/ipv4/ip_forward
To verify it is enabled you can perform a:
      more  /proc/sys/net/ipv4/ip_forward
This should display a "1".

> One side note... apart from wondering if I should recompile the kernel if
> I'm using a stock RH6.1 install...
> in /etc/sysconfig/network, GATEWAY="192.168.1.254", and GATEWAYDEV="eth1".
> I've also got routing enabled through netconf, and routed is set to "does
> not export any routes (silent)" there also.  My hostname/domain is set
> to localhost.localdomain under netconf, although both get changed to my
> actual hostname/domain when DHCP runs.
>

The above GATEWAY and GATEWAYDEV definitions are wrong.  They are
incorrectly set for your Internal Network.  They should be for External
Network...

The GATEWAY (the Default Gateway) should be the IP Address of your
NIC for External Network.  Since, the IP is acquired dynamically, you need
to leave GATEWAY blank, and establish the Gateway Link via the
GATEWAYDEV (Default Gateway Device) Parameter.  Therefore,
set GATEWAYDEV to your External NIC, "eth0" (by doing this you
are basically telling the Network Configuration Processing to execute
a: "route add default eth0").

Also, within your IPCHAINS rules, as the first rule:

/sbin/ipchains -A input -j ACCEPT -i eth0 -s 0/0 67 -d 0/0 68 -p udp

This will allow for renewel of your Dynamic Address.


Therefore, your IPCHAIN Rule Set would look something like this:

/sbin/ipchains -A input -j ACCEPT -i eth0 -s 0/0 67 -d 0/0 68 -p udp
/sbin/ipchains -P forward DENY
/sbin/ipchains -A forward -s 192.168.1.0/24 -j MASQ


> I've seen some RH6 posts on the web that mentioned that by default DHCP
> was handled by something called PUMP, and that it was recommended to
> switch to dhcpcd.  I don't know exactly where to find this, I've checked
> rc.sysinit, /etc/init.d/network, /etc/sysconfig/network-scripts/ifcfg-eth0
> to no avail.  In any case, it works fine and all my server settings get
> filled in.
>

PUMP works just fine..... No need to change things to DHCP Client
Daemon (DHCPCD).


> I'm stuck for answers.  I've been wrestling with this for about three days
> now, and I've kinda hit a plateau.  Nothing I do really makes a difference
> either way.
>
> Any help would be greatly appreciated.
>
> Tudor
>
> _______________________________________________
> Masq maillist  -  [EMAIL PROTECTED]
> Admin requests can be handled at http://www.indyramp.com/masq-list/ --
THIS INCLUDES UNSUBSCRIBING!
> or email to [EMAIL PROTECTED]
>
> PLEASE read the HOWTO and search the archives before posting.
> You can start your search at http://www.indyramp.com/masq/
> Please keep general linux/unix/pc/internet questions off the list.

_______________________________________________
Masq maillist  -  [EMAIL PROTECTED]
Admin requests can be handled at http://www.indyramp.com/masq-list/ -- THIS INCLUDES 
UNSUBSCRIBING!
or email to [EMAIL PROTECTED]

PLEASE read the HOWTO and search the archives before posting.
You can start your search at http://www.indyramp.com/masq/
Please keep general linux/unix/pc/internet questions off the list.

Reply via email to