# NIC stops responding to outside



## Red_Cat (Jul 30, 2011)

I'm running FreeBSD 8.2

After my initial cabling problems my network interface card seemed to be working normally until I had to access the machine from another PC on the LAN. The machine stops responding to any incoming requests (pings, ftp, web page requests) somewhere between 15 to 60 minutes after I have initiated any outgoing traffic from the console. It sometimes will drop off line when it's being actively accessed - while doing some configuration of phpBB I moved to a new page and suddenly it was gone again.

All I have to do to get it back on line is to do an outbound ping to another box on the LAN then it's back up for a time.

Contents of rc.conf:

```
hostname="xxxxxx.my.domain"

ifconfig_fxp0="DHCP"
defaultrouter="10.0.0.1"

# -- For Apache22 Server
apache22_enable="YES"

# -- Start MySQL server
mysql_enable="YES"

# -- Enable FTP
ftpd_enable="YES"
```


```
#ifconfig

fxp0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
	options=2009<RXCSUM,VLAN_MTU,WOL_MAGIC>
	ether 00:11:11:46:17:13
	inet 10.0.0.110 netmask 0xffffff00 broadcast 10.0.0.255
	media: Ethernet autoselect (100baseTX <full-duplex>)
	status: active
plip0: flags=8810<POINTOPOINT,SIMPLEX,MULTICAST> metric 0 mtu 1500
lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> metric 0 mtu 16384
	options=3<RXCSUM,TXCSUM>
	inet6 fe80::1%lo0 prefixlen 64 scopeid 0x4 
	inet6 ::1 prefixlen 128 
	inet 127.0.0.1 netmask 0xff000000 
	nd6 options=3<PERFORMNUD,ACCEPT_RTADV>
```


```
#netstat -rn

Routing tables

Internet:
Destination        Gateway            Flags    Refs      Use  Netif Expire
default            10.0.0.1           UGS         0        0   fxp0
10.0.0.0/24        link#2             U           0       86   fxp0
10.0.0.110         link#2             UHS         0        0    lo0
127.0.0.1          link#4             UH          0       75    lo0

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

I'm guessing (hoping!) that it's something simple and staring me in the face but I can't see it.

Thanks in advance!


----------



## DutchDaemon (Jul 31, 2011)

Any spare NIC lying around somewhere? Occam's Razor says hardware problem. Looks like an old NIC, they can die slowly.


----------



## Red_Cat (Aug 1, 2011)

I installed a Linksys LNE100TX NIC that I had around and disabled the motherboard interface in the BIOS. The behavior is unchanged - it stopped responding to the outside world twice in the first couple of hours.


```
$ ifconfig
dc0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
        options=80008<VLAN_MTU,LINKSTATE>
        ether 00:20:78:1f:9f:26
        inet 10.0.0.110 netmask 0xffffff00 broadcast 10.0.0.255
        media: Ethernet autoselect (100baseTX <full-duplex>)
        status: active
plip0: flags=8810<POINTOPOINT,SIMPLEX,MULTICAST> metric 0 mtu 1500
lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> metric 0 mtu 16384
        options=3<RXCSUM,TXCSUM>
        inet6 fe80::1%lo0 prefixlen 64 scopeid 0x3
        inet6 ::1 prefixlen 128
        inet 127.0.0.1 netmask 0xff000000
        nd6 options=3<PERFORMNUD,ACCEPT_RTADV>
```


For now I have to move on so I added a CRONTAB(1) entry to ping the router once every minute. That has kept the system available to the LAN for the last 20 or so hours. It'll probably be fine like but it feels like a cheap and dirty fix.
`*/1 * * * * /sbin/ping -c 1 10.0.0.1 > /dev/null`

If anyone has any further ideas, I'd be interested to hear them.

Thanks again


----------



## SirDice (Aug 1, 2011)

Bad cables? Bad port on the switch?


----------



## wblock@ (Aug 1, 2011)

I had a long and witty response that the phpBB software helped me discard, so let me hit the high points in a sullen, grumpy, and far less interesting manner:

1. Symptoms could be the switch disabling a port with too many errors.

2. DLink switch.  Right wall wart?  Check the voltage, they're easy to mix up.  Try a different one in case it's going bad.  Try a different Ethernet port, they can fail individually.  Try a non-DLink switch, either between the DLink and FreeBSD system, or in place of the DLink altogether.  Try a short Ethernet cable again.

3. FreeBSD utilities like netstat(1) and systat(1) have statistics on errors and such.  Can't help with specifics, have never needed them.  The freebsd-net mailing list might be helpful there.

4. What you've seen so far with networking on FreeBSD is not normal.  Normal is It Just Works.


----------



## Red_Cat (Aug 3, 2011)

For now it's working fine, at least until the Dlink takes offense at the incessant pinging. The consensus seems to be that it's a cabling / router issue so when I get caught up with some other things I fiddle some more with those.

Thanks for the help. I'll post an update when I get back to this.


----------

