# 9.2 and 10.0 Realtek network issue



## Limnery (Jun 9, 2014)

My 9.2 machine was rebooted due to update 9.2-p8 but the network hangs after reboot ~20 mins later and only `service netif restart` resolved the problems.  I had to check ping every min to see network is ok when not automatically restart netif.

Console attached and OS was responsive. Tried with rescue system 10.0, same problem happened. Reverted back with freebsd-update() to original state 9.2.0 but problem still exist and now made a manual kernel/world rebuild but same results. Before the update and restart there wasn't any network problem.

This is a rental server at Hetzner so I have to proof there is a hardware issue not software related. From Linux rescue system they did a test and then there wasn't any network lose after 30 minutes. Now I'm trying the same but bigger time window.


```
re0@pci0:2:0:0: class=0x020000 card=0x368c1462 chip=0x816810ec rev=0x01 hdr=0x00
    vendor     = 'Realtek Semiconductor Co., Ltd.'
    device     = 'RTL8111/8168B PCI Express Gigabit Ethernet controller'
    class      = network
    subclass   = ethernet
    bar   [10] = type I/O Port, range 32, base 0xd800, size 256, enabled
    bar   [18] = type Memory, range 64, base 0xfeaff000, size 4096, enabled
    PCI errors = Signalled System Error
  PCI-e errors = Non-Fatal Error Detected
                 Unsupported Request Detected
     Non-fatal = Unsupported Request
```


----------



## Limnery (Jun 9, 2014)

Test done with Debian 7.0 rescue system with a 2 hour ping run, but no network network problem during this period.


----------



## dawgfoto (Oct 8, 2014)

Same problem here, do you have any further information on this?
There quite some reports of stability issues with this card and re(4).


----------



## SirDice (Oct 8, 2014)

It's possible the Linux driver is a bit more forgiving when the card throws bad stuff back. That could explain why it tests fine on Linux. But to be honest the re(4) cards aren't the best. They're cheap but that's about it. Don't expect stellar performance from any of them. If possible get a supported Intel network card.


----------



## dawgfoto (Oct 30, 2014)

Turns out that this was some hardware/network problem of my hoster.


----------



## rmoe (Nov 1, 2014)

It's true, earlier Realtek chips were crap and even current chipsets aren't the first choice. But they usually work OK. I happen to have a system with a re(4) that works just fine since two years or so.
And, hey, if your hosted/rented box happens to have a re(4) built in you'll have to make do with that, in particular with cheaper hosters.

To expand somewhat on SirDice I'd guess a bit ...

The card _did_ work before and does work now with Linux, so it's not dead. The more modern Realtek chipsets are pretty complex thingies and I'd guess that something has been changed by the 9.3 upgrade (which _did_ change the driver).

My approach would be to hand-tune the beast so as to have it in a well known state. In particular

- set it to 100TX or 1000TX mode (`ifconfig`), depending on what I _really_ get from my hoster
- check my configuration and be sure to have hw.re.intr*_*filter, hw.re.msi*_*disable, and hw.re.msix*_*disable set correctly in loader.conf
- same with hw.re.prefer*_*iomap
- Finally, and quite possibly related to your situation, I'd be sure to have a sensible value for dev.re.%d.int*_*rx*_*mod

My first suspicions are either a MSI inconsistency or an inadequate dev.re.%d.int*_*rx*_*mod value. Unfortunately I'm not able to simply tell you the right settings because they, particularly the MSI related ones are depending on your concrete system and situation.
Also note that it's _not_ "smart" to simply set dev.re.%d.int*_*rx*_*mod to either the min or the max values. While the max value is on the safe side from a low-level perspective it may well create trouble upstairs. And to set the value too low might seem smart ("I've an 3l1t3 ultra performance config!") but will certainly turn out troublesome or non-working.

Good luck!


----------



## CyberCr33p (Feb 27, 2015)

Did you find any solution for this issue?


----------



## ZOleg (Aug 24, 2015)

CyberCr33p said:


> Did you find any solution for this issue?


Download, build and install driver from Realtek


----------



## SirDice (Aug 24, 2015)

Both 9.2 and 10.0 are now end-of-life. Try a supported version instead.


----------

