?
Solved

gentoo router, basic setup.

Posted on 2005-05-05
6
Medium Priority
?
250 Views
Last Modified: 2008-02-01
Layout:
LAN(laptop, desktop - both XP) ---> swithc ---> Linux box ---> modem ---> internet.

Status:
can ping from laptop to server. can't ping to the outside world: request timed out.
can't ping from desktop to server (probably ZoneAlarm screwing around)
internet working fine on server.

Info you guys might need:

root@modemcable224 dhcp # /sbin/ifconfig
eth0      Link encap:Ethernet  HWaddr 00:0C:6E:C2:3C:EA
          inet addr:66.130.8.224  Bcast:255.255.255.255  Mask:255.255.255.0
          UP BROADCAST NOTRAILERS RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:448766 errors:0 dropped:0 overruns:0 frame:0
          TX packets:2571 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:105166536 (100.2 Mb)  TX bytes:310013 (302.7 Kb)
          Interrupt:22 Memory:feafc000-0

eth1      Link encap:Ethernet  HWaddr 00:0D:88:B5:62:05
          inet addr:192.168.0.1  Bcast:192.168.0.255  Mask:255.255.255.0
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:2020 errors:0 dropped:0 overruns:0 frame:0
          TX packets:2897 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:217630 (212.5 Kb)  TX bytes:358411 (350.0 Kb)
          Interrupt:22 Base address:0xd400


root@modemcable224 dhcp # /sbin/route -n
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
192.168.211.0   0.0.0.0         255.255.255.0   U     0      0        0 vmnet8
192.168.0.0     0.0.0.0         255.255.255.0   U     0      0        0 eth1
66.130.8.0      0.0.0.0         255.255.255.0   U     0      0        0 eth0
172.16.108.0    0.0.0.0         255.255.255.0   U     0      0        0 vmnet1
127.0.0.0       127.0.0.1       255.0.0.0       UG    0      0        0 lo
0.0.0.0         66.130.8.1      0.0.0.0         UG    0      0        0 eth0



root@modemcable224 dhcp # iptables -L
Chain INPUT (policy ACCEPT)
target     prot opt source               destination
ACCEPT     all  --  anywhere             anywhere
ACCEPT     all  --  anywhere             anywhere
REJECT     udp  --  anywhere             anywhere            udp dpt:bootps reject-with icmp-port-unreachable
REJECT     udp  --  anywhere             anywhere            udp dpt:domain reject-with icmp-port-unreachable
ACCEPT     tcp  --  anywhere             anywhere            tcp dpt:ssh
DROP       tcp  --  anywhere             anywhere            tcp dpts:0:1023
DROP       udp  --  anywhere             anywhere            udp dpts:0:1023

Chain FORWARD (policy ACCEPT)
target     prot opt source               destination
DROP       all  --  anywhere             192.168.0.0/16
ACCEPT     all  --  192.168.0.0/16       anywhere
ACCEPT     all  --  anywhere             192.168.0.0/16

Chain OUTPUT (policy ACCEPT)
target     prot opt source               destination


...all I want is to share the internet connection.
please advise.

thank you. wish I would have more points....
0
Comment
Question by:vRisc
  • 3
  • 3
6 Comments
 
LVL 3

Accepted Solution

by:
joju earned 200 total points
ID: 13943020
on linux box what i see is eth0 is connected to modem
eth1 is connected to switch.


DO the following on Linux box

1.enable ip forwarding if its not enabled

#echo 1 > /proc/sys/net/ipv4/ip_forward

2. Masquerade the source packets

iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE

Do the following on clients

1. Add 192.168.0.1 as default gateway


Thanx,
Joju.
0
 

Author Comment

by:vRisc
ID: 13944438
Thanks Joju, however got it working before i got the post.


I'm having problems with the desktop computer.
it cannot ping the network.

.. if you could help me with that, the points are yours.
I uninstalled zonealarm, turned off windows firewall, and still can't ping the network...

the laptop however, works beautifully.
any help, much appreciated.
thanks.
0
 
LVL 3

Expert Comment

by:joju
ID: 13944527
post the output of command "ipconfig /all" run on ur desktop computer.

Thanx,
Joju.
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:vRisc
ID: 13945347
Microsoft Windows XP [Version 5.1.2600]

(C) Copyright 1985-2001 Microsoft Corp.



C:\Documents and Settings\Hemma>ipconfig



Windows IP Configuration





Ethernet adapter Local Area Connection 2:



        Connection-specific DNS Suffix  . :

        IP Address. . . . . . . . . . . . : 0.0.0.0

        Subnet Mask . . . . . . . . . . . : 0.0.0.0

        Default Gateway . . . . . . . . . :



Ethernet adapter Local Area Connection:



        Media State . . . . . . . . . . . : Media disconnected



C:\Documents and Settings\Hemma>ipconfig /renew



Windows IP Configuration



An error occurred while renewing interface Local Area Connection 2 : unable to c

ontact your DHCP server. Request has timed out.

No operation can be performed on Local Area Connection while it has its media di

sconnected.



C:\Documents and Settings\Hemma>ipconfig /all



Windows IP Configuration



        Host Name . . . . . . . . . . . . : DEVEN-COMPUTER

        Primary Dns Suffix  . . . . . . . :

        Node Type . . . . . . . . . . . . : Unknown

        IP Routing Enabled. . . . . . . . : No

        WINS Proxy Enabled. . . . . . . . : No



Ethernet adapter Local Area Connection 2:



        Connection-specific DNS Suffix  . :

        Description . . . . . . . . . . . : D-Link DL10050-based Ethernet Adapte

r (Generic)

        Physical Address. . . . . . . . . : 00-05-5D-07-86-38

        Dhcp Enabled. . . . . . . . . . . : Yes

        Autoconfiguration Enabled . . . . : Yes

        Autoconfiguration IP Address. . . : 169.254.225.210

        Subnet Mask . . . . . . . . . . . : 255.255.0.0

        Default Gateway . . . . . . . . . :



Ethernet adapter Local Area Connection:



        Media State . . . . . . . . . . . : Media disconnected

        Description . . . . . . . . . . . : Intel(R) PRO/100 VE Network Connecti

on

        Physical Address. . . . . . . . . : 00-0C-6E-41-5C-24



C:\Documents and Settings\Hemma>
0
 

Author Comment

by:vRisc
ID: 13949545
it was the damned wire. i found out while testing with a laptop, that there were both replies and timed out requests all together.

thanks for the help.
please return 30 pts and assign 20 to joju, for the effort.

thanks, joju
0
 
LVL 3

Expert Comment

by:joju
ID: 13950960
No problems from my side to close this question. I didnt help much to get points.
Thanx,
Joju.
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

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…
Despite its rising prevalence in the business world, "the cloud" is still misunderstood. Some companies still believe common misconceptions about lack of security in cloud solutions and many misuses of cloud storage options still occur every day. …
Suggested Courses

840 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