Jump to content
XPEnology Community

Не видит сетевуху RTL8111F PCI-E


tERBO

Recommended Posts

Люди добрые - помогите советом

Воткнул в сервак PCI-E сетевуху на чипе RTL8111F, а он её не видит. В списке совместимости RTL8111F значится, но только для шины PCI...

Пошерстил форум - 2 года назад советовали править файл boot/syslinux/syslinux.cfg, однако у меня boot/ раздела нету в системе (смотрел midnight commander-ом). Может быть за это время что-то изменилось? Подскажите где и что подправить чтобы сетевуха заработала.

Link to comment
Share on other sites

boot/syslinux/syslinux.cfg - скорее всего это находится на флешке (если стоит 5 версия). Установи в Винде программу Ext2Fsd-0.63.exe или более новую версию и будет доступ к этому каталогу.

Link to comment
Share on other sites

Воткнул в сервак PCI-E сетевуху на чипе RTL8111F, а он её не видит. В списке совместимости RTL8111F значится, но только для шины PCI...

для шины PCI-E тоже, и driver r8168 для всех карт RTL8111х

http://www.realtek.com.tw/Downloads/dow ... ByDesc=1#7

 

попробуйте добавить в загрузчике в syslinux.cfg в конце строки APPEND следующее:

rmmod=r8169

что позволит загрузить вместо драйвера r8169 более совместимый r8168

LABEL xpenology
      MENU LABEL XPEnology DSM 5.2-5644
      KERNEL /zImage
      APPEND root=/dev/md0 ihd_num=0 netif_num=4 syno_hw_version=DS3615xs sn=xx mac1=xx vid=0x0EA0 pid=0x2168 loglevel=0 vga=0x305 rmmod=r8169

 

Хотя в загрузчике все дрова есть, можно и в ручную установить с помощью флешки а заодно и MAC address поменять если надо

  1. На компьютере отформатировать USB флешку в файловую систему FAT32;
  2. Загрузите драйвер 8168 с RealTek веб-сайта: http://12244.wpc.azureedge.net/8012244/ ... 00.tar.bz2 и скопируйте файл "0005-r8168-8.042.00.tar.bz2" на USB флешку;
  3. Извлеките USB флешку и поместите её на XPEpenology NAS;
  4. В консоли исполняем следующие команды:
    server> cd /volumeUSB2/usbshare >> ваш путь к флешке, не путать с загрузчиком
    server> tar vjxf 0005-r8168-8.042.00.tar.bz2
    server> cd r8168-8.042.00
    server> ./autorun.sh
    

 

поменять MAC address


There are two ways to modify the MAC address of the NIC.
1. Use ifconfig:
              # ifconfig ethX hw ether YY:YY:YY:YY:YY:YY

   ,where X is the device number assigned by Linux kernel, and
	  YY:YY:YY:YY:YY:YY is the MAC address assigned by the user.

2. Use ip:
               # ip link set ethX address YY:YY:YY:YY:YY:YY

   ,where X is the device number assigned by Linux kernel, and
	  YY:YY:YY:YY:YY:YY is the MAC address assigned by the user.

 

[spoiler=]This is the Linux device driver released for RealTek RTL8168B/8111B, RTL8168C/8111C, RTL8168CP/8111CP, RTL8168D/8111D, RTL8168DP/8111DP, and RTL8168E/8111E Gigabit Ethernet controllers with PCI-Express interface.

 

 

- Kernel source tree (supported Linux kernel 2.6.x and 2.4.x)

- For linux kernel 2.4.x, this driver supports 2.4.20 and latter.

- Compiler/binutils for kernel compilation

 

Unpack the tarball :

# tar vjxf r8168-8.aaa.bb.tar.bz2

 

Change to the directory:

# cd r8168-8.aaa.bb

 

If you are running the target kernel, then you should be able to do :

 

# ./autorun.sh (as root or with sudo)

 

You can check whether the driver is loaded by using following commands.

 

# lsmod | grep r8168

# ifconfig -a

 

If there is a device name, ethX, shown on the monitor, the linux

driver is loaded. Then, you can use the following command to activate

the ethX.

 

# ifconfig ethX up

 

,where X=0,1,2,...

 

1. Set manually

a. Set the IP address of your machine.

 

# ifconfig ethX "the IP address of your machine"

 

b. Set the IP address of DNS.

 

Insert the following configuration in /etc/resolv.conf.

 

nameserver "the IP address of DNS"

 

c. Set the IP address of gateway.

 

# route add default gw "the IP address of gateway"

 

2. Set by doing configurations in /etc/sysconfig/network-scripts

/ifcfg-ethX for Redhat and Fedora, or /etc/sysconfig/network

/ifcfg-ethX for SuSE. There are two examples to set network

configurations.

 

a. Fixed IP address:

DEVICE=eth0

BOOTPROTO=static

ONBOOT=yes

TYPE=ethernet

NETMASK=255.255.255.0

IPADDR=192.168.1.1

GATEWAY=192.168.1.254

BROADCAST=192.168.1.255

 

b. DHCP:

DEVICE=eth0

BOOTPROTO=dhcp

ONBOOT=yes

 

There are two ways to modify the MAC address of the NIC.

1. Use ifconfig:

 

# ifconfig ethX hw ether YY:YY:YY:YY:YY:YY

 

,where X is the device number assigned by Linux kernel, and

YY:YY:YY:YY:YY:YY is the MAC address assigned by the user.

 

2. Use ip:

 

# ip link set ethX address YY:YY:YY:YY:YY:YY

 

,where X is the device number assigned by Linux kernel, and

YY:YY:YY:YY:YY:YY is the MAC address assigned by the user.

 

 

1. Force the link status when insert the driver.

 

If the user is in the path ~/r8168, the link status can be forced

to one of the 5 modes as following command.

 

# insmod ./src/r8168.ko speed=SPEED_MODE duplex=DUPLEX_MODE autoneg=NWAY_OPTION

 

,where

SPEED_MODE = 1000 for 1000Mbps

= 100 for 100Mbps

= 10 for 10Mbps

DUPLEX_MODE = 0 for half-duplex

= 1 for full-duplex

NWAY_OPTION = 0 for auto-negotiation off (true force)

= 1 for auto-negotiation on (nway force)

For example:

 

# insmod ./src/r8168.ko speed=100 duplex=0 autoneg=1

 

will force PHY to operate in 100Mpbs Half-duplex(nway force).

 

2. Force the link status by using ethtool.

a. Insert the driver first.

b. Make sure that ethtool exists in /sbin.

c. Force the link status as the following command.

 

# ethtool -s ethX speed SPEED_MODE duplex DUPLEX_MODE autoneg NWAY_OPTION

 

,where

SPEED_MODE = 1000 for 1000Mbps

= 100 for 100Mbps

= 10 for 10Mbps

DUPLEX_MODE = half for half-duplex

= full for full-duplex

NWAY_OPTION = off for auto-negotiation off (true force)

= on for auto-negotiation on (nway force)

 

For example:

 

# ethtool -s eth0 speed 100 duplex full autoneg on

 

will force PHY to operate in 100Mpbs Full-duplex(nway force).

 

Transmitting Jumbo Frames, whose packet size is bigger than 1500 bytes, please change mtu by the following command.

 

# ifconfig ethX mtu MTU

 

, where X=0,1,2,..., and MTU is configured by user.

 

RTL8168B/8111B supports Jumbo Frame size up to 4 kBytes.

RTL8168C/8111C and RTL8168CP/8111CP support Jumbo Frame size up to 6 kBytes.

RTL8168D/8111D supports Jumbo Frame size up to 9 kBytes.

 

 

viewtopic.php?f=2&t=6844&start=10#p41797

Link to comment
Share on other sites

Хотя в загрузчике все дрова есть, можно и в ручную установить с помощью флешки а заодно и MAC address поменять если надо

 

Не прокатило - мэйка нету...

 

TerbsDS> cd /tmp/rtl/
TerbsDS> ls
0005-r8168-8.042.00.tar.bz2
TerbsDS> tar vjxf 0005-r8168-8.042.00.tar.bz2
r8168-8.042.00/
r8168-8.042.00/autorun.sh
r8168-8.042.00/Makefile
r8168-8.042.00/README
r8168-8.042.00/src/
r8168-8.042.00/src/Makefile
r8168-8.042.00/src/Makefile_linux24x
r8168-8.042.00/src/r8168.h
r8168-8.042.00/src/r8168_asf.c
r8168-8.042.00/src/r8168_asf.h
r8168-8.042.00/src/r8168_dash.h
r8168-8.042.00/src/r8168_n.c
r8168-8.042.00/src/r8168_realwow.h
r8168-8.042.00/src/rtltool.c
r8168-8.042.00/src/rtltool.h
r8168-8.042.00/src/rtl_eeprom.c
r8168-8.042.00/src/rtl_eeprom.h
TerbsDS> ls
0005-r8168-8.042.00.tar.bz2  r8168-8.042.00
TerbsDS> cd r8168-8.042.00/
TerbsDS> ls
Makefile    README      autorun.sh  src
TerbsDS> ./autorun.sh
find: /lib/modules/3.10.35/kernel/drivers/net/ethernet: No such file or directory
find: /lib/modules/3.10.35/kernel/drivers/net: No such file or directory

Check old driver and unload it.
Build the module and install
./autorun.sh: line 30: make: not found
TerbsDS>

Дёргать флэшку проблематично т.к. игла в яйце, а яйцо в утке... Всмысле флэка компактфлэшная и стоит внутри в cf-to-ide адапрете. Но если не найдётся способа сделать всё удалённо то, чуствую, придётся...

Link to comment
Share on other sites

"Check old driver and unload it."

у вас не сработал:

check=`lsmod | grep r8169`
if [ "$check" != "" ]; then
       echo "rmmod r8169"
       /sbin/rmmod r8169
fi

check=`lsmod | grep r8168`
if [ "$check" != "" ]; then
       echo "rmmod r8168"
       /sbin/rmmod r8168
fi

должно было быть

rmmod r8169
rmmod r8168

 

проверьте

lsmod | grep r8168

 

путь не правильный

PATH=$(find /lib/modules/$(uname -r)/kernel/drivers/net -name realtek -type d)

[spoiler=autorun.sh]#!/bin/sh

 

# invoke insmod with all arguments we got

# and use a pathname, as insmod doesn't look in . by default

 

TARGET_PATH=$(find /lib/modules/$(uname -r)/kernel/drivers/net/ethernet -name realtek -type d)

if [ "$TARGET_PATH" = "" ]; then

TARGET_PATH=$(find /lib/modules/$(uname -r)/kernel/drivers/net -name realtek -type d)

fi

if [ "$TARGET_PATH" = "" ]; then

TARGET_PATH=/lib/modules/$(uname -r)/kernel/drivers/net

fi

echo

echo "Check old driver and unload it."

check=`lsmod | grep r8169`

if [ "$check" != "" ]; then

echo "rmmod r8169"

/sbin/rmmod r8169

fi

 

check=`lsmod | grep r8168`

if [ "$check" != "" ]; then

echo "rmmod r8168"

/sbin/rmmod r8168

fi

 

echo "Build the module and install"

echo "-------------------------------" >> log.txt

date 1>>log.txt

make $@ all 1>>log.txt || exit 1

module=`ls src/*.ko`

module=${module#src/}

module=${module%.ko}

 

if [ "$module" = "" ]; then

echo "No driver exists!!!"

exit 1

elif [ "$module" != "r8169" ]; then

if test -e $TARGET_PATH/r8169.ko ; then

echo "Backup r8169.ko"

if test -e $TARGET_PATH/r8169.bak ; then

i=0

while test -e $TARGET_PATH/r8169.bak$i

do

i=$(($i+1))

done

echo "rename r8169.ko to r8169.bak$i"

mv $TARGET_PATH/r8169.ko $TARGET_PATH/r8169.bak$i

else

echo "rename r8169.ko to r8169.bak"

mv $TARGET_PATH/r8169.ko $TARGET_PATH/r8169.bak

fi

fi

fi

 

echo "DEPMOD $(uname -r)"

depmod `uname -r`

echo "load module $module"

modprobe $module

 

is_update_initramfs=n

distrib_list="ubuntu debian"

 

if [ -r /etc/debian_version ]; then

is_update_initramfs=y

elif [ -r /etc/lsb-release ]; then

for distrib in $distrib_list

do

/bin/grep -i "$distrib" /etc/lsb-release 2>&1 /dev/null && \

is_update_initramfs=y && break

done

fi

 

if [ "$is_update_initramfs" = "y" ]; then

if which update-initramfs >/dev/null ; then

echo "Updating initramfs. Please wait."

update-initramfs -u -k $(uname -r)

else

echo "update-initramfs: command not found"

exit 1

fi

fi

 

echo "Completed."

exit 0

 

 

короче забейте на эти дрова от реалтека специально для линукса и установку так так как она всё равно устанавливает r8169 который хуже чем универсальный r8168

загрузчик прекрасно и сам подгружает дрова в том числе и r8168

Link to comment
Share on other sites

проверьте

lsmod | grep r8168

"lsmod | grep r8168" - пусто, "lsmod | grep r8169" - тоже пусто

 

короче забейте на эти дрова от реалтека специально для линукса и установку так так как она всё равно устанавливает r8169 который хуже чем универсальный r8168

загрузчик прекрасно и сам подгружает дрова в том числе и r8168

Так ведь не подгружает - в ifconfig-е нету сетевухи и в dmesg-е тишина....

Link to comment
Share on other sites

Извиняюсь - мой косяк!

Посмотрел lspci - а там сетевухи тоже нету - значит сервак её не видит физически. Переткнул в соседний разъём - заработало. Видимо контакт плохой был - разъём PCI-E x1 в который отродясь ничего не вставлялось - может пыль попала или окислился.

Спасибо всем кто откликнулся! :grin:

Link to comment
Share on other sites

Извиняюсь - мой косяк!

Посмотрел lspci - а там сетевухи тоже нету - значит сервак её не видит физически. Переткнул в соседний разъём - заработало. Видимо контакт плохой был - разъём PCI-E x1 в который отродясь ничего не вставлялось - может пыль попала или окислился.

Спасибо всем кто откликнулся! :grin:

жесть :lol:

Link to comment
Share on other sites

×
×
  • Create New...