| Home | Register | Members | Search | Links |
![]() |
| Thread Tools | Display Modes |
|
|
|
| |
|
Tauno Voipio
Guest
Posts: n/a
|
Michael Badt wrote:
> Hi, > I have a Mandriva LE 2005 Desktop connected to the Internet via eth1 (static > IP 192.168.1.1 required by ADSL modem) and an ADSL (PPPoE) modem. > > I run Shorewall on the desktop (details below) with no firewall (so far, > till I set up my loc network) on the laptop. Shoreall created a > complicated, multiple chain table set (used by iptables). I think, it > supports the required IP masquerading, but I not sure due to the > complexity. > > I try to configure the desktop as an Internet gateway connected to a local > (internal) 10.200.1.0 network via its eth0. > > Today I connected to that desktop a laptop with Mandriva 2005 LE. Both > computers are interconnected by a (Crossed) Ethernet cable connected to the > respective eth0 on both PCs. The Desktop successfully runs dhcpd and > assigns the Laptop an IP address. Both Computers successfully ping each > other in both directions. > > The Problem: The laptop can't access the Internet while the Desktop is > connected. > Among others, I suspect the laptops routing and resol.conf should also be > modified (details below). Is the desktop's routing OK? > Following are the technical details. (sorry for the long data) (details stripped) Did you remember to enable IP forwarding in the desktop? Quickie: echo 1 >/proc/sys/net/ipv4/ip_forward Your laptop needs the DNS set up properly, either directly to the ISP's servers, or to a cache server in the desktop. My recommendation is to install dnsmasq on the desktop and direct the laptop to use it (via DHCP, see DHCP server configuration manual). dnsmasq will also serve the local network names from the /etc/hosts file on the desktop, if so requested. The routing in the laptop is trivial: all routes point to the desktop (including the default route). It should be properly set up after the DHCP exchange. For Internet nodes with only one path to the Net, the rule for the default route is to set it to point to the next node towards the Net. In this case, the laptop has to point to the desktop and the desktop has to point to the ISP. You can debug the connectivity step by step by first checking that the local hosts can ping each other and the desktop can ping the ISP's gateway. The next step is to make the laptop to ping the ISP's gateway with a numeric address (with 'ping -n') to check the basic IP connectivity but without DNS. The third step is to make DNS work at both computers. HTH -- Tauno Voipio tauno voipio (at) iki fi |
|
|
|
|
|||
|
|||
|
Bit Twister
Guest
Posts: n/a
|
On Sun, 12 Jun 2005 12:39:22 +0300, Michael Badt wrote:
> Hi, > I have a Mandriva LE 2005 Desktop connected to the Internet via eth1 (static > IP 192.168.1.1 required by ADSL modem) and an ADSL (PPPoE) modem. > > I run Shorewall on the desktop (details below) with no firewall (so far, > till I set up my loc network) on the laptop. Shoreall created a > complicated, multiple chain table set (used by iptables). I think, it > supports the required IP masquerading, but I not sure due to the > complexity. > > I try to configure the desktop as an Internet gateway connected to a local > (internal) 10.200.1.0 network via its eth0. shorewall_masq_search_tag Wondering if the smurf rule is dropping your 10.xx.xx.xx network. Reject rule does drop 10.x If you were to look in /var/log/messages you might get a clue as what rule drops your connections. I would change the local network from 10.x to something like 192.168.2.x if it were me. > Today I connected to that desktop a laptop with Mandriva 2005 LE. Both > computers are interconnected by a (Crossed) Ethernet cable connected to the > respective eth0 on both PCs. The Desktop successfully runs dhcpd and > assigns the Laptop an IP address. Both Computers successfully ping each > other in both directions. > > The Problem: The laptop can't access the Internet while the Desktop is > connected. Test first on Desktop, then laptop. If ping -c 1 -w 3 66.94.234.13 fails, firewall problem. If ping -c 1 -w 3 66.94.234.13 works, then you have a DNS problem. If ping -c 1 -w 3 yahoo.com fails, then you need to verify /etc/resolv.conf contains the gateway ISPs nameserver ip addy > Among others, I suspect the laptops routing and resol.conf should also be > modified (details below). if ping -c 1 -w 3 66.94.234.13 works, put the /etc/resolv.conf from the desktop into the laptop's resolv.conf. and try the yahoo ping, no restarts needed. > Is the desktop's routing OK? google, yahoo,... internet acces will go out the defautl gateway interface indicated by the G seen in route command. Click up a spare terminal on the desktop su -l root tail -f /var/log/messages then on the laptop do the ping tests, you should see which chain stopped the attempt. To get my lan network running here is all shorewall files I modifed: blacklist, masq, policy, rules, interfaces, params, routestopped You can ignore blacklist and routestopped. I am on cable modem, address is via dhcp, hardware layout internet---cable_modem---eth1---eth0---switch----eth0 for all lan boxes. ^ ^ | | Desktop firewall box------+------' Modify /etc/sysconfig/network-scripts/ifcfg-eth0 on the desktop METRIC=12 instead of 10 To understand my shorewall files you have to see my params file cat params # data values found in DHCPSERVERS=68.87.66.10 # /var/lib/dhcp/dhclient-eth1.leases DHCP_SERVERS=$DHCPSERVERS,$MODEMIP LOC_BCAST=192.168.2.255 # /etc/sysconfig/network-scripts/ifcfg-eth0 LOC_NIC=eth0 MODEMWEB=192.168.100.1 # motorola sb4220/5100 web page (if enabled) NET_BCAST=255.255.255.255 # /var/lib/dhcp/dhclient-eth1.leases NET_NIC=eth1 # /etc/sysconfig/network NET_OPTIONS=dhcp,routefilter,blacklist,tcpflags # used in shorewall/interfaces Contents of the modified shorewall files, minus the comments. You could set your NET_OPTIONS=detect and ignore the DHCP* values where you see them. fw and $FW are shorewall understood values. I use tabs as seperators in the files. cat interfaces #ZONE INTERFACE BROADCAST OPTIONS net $NET_NIC $NET_BCAST $NET_OPTIONS loc $LOC_NIC $LOC_BCAST cat masq #INTERFACE SUBNET ADDRESS PROTO PORT(S) $NET_NIC $LOC_NIC cat policy #SOURCE DEST POLICY LOG LIMIT:BURST # LEVEL loc net ACCEPT loc fw ACCEPT - fw loc ACCEPT fw net ACCEPT net all DROP info # THE FOLLOWING POLICY MUST BE LAST all all REJECT info cat rules #ACTION SOURCE DEST PROTO DEST # PORT ACCEPT net:$DHCP_SERVERS fw udp bootps,bootpc ACCEPT loc fw icmp 8 ACCEPT fw loc icmp DROP net $FW icmp echo-request ACCEPT fw net icmp |
|
|
|
|
|||
|
|||
|
Michael Badt
Guest
Posts: n/a
|
Thanks all,
Eventually I managed to solve the problem only by modifying the laptop's resolv.conf to point at my ISP's DNS server. (Yes, Ip forwarding was already enabled). Take care Michael Badt Tauno Voipio wrote: > Michael Badt wrote: >> Hi, >> I have a Mandriva LE 2005 Desktop connected to the Internet via eth1 >> (static >> IP 192.168.1.1 required by ADSL modem) and an ADSL (PPPoE) modem. >> >> I run Shorewall on the desktop (details below) with no firewall (so far, >> till I set up my loc network) on the laptop. Shoreall created a >> complicated, multiple chain table set (used by iptables). I think, it >> supports the required IP masquerading, but I not sure due to the >> complexity. >> >> I try to configure the desktop as an Internet gateway connected to a >> local (internal) 10.200.1.0 network via its eth0. >> >> Today I connected to that desktop a laptop with Mandriva 2005 LE. Both >> computers are interconnected by a (Crossed) Ethernet cable connected to >> the respective eth0 on both PCs. The Desktop successfully runs dhcpd and >> assigns the Laptop an IP address. Both Computers successfully ping each >> other in both directions. >> >> The Problem: The laptop can't access the Internet while the Desktop is >> connected. >> Among others, I suspect the laptops routing and resol.conf should also be >> modified (details below). Is the desktop's routing OK? >> Following are the technical details. (sorry for the long data) > > (details stripped) > > Did you remember to enable IP forwarding in the desktop? > > Quickie: > > echo 1 >/proc/sys/net/ipv4/ip_forward > > Your laptop needs the DNS set up properly, either directly to > the ISP's servers, or to a cache server in the desktop. > > My recommendation is to install dnsmasq on the desktop and > direct the laptop to use it (via DHCP, see DHCP server > configuration manual). dnsmasq will also serve the local > network names from the /etc/hosts file on the desktop, > if so requested. > > The routing in the laptop is trivial: all routes point to > the desktop (including the default route). It should be > properly set up after the DHCP exchange. > > For Internet nodes with only one path to the Net, the rule > for the default route is to set it to point to the next > node towards the Net. In this case, the laptop has to point > to the desktop and the desktop has to point to the ISP. > > You can debug the connectivity step by step by first checking > that the local hosts can ping each other and the desktop > can ping the ISP's gateway. The next step is to make the > laptop to ping the ISP's gateway with a numeric address > (with 'ping -n') to check the basic IP connectivity but > without DNS. The third step is to make DNS work at both > computers. > > HTH > |
|
|
|
|
|||
|
|||
|
|
|
| |
![]() |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| internet connection failure... | RANA RANVIR SINGH\(ART\) | Broadband Hardware | 0 | 01-30-2009 10:45 AM |
| how to combine 2 internet connection together so internet can share better | Shotta_tav | Wireless Internet | 3 | 02-11-2008 12:23 PM |
| Power Failure Causes Lost Internet Connection | =?Utf-8?B?Sko=?= | Broadband Hardware | 1 | 01-21-2006 04:08 AM |
| Mandriva: Failure to share internet connection | Michael Badt | Linux Networking | 0 | 06-10-2005 03:23 PM |
| Re: how to enable Internet Connection Sharing (ICS) to share the dial-up connection | Steve Winograd [MVP] | Windows Networking | 0 | 08-08-2003 07:27 AM |
Forum Software Powered by vBulletin®, Copyright Jelsoft Enterprises Ltd.
SEO by vBSEO 3.3.2 ©2009, Crawlability, Inc. |



Linear Mode

