debian之raid和网卡驱动的编译及安装

编译raid驱动:

1. root用户

2. apt-get install build-essential ; apt-get install libncurses5 ; apt-get install libncurses5-dev

3. apt-get install linux-headers-2.6.26-2-amd64

4. cd /usr/src ; ln -s  linux-headers-2.6.26-2-amd64 linux

5. mkdir v00.00.05.30 ; tar zxvf megaraid_sas-v00.00.05.30-src.tgz -C v00.00.05.30

6. make -C /lib/modules/2.6.26-2-amd64/build/ M=`pwd`

7. cp megaraid_sas.ko /lib/modules/2.6.26-2-amd64/kernel/drivers/scsi/megaraid


编译tg3驱动:

1. cd /usr/src ; apt-get install linux-source-2.6.26

2. tar xvf linux-source-2.6.26.tar.bz2

3. tar xvf tg3-3.133d.tar.gz ; cd tg3-3.133d/

4. makeflags.sh ./linux-source-2.6.26/ ; make -C /lib/modules/2.6.26-2-amd64/build/ M=`pwd`

5. cp tg3.ko /lib/modules/2.6.26-2-amd64/kernel/drivers/net/

6  cd /boot/ ; mkinitramfs -o initrd.img-2.6.26-2-amd64


系统安装:

1.  Copy megaraid_sas.ko ; tg3.ko ; initrd.img-2.6.26-2-amd64 to an USB-key

2.  Detect disks said "No disk drive was detected"

3.  Insert your USB-key, select for <Go back>, press enter on Detect disks

4.  Press ALT+F2. exit to console

5.  fdisk -l ; /dev/sda1

6.  mkdir /mnt2 ; mount /dev/sda1 /mnt2

7.  cp megaraid_sas.ko /lib/modules/2.6.26-2-amd64/kernel/drivers/scsi/megaraid -f

8. cp tg3.ko /lib/modules/2.6.26-2-amd64/kernel/drivers/net/ -f

9.  cp /mnt2/initrd.img-2.6.26-2-amd64 /etc

10. umount /dev/sda1 and remove your USB-key from the installation system

11. Press ALT+F1 ; select "Go back" ; select "Detect disks" press enter

12. DO NOT REBOOT after Debian is done. Exit to console again (ALT+F2)

13. cp -f /etc/initrd.img-2.6.26-2-amd64  /target/boot/initrd.img-2.6.26-2-amd64

14. ALT+F1 ; reboot ; finished.

你可能感兴趣的:(Debian,raid驱动,网卡tg3)