View unanswered posts | View active topics It is currently Fri Aug 22, 2014 1:49 am



Reply to topic  [ 113 posts ]  Go to page 1, 2, 3, 4, 5 ... 12  Next
 RTL8111/8168 and P55 integr. SATA Ctrl. (AHCI) for ESX 4 
Author Message

Joined: Sun Oct 04, 2009 2:47 pm
Posts: 4
Post RTL8111/8168 and P55 integr. SATA Ctrl. (AHCI) for ESX 4
If you don't want the story: There is an oem.tgz with ESX 4 support for the Realtek RTL8111/8168 chipset and the P55 integrated SATA controller in AHCI mode attached to this post.

I have a nice new toy with a Gigabyte GA-P55M-UD2 motherboard. Unfortunately ESXi 4.0 doesn't support it out of the box. The GigE chipset Realtek RTL8111 ( PCI-ID: 10ec:8168 ) leaves you with the famous "Failed to load lvmdriver" error. Also my SATA controller running in AHCI mode ( PCI-ID: 8086:3b22 ) integrated in the Intel P55 chipset for the new LGA1156 Core i5 and Core i7 CPU's is not recognized.

The principle way to enable support in ESX for new devices is described here:

http://www.vm-help.com/esx40i/customize_oem_tgz.php

That leaves you with the question where to get the proper device drivers ?

Luckily I found this post:

http://www.kernelcrash.com/blog/using-a ... 009/08/22/

So I followed the procedure and downloaded the ESX Open Source distribution from VMware and the latest r8168 Linux device driver package from Realtek's website ( version 8.014.00 ). With some minor modifications the r8168 driver did really compile without errors and was successfully loaded by ESX...

...just to leave me with an ESX Hypervisor without a datastore.

ESX didn't see the SATA controller even that I had entered the PCI-ID for it in the simple.map file, directing it to the ahci.o driver.

OK, good to have the sources. Taking a look into ahci.c showed that 3b22 was not listed in the pci_device_id structure. Well, I'm not an expert on Linux device drivers and I hope my simple hack doesn't wait with some later surprise but I simply added this value to ahci_pci_tbl. Crosschecking with the ahci.c version for Linux 2.6.31 on
http://lxr.linux.no/#linux+v2.6.31/drivers/ata/ahci.c#L486 showed it there. Hopefully no special code to support it went into ahci.c between 2.6.18 and 2.6.31 but at least I didn't find any other reference to it.

Compilation of ahci.o went like a charm and adding it to the oem.tgz made my baby work with ESXi 4.0 !


Attachments:
File comment: Changed the name of the file so when ppl download the file they know witch feature it has. //Varazir
RTL8111_8168_P55_integr_SATA_Ctrl.(AHCI).oem.tgz [187.13 KiB]
Downloaded 30891 times
Tue Oct 13, 2009 1:21 pm
Profile

Joined: Mon May 18, 2009 6:13 am
Posts: 49
Post Re: RTL8111/8168 and P55 integr. SATA Ctrl. (AHCI) for ESX 4
Hello
Thanks for sharing, I have same NIC but different SATA Controller.
I will try to compile driver for 2 NICs and 1 Controller and if I get the answer, I will post them here.


Wed Oct 14, 2009 11:35 pm
Profile

Joined: Sat Oct 17, 2009 5:27 am
Posts: 25
Post Re: RTL8111/8168 and P55 integr. SATA Ctrl. (AHCI) for ESX 4
Thank you geppi!

Great job indeed!

I can confirm that the Realtek driver is working! :D

/usr/lib/vmware/vmkmod # cat /etc/vmware/simple.map| grep r8168
10ec:8168 0000:0000 network r8168.o

/usr/lib/vmware/vmkmod # vmkload_mod -l -b | grep r8168
r8168 61440 0

/usr/lib/vmware/vmkmod # ethtool vmnic32
Settings for vmnic32:
Supported ports: [ TP ]
Supported link modes: 10baseT/Half 10baseT/Full
100baseT/Half 100baseT/Full
1000baseT/Full
Supports auto-negotiation: Yes
Advertised link modes: 10baseT/Half 10baseT/Full
100baseT/Half 100baseT/Full
1000baseT/Full
Advertised auto-negotiation: Yes
Speed: 100Mb/s
Duplex: Full
Port: Twisted Pair
PHYAD: 0
Transceiver: internal
Auto-negotiation: on
Supports Wake-on: pumbg
Wake-on: g
Current message level: 0x00000033 (51)
Link detected: yes

Transceiver: internal
Auto-negotiation: on
Supports Wake-on: pumbg
Wake-on: g
Current message level: 0x00000033 (51)
Link detected: yes

My config is the following:
Mobo : Gigabyte MA790GP-UD4H
CPU : Phenom II X4 940
PSU : Chieftec 450W
Case : Gigabyte GZ-X6 Black
SATA HDDs(in AHCI mode) + SATA DVD writer : LG GH22NS50
8 GB DDR2 RAM(Geil Black Dragon DDR2 Gaming Series)
LAN : Intel EXPI9301CTBLK CT + onboard Realtek

_________________
VCP4


Sat Oct 17, 2009 5:31 am
Profile

Joined: Thu May 14, 2009 12:23 am
Posts: 9
Post Re: RTL8111/8168 and P55 integr. SATA Ctrl. (AHCI) for ESX 4
Thanks for driver!

Driver is working on my Asus P5B but there are some problems using this NIC on VM with windows installed.
During downloading large files to VM via Remote Desktop connection realtek adapter hung up. I need to disconnect cable or unload/load driver.
To make ftp connection Tx option for 'TCP Checksum Offload (IPv4)' in NIC advanced settings tab must be disabled. (default: Tx and Rx are enabled for VMXNET 3 adapter type).

frutis


Mon Oct 19, 2009 12:45 am
Profile

Joined: Tue Oct 13, 2009 10:57 pm
Posts: 12
Post Re: RTL8111/8168 and P55 integr. SATA Ctrl. (AHCI) for ESX 4
dear geppi,
please instruct me step by step to build your tgz file. Because i need to build some other driver.
Thanks so much


Tue Oct 20, 2009 8:15 am
Profile

Joined: Wed Mar 18, 2009 1:32 pm
Posts: 455
Location: Sweden
Post Re: RTL8111/8168 and P55 integr. SATA Ctrl. (AHCI) for ESX 4
doccocaubai wrote:
dear geppi,
please instruct me step by step to build your tgz file. Because i need to build some other driver.
Thanks so much


Do you need to add more files or just edit the files ?

If you just going to edit the files you can use my script, but then you need a linux system and English prefer.

Rgd Daniel

_________________
Dovie'andi se tovya sagain,



Tue Oct 20, 2009 9:12 am
Profile WWW

Joined: Tue Oct 20, 2009 12:37 pm
Posts: 4
Post Re: RTL8111/8168 and P55 integr. SATA Ctrl. (AHCI) for ESX 4
Hi, thank you for your good work as I have been waiting for rtl8168 driver for a long time.
Nevertheless, the first attempt to use this deiver failed. First I copied simple.map, pci.ids and r8168.o from the distribution to /etc/vmware/ and /usr/lib/vmware/vmkmod/ Then I tried to load rt8168 in a running system with vmkload_mod -v 16 r8168 and system seems to load it (at least vmkload_mod -l -b | grep r8168 gives me the following: r8168 61440 0). However, when I check nics available in the system with esxcfg-nics -l command, there are no new nics related to this driver. And when I tried to reboot system, it doesn't load driver at boot time. I have MSI MS7577 M/b with Phenom II X4 945 processor. lspci -v gives me the following related to this nic:

06:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. Unknown device 8168 (rev 03)
Subsystem: Micro-Star International Co., Ltd. Unknown device 7577
Flags: bus master, fast devsel, latency 0, IRQ 17
I/O ports at 9800 [size=256]
Memory at fdeff000 (64-bit, prefetchable) [size=4K]
Memory at fdef8000 (64-bit, prefetchable) [size=16K]
Expansion ROM at fe7e0000 [disabled] [size=128K]
Capabilities: [40] Power Management version 3
Capabilities: [50] Message Signalled Interrupts: 64bit+ Queue=0/0 Enable-
Capabilities: [70] Express Endpoint IRQ 1
Capabilities: [ac] MSI-X: Enable- Mask- TabSize=4
Capabilities: [cc] Vital Product Data

07:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. Unknown device 8168 (rev 03)
Subsystem: Micro-Star International Co., Ltd. Unknown device 7577
Flags: bus master, fast devsel, latency 0, IRQ 18
I/O ports at a800 [size=256]
Memory at fdfff000 (64-bit, prefetchable) [size=4K]
Memory at fdff8000 (64-bit, prefetchable) [size=16K]
Expansion ROM at fe8e0000 [disabled] [size=128K]
Capabilities: [40] Power Management version 3
Capabilities: [50] Message Signalled Interrupts: 64bit+ Queue=0/0 Enable-
Capabilities: [70] Express Endpoint IRQ 1
Capabilities: [ac] MSI-X: Enable- Mask- TabSize=4
Capabilities: [cc] Vital Product Data

lspci -nv gives me the following:

06:00.0 0200: 10ec:8168 (rev 03)
Subsystem: 1462:7577
Flags: bus master, fast devsel, latency 0, IRQ 17
I/O ports at 9800 [size=256]
Memory at fdeff000 (64-bit, prefetchable) [size=4K]
Memory at fdef8000 (64-bit, prefetchable) [size=16K]
Expansion ROM at fe7e0000 [disabled] [size=128K]
Capabilities: [40] Power Management version 3
Capabilities: [50] Message Signalled Interrupts: 64bit+ Queue=0/0 Enable-
Capabilities: [70] Express Endpoint IRQ 1
Capabilities: [ac] MSI-X: Enable- Mask- TabSize=4
Capabilities: [cc] Vital Product Data

07:00.0 0200: 10ec:8168 (rev 03)
Subsystem: 1462:7577
Flags: bus master, fast devsel, latency 0, IRQ 18
I/O ports at a800 [size=256]
Memory at fdfff000 (64-bit, prefetchable) [size=4K]
Memory at fdff8000 (64-bit, prefetchable) [size=16K]
Expansion ROM at fe8e0000 [disabled] [size=128K]
Capabilities: [40] Power Management version 3
Capabilities: [50] Message Signalled Interrupts: 64bit+ Queue=0/0 Enable-
Capabilities: [70] Express Endpoint IRQ 1
Capabilities: [ac] MSI-X: Enable- Mask- TabSize=4
Capabilities: [cc] Vital Product Data

The question is what should I do to enable this nic in already installed system as I don't want to reinstall it?



Thank you, Dmitry


Tue Oct 20, 2009 2:23 pm
Profile
Site Admin

Joined: Mon Mar 16, 2009 10:13 pm
Posts: 3880
Post Re: RTL8111/8168 and P55 integr. SATA Ctrl. (AHCI) for ESX 4
If you copy the driver and then manually load it, it should work fine on an installed system (at least until you reboot it).

Can you post the output of /var/log/messages after you run vmkload_mod - you should see a section that deals with what happens when the driver tries to load.

_________________
Dave Mishchenko
VMware vExpert 2009-2013
Image
Now available - VMware ESXi: Planning, Implementation, and Security
Also available - vSphere Quick Start Guide


Tue Oct 20, 2009 2:40 pm
Profile

Joined: Tue Oct 13, 2009 10:57 pm
Posts: 12
Post Re: RTL8111/8168 and P55 integr. SATA Ctrl. (AHCI) for ESX 4
Varazir wrote:
doccocaubai wrote:
dear geppi,
please instruct me step by step to build your tgz file. Because i need to build some other driver.
Thanks so much


Do you need to add more files or just edit the files ?

If you just going to edit the files you can use my script, but then you need a linux system and English prefer.

Rgd Daniel

Dear Varazir, I need more files. Because I need to build the driver for my 82559ER NIC.


Tue Oct 20, 2009 10:26 pm
Profile

Joined: Tue Oct 20, 2009 12:37 pm
Posts: 4
Post Re: RTL8111/8168 and P55 integr. SATA Ctrl. (AHCI) for ESX 4
Hi, Dave,

This is what is related to driver loading from /var/log/vmkernel as there is nothing special in /var/log/messages:

Oct 21 10:24:55 localhost vmkernel: 18:00:01:57.436 cpu3:4107)PCI: driver r8168 is looking for devices
Oct 21 10:24:55 localhost vmkernel: 18:00:01:57.436 cpu3:4107)PCI: Trying 0000:00:12.0
Oct 21 10:24:55 localhost vmkernel: 18:00:01:57.436 cpu3:4107)PCI: Trying 0000:00:12.1
Oct 21 10:24:55 localhost vmkernel: 18:00:01:57.436 cpu3:4107)PCI: Trying 0000:00:12.2
Oct 21 10:24:55 localhost vmkernel: 18:00:01:57.436 cpu3:4107)PCI: Trying 0000:00:13.0
Oct 21 10:24:55 localhost vmkernel: 18:00:01:57.436 cpu3:4107)PCI: Trying 0000:00:13.1
Oct 21 10:24:55 localhost vmkernel: 18:00:01:57.436 cpu3:4107)PCI: Trying 0000:00:13.2
Oct 21 10:24:55 localhost vmkernel: 18:00:01:57.436 cpu3:4107)PCI: Trying 0000:00:14.5
Oct 21 10:24:55 localhost vmkernel: 18:00:01:57.436 cpu3:4107)PCI: Trying 0000:00:11.0
Oct 21 10:24:55 localhost vmkernel: 18:00:01:57.436 cpu3:4107)PCI: Trying 0000:00:14.1
Oct 21 10:24:55 localhost vmkernel: 18:00:01:57.436 cpu3:4107)PCI: Trying 0000:04:00.0
Oct 21 10:24:55 localhost vmkernel: 18:00:01:57.436 cpu3:4107)PCI: Trying 0000:04:00.1
Oct 21 10:24:55 localhost vmkernel: 18:00:01:57.436 cpu3:4107)PCI: Trying 0000:05:00.0
Oct 21 10:24:55 localhost vmkernel: 18:00:01:57.436 cpu3:4107)PCI: Trying 0000:05:00.1
Oct 21 10:24:55 localhost vmkernel: 18:00:01:57.436 cpu3:4107)PCI: Trying 0000:09:00.1
Oct 21 10:24:55 localhost vmkernel: 18:00:01:57.436 cpu3:4107)PCI: Announcing 0000:09:00.1
Oct 21 10:24:55 localhost vmkernel: 18:00:01:57.436 cpu3:4107)PCI: Trying 0000:0a:00.0
Oct 21 10:24:55 localhost vmkernel: 18:00:01:57.436 cpu3:4107)PCI: Trying 0000:0a:00.1
Oct 21 10:24:55 localhost vmkernel: 18:00:01:57.436 cpu3:4107)PCI: driver r8168 claimed 0 device
Oct 21 10:24:55 localhost vmkernel: 18:00:01:57.436 cpu3:4107)Mod: 2892: Initialization for r8168 succeeded with module ID 56.
Oct 21 10:24:55 localhost vmkernel: 18:00:01:57.436 cpu3:4107)r8168 loaded successfully.


Best Regards, Dmitry


Tue Oct 20, 2009 10:36 pm
Profile
Display posts from previous:  Sort by  
Reply to topic   [ 113 posts ]  Go to page 1, 2, 3, 4, 5 ... 12  Next

Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by STSoftware for PTF.