# Droping packets / Connectivity Problem



## jdp (Jan 3, 2009)

I recently setup a FreeBSD box and I am having trouble connecting it to the network. 

I am connected, to one of the wired ports, to a LinkSys wireless router which is connected to the cable modem. DHCP seems to take longer than it should, 3 or four request offer cycles, sometimes more. Once the Box is up I can ping other IPs in the network but I can't seem to ping anything on the Internet. Actually what seems to happen is I get about 95% packet loss. The other devices connected to the wireless router don't have this problem so I am at a bit of a loss. 

Does anyone have any ideas? Here is some configuration information, let me know what more might be needed. Thanks.

The FreeBSD distribution is: FreeBSD  7.0-RELEASE FreeBSD 7.0-RELEASE #0: 

The rc.conf has:
# Please make all changes to this file, not to /etc/defaults/rc.conf.
# This file now contains just the overrides from /etc/defaults/rc.conf.
inetd_enable="YES"
linux_enable="YES"
moused_enable="YES"
#sshd_enable="YES"
# -- sysinstall generated deltas -- # Sun Nov 16 15:15:04 2008
ifconfig_dc0="DHCP"


----------



## DutchDaemon (Jan 3, 2009)

What is the contents of the following after DHCP succeeds?

ifconfig -a
cat /etc/resolv.conf
netstat -rn

In other words: do you get a correct IP address and netmask, do you get a nameserver, and do you have a default gateway?


----------



## jdp (Jan 3, 2009)

Thanks, the information is below. Again the DHCP seems to take a variable number of offers before it is accepted. The assigned IP is in the range I would expect and the DNS ips are the ones found in the wireless router configuration, which is also set by DHCP with the cable company. Pinging internally seems fine, 192.168.1.0/24 but anything outside and there is high loss. The other two devices connected are a blackberry and an ubuntu linux laptop which seem fine.

Thoughts?


# ifconfig -a
dc0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
	options=8<VLAN_MTU>
	ether 00:80:ad:71:91:19
	inet 192.168.1.104 netmask 0xffffff00 broadcast 192.168.1.255
	media: Ethernet autoselect (100baseTX <full-duplex>)
	status: active
plip0: flags=108810<POINTOPOINT,SIMPLEX,MULTICAST,NEEDSGIANT> metric 0 mtu 1500
lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> metric 0 mtu 16384
	inet6 fe80::1%lo0 prefixlen 64 scopeid 0x3 
	inet6 ::1 prefixlen 128 
	inet 127.0.0.1 netmask 0xff000000 
# 

# cat /etc/resolv.conf
search hsd1.md.comcast.net
nameserver 68.87.73.242
nameserver 68.87.71.226
nameserver 68.87.64.196

# netstat -rn
Routing tables

Internet:
Destination        Gateway            Flags    Refs      Use  Netif Expire
default            192.168.1.1        UGS         0      590    dc0
127.0.0.1          127.0.0.1          UH          0       72    lo0
192.168.1.0/24     link#1             UC          0        0    dc0
192.168.1.1        00:16:b6:e2:46:62  UHLW        1        0    dc0   1078
192.168.1.100      00:1c:cc:31:50:80  UHLW        1        3    dc0   1185
192.168.1.103      00:19:7e:68:bc:4b  UHLW        1       49    dc0   1078

Internet6:
Destination                       Gateway                       Flags      Netif Expire
::1                               ::1                           UHL         lo0
fe80::%lo0/64                     fe80::1%lo0                   U           lo0
fe80::1%lo0                       link#3                        UHL         lo0
ff01:3::/32                       fe80::1%lo0                   UC          lo0
ff02::%lo0/32                     fe80::1%lo0                   UC          lo0
#


----------



## DutchDaemon (Jan 3, 2009)

The values appear to be correct. Any other NIC you can play with? This looks like an older, not exactly bug-less type (man 4 dc).


----------



## jdp (Jan 3, 2009)

I have a 3com 3c905 which I bet is just as old but I've never had problems with those cards. To the best of my knowledge the NIC in there is an off brand card. Though I believe I set this up over the network a month or two ago so I am surprised. 

Anyway I did pop in the 3com card but it didn't come up when I booted the PC. Do I have to make any configuration changes along with the card? If so what are they?


----------



## Djn (Jan 3, 2009)

That's the xl driver, so try to kldload if_xl and see if that makes it show up in the ifconfig output.


----------



## jdp (Jan 3, 2009)

Thanks, now I have both NICs in there and the drivers load for both but neither seems to work right. It was pretty odd booting, DHCP took at least 12 requests and after start up although I had an IP, a different one on the new NIC, I could ping local addresses (1.100, 1.103, ect) but not the LinkSys (192.168.1.1) for the first couple minutes. After about 5 minutes I could ping the Linksys but the situation is the same for anything outside.

Any other suggestions?

Here is the new results:

# ifconfig -a
dc0: flags=8802<BROADCAST,SIMPLEX,MULTICAST> metric 0 mtu 1500
	options=8<VLAN_MTU>
	ether 00:80:ad:71:91:19
	media: Ethernet autoselect (none)
	status: no carrier
xl0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
	options=8<VLAN_MTU>
	ether 00:60:08:2b:c6:9f
	inet 192.168.1.105 netmask 0xffffff00 broadcast 192.168.1.255
	media: Ethernet autoselect (100baseTX <full-duplex>)
	status: active
plip0: flags=108810<POINTOPOINT,SIMPLEX,MULTICAST,NEEDSGIANT> metric 0 mtu 1500
lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> metric 0 mtu 16384
	inet6 fe80::1%lo0 prefixlen 64 scopeid 0x4 
	inet6 ::1 prefixlen 128 
	inet 127.0.0.1 netmask 0xff000000 


# cat /etc/resolv.conf 
search hsd1.md.comcast.net
nameserver 68.87.73.242
nameserver 68.87.71.226
nameserver 68.87.64.196

# netstat -rn
Routing tables

Internet:
Destination        Gateway            Flags    Refs      Use  Netif Expire
default            192.168.1.1        UGS         0      470    xl0
127.0.0.1          127.0.0.1          UH          0        0    lo0
192.168.1.0/24     link#2             UC          0        0    xl0
192.168.1.1        00:16:b6:e2:46:62  UHLW        2       33    xl0    709
192.168.1.100      00:1c:cc:31:50:80  UHLW        1        4    xl0   1173
192.168.1.103      00:19:7e:68:bc:4b  UHLW        1      106    xl0    798

Internet6:
Destination                       Gateway                       Flags      Netif Expire
::1                               ::1                           UHL         lo0
fe80::%lo0/64                     fe80::1%lo0                   U           lo0
fe80::1%lo0                       link#4                        UHL         lo0
ff01:4::/32                       fe80::1%lo0                   UC          lo0
ff02::%lo0/32                     fe80::1%lo0                   UC          lo0
#


----------

