Trouble with forwarding.

Posted on 1997-08-31
Medium Priority
Last Modified: 2010-03-18
 I have two linux boxes, (ethernet connection) one I am trying to set up as a router with no luck. (PPP dial on demand / diald installed, works fine). I cannot get this kernel to forward any packets, I compiled all the TCP/IP support there is in the kernel config ( including ip-forward and ip-masq, but must not be working). I can connect to the computer fine (telnet, ftp, nfs...) , but I cannot go threw it. I can connect to the internet fine when on it (telnet'ed to it or direct), but none of my routing/forwarding is allowing me to forward threw it from the other computer. I tried everything from the mini-howto's on the subject with no results. I have the ipfwadm like all the examples. I have all the nessary modules loaded. I have the routing setup like the examples. Why can't I go threw that box!

router computer:
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
nos.com         *      UH    0      0        0 sl0     *      UH    1      0        0 sl1
localnet        *        U     0      0        2 eth0
loopback        *            U     0      0        2 lo
hamnet          nos.com       UG    0      0        0 sl0
(diald set up sl1, sl0 is tnos, ham radio packet software. it is also not forwarding proberly. pppd will set the default route when it connects)

 ipfwadm -F -p deny
 ipfwadm -F -a m -S -D

other computer:
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
localnet        *        U     0      0       27 eth0
loopback        *            U     0      0       14 lo
default         musha.com         UG    0      0        0 eth0
(musha is the name of the router)

System specs:

router box:
386DX 33, 8 meg RAM, 130 Meg HD

other system:
486DX2 80, 32 meg RAM, 1.2 GIG + 420 Meg HDs

both have LINUX 2.0.30, modules 2.0.0 (all compiled myself)
router main install was Slackware 3.3
other main install was Slackware 3.2 (upgrade from 1.2.13)
I downloaded and reinstalled all the lib's, include files, kernel and modules, and other packages on the other computer. They are not from Slackware.
The router box only has the kernel and modules packages reinstalled.
Question by:jschaeffer

Expert Comment

ID: 1586368
I may be able to answer but could you elaborate on something, I had some and no luck doing exactly the same thing, If memory serves me...Do you have the router (which I assume uses a slip connection to the net and thena  Ethernet connection to the other computer) set up as a gateway.  i.e. on the  computer which can't connect in the routing table do you have the router's Ethernet IP address as a gateway, something like  route -add gw {router-eth-address} where router-... is the IP address of the Ethernet card.
Also you should know that you should not be connecting an LAN network to the net anyway, unless you have cubscribed for extra IP addresses, this may be why, because you have given the Ethernet on the "can't" computer an address which the Host and therefore Route will not process.

Accepted Solution

df020797 earned 400 total points
ID: 1586369
Drop the ipfwadm -F -p deny and it ll work.


Expert Comment

ID: 1586370
I think you're routing table is wrong. You should have a default route in there. Although when you normally connect with pppd, a default route is added, when the machine in question is a router, I'm not sure how it's going to treat incomign packets when it has no default route set up.

I run an ipmasqerading router doing pretty much the same as you seem to want to do, and my default route is through the gateway on my ISP's end, and the gatewaydevice is set to sl0. When diald brings the link up, the default route becomes the one set by pppd.

Author Comment

ID: 1586371
That did the trick!! After adjusting the route everything works great!
Thanks a lot! Sorry for taking such a long time to respond. Had trouble with this site. ( login, connect problems )

Featured Post

Upgrade your Question Security!

Add Premium security features to your question to ensure its privacy or anonymity. Learn more about your ability to control Question Security today.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I have seen several blogs and forum entries elsewhere state that because NTFS volumes do not support linux ownership or permissions, they cannot be used for anonymous ftp upload through the vsftpd program.   IT can be done and here's how to get i…
Note: for this to work properly you need to use a Cross-Over network cable. 1. Connect both servers S1 and S2 on the second network slots respectively. Note that you can use the 1st slots but usually these would be occupied by the Service Provide…
If you're a developer or IT admin, you’re probably tasked with managing multiple websites, servers, applications, and levels of security on a daily basis. While this can be extremely time consuming, it can also be frustrating when systems aren't wor…
Loops Section Overview
Suggested Courses

864 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question