(these steps are assuming that your core doesn't need the r8169 driver
First, go to realtek.com.tw/downloads/downloadsView.aspx?Langid=1&PNid=13&PFid=5&Level=5&Conn=4&DownTypeID=3&GetDown=false#2 and download the 8.020.00 driver source (dated 11/15/2010). Then transfer this file to / on your core.
(or, use wget on the core directly to download the file, I found it hosted on google code:
wget r8168.googlecode.com/files/r8168-8.020.00.tar.bz2)
Next, ssh into the core:
- Become super user
sudo su
Check whether the built-in driver, r8169.ko is installed.
lsmod | grep r8169
If it is installed (the command above will give you an indication), you will have to follow the r8168 wiki to download the kernel sources and apply a patch. Otherwise, continue on...
- Lets go to the driver source you placed in /
cd /
- Extract the sources, then cd into the source folder
tar -jxf r8168-8.020.00.tar.bz2
cd r8168-8.020.00
- Compile the sources
make
The makefile SHOULD automatically put the driver file in the right place:
/lib/modules/2.6.22-14-generic/kernel/drivers/net/r8168.ko
if not, copy it over yourself:
cp ./r8168.ko /lib/modules/2.6.22-14-generic/kernel/drivers/net/r8168.ko
- Install the driver module
add a new line at the bottom of /etc/initramfs-tools-interactor/modules, then save:
vim /etc/initramfs-tools-interactor/modules
add the following line at the bottom:
r8168
then exit vim (:wq)
- Remove the r8169 module, we won't need it
rm /lib/modules/2.6.22-14-generic/kernel/drivers/net/r8169.ko
make install
depmod -a
modprobe r8168
- Make the MD ramdisk boot image
/usr/pluto/bin/Diskless_BuildDefaultImage.sh
Now you should be able to boot the MD - you'll know its working when you see "We have announced ourselves to the router" and the diskless setup runs (you should also at this time see a new Media Director in the web admin).
When the diskless setup is finished, the MD will reboot - but again it will fail with a kernel panic (the new diskless filesystem does not yet have the r8168 module, so lets fix that by copying it over from the root file system)...
cp /lib/modules/2.6.22-14-generic/kernel/drivers/net/r8168.ko /usr/pluto/diskless/<MD#>/lib/modules/2.6.22-14-generic/kernel/drivers/net/r8168.ko
(make sure you replace <MD#> with the device number of your new MD - you can see this in the web admin)
(also note that your kernel version in the path could be different, change it as needed for your installation)
You need to activate the module in 2 places now, using vim:
vim /usr/pluto/diskless/<MD#>/etc/modules
and
vim /usr/pluto/diskless/<MD#>/etc/initramfs-tools/modules
(Again, replace <MD#> with your actual MD device number)
add the following to the end of both above files:
r8168
-And also remove the r8169 driver from the MD's boot files
rm /usr/pluto/diskless/<MD#>/lib/modules/2.6.22-14-generic/kernel/drivers/net/r8168.ko
Now just recreate the ramdisk IN THE MD (via chroot)
cd /usr/pluto/diskless/
chroot <MD#>
depmod
cd /boot
mkinitramfs -o initrd.img-`uname -r` `uname -r`
exit
Finally, lets clean up our mess from building the driver:
rm -r /r8168-8.020.00
rm /r8168-8.020.00.tar.bz2
Now reboot, and you should come up to the A/V wizard and you're done