Linux - NetworkingThis forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
something very wierd is going on and i don't know if anybody can help me on this
i have the following setup
CentOS 5.3(clean installation)
eth0 is my lan interface
eth2 is my internet interface
DMZ is set to the ADSL modem/router for interface eth2 of linux
dhcpd running on eth0
eth2 is set to be configured with dhcp getting it from the modem/router(the dhcp address is the internet address not from router's dhcpd,due to DMZ set on the linux box)
i have set in /etc/sysctl.conf
net.ipv4.ip_forward = 1
and have added the following rules in iptables:
iptables --append FORWARD --in-interface eth0 -j ACCEPT
iptables --table nat --append POSTROUTING --out-interface eth2 -j MASQUERADE
the box pass all data from eth0 to eth2
and internet works
and lan works perfectly
now the problem:
from time to time and for a wierd reason
this stops working
meaning i can connect from another lan machine using ssh for example to the internal interface
but internet stops working
this is verified by wireless client connected directly to the router with dhcp enabled
i can't figure out what's going on
i even changed the internet NIC(used to be eth1)
When you are having trouble, try clearing out all the firewall rules and see if the problem is still there, if it is not, then you may just have some iptables rules that maybe causing a conflick somewhere.
When you are having trouble, try clearing out all the firewall rules and see if the problem is still there, if it is not, then you may just have some iptables rules that maybe causing a conflick somewhere.
You this to clear all the iptables rules.
If the problem is still there, it maybe a routing problem, you can check the output of the routing table with (as root).
i have already tried that fotoguy
the rules that i show here are the only rules applied in the firewall
I am using an old rc.firewall-2.4 script from years ago.
Could not ping or SSH into a box on the 10.0 from the 192.168. FOTOGUY suggested clearing the firewall - bingo. This enabled this traffic. The two lines I added to my firewall script to enable eth1<>eth2 traffic:
$IPTABLES -A FORWARD -i $INTIF -o $INTIF1 -j ACCEPT
$IPTABLES -A FORWARD -i $INTIF1 -o $INTIF -j ACCEPT
i managed to find what's the problem
you can't believe this but for a wierd reason my isp changes the gateway so i have to renew with dhcp in order to get the new gateway(note that my ip is static)
i will have to contact them to clear this out
i managed to find what's the problem
you can't believe this but for a wierd reason my isp changes the gateway so i have to renew with dhcp in order to get the new gateway(note that my ip is static)
i will have to contact them to clear this out
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.