<?xml version="1.0" encoding="UTF-8" ?>
<rss version="2.0">
<channel>
<title><![CDATA[BIWEB开源PHP WMS系统创始人ArthurXF肖飞的blog]]></title> 
<link>http://www.bizeway.net/index.php</link> 
<description><![CDATA[网务通 - 网务公司发展之路]]></description> 
<language>zh-cn</language> 
<copyright><![CDATA[BIWEB开源PHP WMS系统创始人ArthurXF肖飞的blog]]></copyright>
<item>
<link>http://www.bizeway.net/read.php?</link>
<title><![CDATA[跟着ArthurXF学FreeBSD2——给FreeBSD一个优化的新内核]]></title> 
<author>ArthurXF &lt;arthurxf@gmail.com&gt;</author>
<category><![CDATA[FreeBSD]]></category>
<pubDate>Thu, 18 Jan 2007 08:42:41 +0000</pubDate> 
<guid>http://www.bizeway.net/read.php?</guid> 
<description>
<![CDATA[ 
	　　FreeBSD安装好了以后呢，因为FreeBSD默认配置要支持很多的设备，要兼容各种设备管理啊，这样就启动了很多的驱动程序等等，这些东西我们都一般服务器配置好之后很多都用不到，而FreeBSD每次都要加载它们，这样FreeBSD启动慢，而且还占用资源，所以我们现在来重新配置FreeBSD的内核，去掉我们用不到的东西，这样我们就可以很快启动FreeBSD系统了。那么让我们开始：<br/>cd /usr/src/sys/i386/conf <br/>cp GENERIC ArthurXF <br/>vi ArthurXF<br/>大家自己选择一些要用到的设备，如果不用的就用#号注释掉，我把我的配置放出来仅供参考。<br/>需要注意的是ident &nbsp; &nbsp;ArthurXF ，必须和你的内核文件名一致。<br/><div class="quote"><div class="quote-title">引用</div><div class="quote-content">#<br/># GENERIC -- Generic kernel configuration file for FreeBSD/i386<br/>#<br/># For more information on this file, please read the handbook section on<br/># Kernel Configuration Files:<br/>#<br/># &nbsp; &nbsp;http://www.FreeBSD.org/doc/en_US.ISO8859-1/books/handbook/kernelconfig-config.html<br/>#<br/># The handbook is also available locally in /usr/share/doc/handbook<br/># if you've installed the doc distribution, otherwise always see the<br/># FreeBSD World Wide Web server (http://www.FreeBSD.org/) for the<br/># latest information.<br/>#<br/># An exhaustive list of options and more detailed explanations of the<br/># device lines is also present in the ../../conf/NOTES and NOTES files.<br/># If you are in doubt as to the purpose or necessity of a line, check first<br/># in NOTES.<br/>#<br/># $FreeBSD: src/sys/i386/conf/GENERIC,v 1.429.2.7.2.2 2006/05/01 00:15:12 scottl Exp $<br/><br/>machine &nbsp; &nbsp;i386<br/>cpu &nbsp; &nbsp;I486_CPU<br/>cpu &nbsp; &nbsp;I586_CPU<br/>cpu &nbsp; &nbsp;I686_CPU<br/>ident &nbsp; &nbsp;ArthurXF<br/><br/># To statically compile in device wiring instead of /boot/device.hints<br/>#hints &nbsp; &nbsp;"GENERIC.hints" &nbsp; &nbsp;# Default places to look for devices.<br/><br/>makeoptions &nbsp;DEBUG=-g &nbsp; &nbsp;# Build kernel with gdb(1) debug symbols<br/><br/>#options &nbsp; SCHED_ULE &nbsp; &nbsp;# ULE scheduler<br/>options &nbsp; SCHED_4BSD &nbsp; &nbsp;# 4BSD scheduler<br/>options &nbsp; PREEMPTION &nbsp; &nbsp;# Enable kernel thread preemption<br/>options &nbsp; INET &nbsp; &nbsp; &nbsp;# InterNETworking<br/>options &nbsp; INET6 &nbsp; &nbsp; &nbsp;# IPv6 communications protocols<br/>options &nbsp; FFS &nbsp; &nbsp; &nbsp;# Berkeley Fast Filesystem<br/>options &nbsp; SOFTUPDATES &nbsp; &nbsp;# Enable FFS soft updates support<br/>options &nbsp; UFS_ACL &nbsp; &nbsp; &nbsp;# Support for access control lists<br/>options &nbsp; UFS_DIRHASH &nbsp; &nbsp;# Improve performance on big directories<br/>options &nbsp; MD_ROOT &nbsp; &nbsp; &nbsp;# MD is a potential root device<br/>options &nbsp; NFSCLIENT &nbsp; &nbsp;# Network Filesystem Client<br/>options &nbsp; NFSSERVER &nbsp; &nbsp;# Network Filesystem Server<br/>options &nbsp; NFS_ROOT &nbsp; &nbsp;# NFS usable as /, requires NFSCLIENT<br/>options &nbsp; MSDOSFS &nbsp; &nbsp; &nbsp;# MSDOS Filesystem<br/>#options &nbsp; CD9660 &nbsp; &nbsp; &nbsp;# ISO 9660 Filesystem<br/>options &nbsp; PROCFS &nbsp; &nbsp; &nbsp;# Process filesystem (requires PSEUDOFS)<br/>options &nbsp; PSEUDOFS &nbsp; &nbsp;# Pseudo-filesystem framework<br/>options &nbsp; GEOM_GPT &nbsp; &nbsp;# GUID Partition Tables.<br/>options &nbsp; COMPAT_43 &nbsp; &nbsp;# Compatible with BSD 4.3 [KEEP THIS!]<br/>options &nbsp; COMPAT_FREEBSD4 &nbsp; &nbsp;# Compatible with FreeBSD4<br/>options &nbsp; COMPAT_FREEBSD5 &nbsp; &nbsp;# Compatible with FreeBSD5<br/>options &nbsp; SCSI_DELAY=5000 &nbsp; &nbsp;# Delay (in ms) before probing SCSI<br/>options &nbsp; KTRACE &nbsp; &nbsp; &nbsp;# ktrace(1) support<br/>options &nbsp; SYSVSHM &nbsp; &nbsp; &nbsp;# SYSV-style shared memory<br/>options &nbsp; SYSVMSG &nbsp; &nbsp; &nbsp;# SYSV-style message queues<br/>options &nbsp; SYSVSEM &nbsp; &nbsp; &nbsp;# SYSV-style semaphores<br/>options &nbsp; _KPOSIX_PRIORITY_SCHEDULING # POSIX P1003_1B real-time extensions<br/>options &nbsp; KBD_INSTALL_CDEV &nbsp;# install a CDEV entry in /dev<br/>options &nbsp; AHC_REG_PRETTY_PRINT &nbsp;# Print register bitfields in debug<br/> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;# output. &nbsp;Adds ~128k to driver.<br/>options &nbsp; AHD_REG_PRETTY_PRINT &nbsp;# Print register bitfields in debug<br/> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;# output. &nbsp;Adds ~215k to driver.<br/>options &nbsp; ADAPTIVE_GIANT &nbsp; &nbsp;# Giant mutex is adaptive.<br/><br/>device &nbsp; &nbsp;apic &nbsp; &nbsp; &nbsp;# I/O APIC<br/><br/># Bus support.<br/>device &nbsp; &nbsp;eisa<br/>device &nbsp; &nbsp;pci<br/><br/># Floppy drives<br/>#device &nbsp; &nbsp;fdc<br/><br/># ATA and ATAPI devices<br/>device &nbsp; &nbsp;ata<br/>device &nbsp; &nbsp;atadisk &nbsp; &nbsp;# ATA disk drives<br/>device &nbsp; &nbsp;ataraid &nbsp; &nbsp;# ATA RAID drives<br/>device &nbsp; &nbsp;atapicd &nbsp; &nbsp;# ATAPI CDROM drives<br/>device &nbsp; &nbsp;atapifd &nbsp; &nbsp;# ATAPI floppy drives<br/>device &nbsp; &nbsp;atapist &nbsp; &nbsp;# ATAPI tape drives<br/>options &nbsp; ATA_STATIC_ID &nbsp;# Static device numbering<br/><br/># SCSI Controllers<br/>#device &nbsp; &nbsp;ahb &nbsp; &nbsp;# EISA AHA1742 family<br/>#device &nbsp; &nbsp;ahc &nbsp; &nbsp;# AHA2940 and onboard AIC7xxx devices<br/>#device &nbsp; &nbsp;ahd &nbsp; &nbsp;# AHA39320/29320 and onboard AIC79xx devices<br/>#device &nbsp; &nbsp;amd &nbsp; &nbsp;# AMD 53C974 (Tekram DC-390(T))<br/>#device &nbsp; &nbsp;isp &nbsp; &nbsp;# Qlogic family<br/>#device &nbsp; ispfw &nbsp; &nbsp;# Firmware for QLogic HBAs- normally a module<br/>#device &nbsp; &nbsp;mpt &nbsp; &nbsp;# LSI-Logic MPT-Fusion<br/>#device &nbsp; &nbsp;ncr &nbsp; &nbsp;# NCR/Symbios Logic<br/>#device &nbsp; &nbsp;sym &nbsp; &nbsp;# NCR/Symbios Logic (newer chipsets + those of `ncr')<br/>#device &nbsp; &nbsp;trm &nbsp; &nbsp;# Tekram DC395U/UW/F DC315U adapters<br/><br/>#device &nbsp; &nbsp;adv &nbsp; &nbsp;# Advansys SCSI adapters<br/>#device &nbsp; &nbsp;adw &nbsp; &nbsp;# Advansys wide SCSI adapters<br/>#device &nbsp; &nbsp;aha &nbsp; &nbsp;# Adaptec 154x SCSI adapters<br/>#device &nbsp; &nbsp;aic &nbsp; &nbsp;# Adaptec 15[012]x SCSI adapters, AIC-6[23]60.<br/>#device &nbsp; &nbsp;bt &nbsp; &nbsp;# Buslogic/Mylex MultiMaster SCSI adapters<br/><br/>#device &nbsp; &nbsp;ncv &nbsp; &nbsp;# NCR 53C500<br/>#device &nbsp; &nbsp;nsp &nbsp; &nbsp;# Workbit Ninja SCSI-3<br/>#device &nbsp; &nbsp;stg &nbsp; &nbsp;# TMC 18C30/18C50<br/><br/># SCSI peripherals<br/>#device &nbsp; &nbsp;scbus &nbsp; &nbsp;# SCSI bus (required for SCSI)<br/>#device &nbsp; &nbsp;ch &nbsp; &nbsp;# SCSI media changers<br/>#device &nbsp; &nbsp;da &nbsp; &nbsp;# Direct Access (disks)<br/>#device &nbsp; &nbsp;sa &nbsp; &nbsp;# Sequential Access (tape etc)<br/>#device &nbsp; &nbsp;cd &nbsp; &nbsp;# CD<br/>#device &nbsp; &nbsp;pass &nbsp; &nbsp;# Passthrough device (direct SCSI access)<br/>#device &nbsp; &nbsp;ses &nbsp; &nbsp;# SCSI Environmental Services (and SAF-TE)<br/><br/># RAID controllers interfaced to the SCSI subsystem<br/>#device &nbsp; &nbsp;amr &nbsp; &nbsp;# AMI MegaRAID<br/>#device &nbsp; &nbsp;arcmsr &nbsp; &nbsp;# Areca SATA II RAID<br/>#device &nbsp; &nbsp;asr &nbsp; &nbsp;# DPT SmartRAID V, VI and Adaptec SCSI RAID<br/>#device &nbsp; &nbsp;ciss &nbsp; &nbsp;# Compaq Smart RAID 5*<br/>#device &nbsp; &nbsp;dpt &nbsp; &nbsp;# DPT Smartcache III, IV - See NOTES for options<br/>#device &nbsp; &nbsp;hptmv &nbsp; &nbsp;# Highpoint RocketRAID 182x<br/>#device &nbsp; &nbsp;rr232x &nbsp; &nbsp;# Highpoint RocketRAID 232x<br/>#device &nbsp; &nbsp;iir &nbsp; &nbsp;# Intel Integrated RAID<br/>#device &nbsp; &nbsp;ips &nbsp; &nbsp;# IBM (Adaptec) ServeRAID<br/>#device &nbsp; &nbsp;mly &nbsp; &nbsp;# Mylex AcceleRAID/eXtremeRAID<br/>#device &nbsp; &nbsp;twa &nbsp; &nbsp;# 3ware 9000 series PATA/SATA RAID<br/><br/># RAID controllers<br/>#device &nbsp; &nbsp;aac &nbsp; &nbsp;# Adaptec FSA RAID<br/>#device &nbsp; &nbsp;aacp &nbsp; &nbsp;# SCSI passthrough for aac (requires CAM)<br/>#device &nbsp; &nbsp;ida &nbsp; &nbsp;# Compaq Smart RAID<br/>#device &nbsp; &nbsp;mfi &nbsp; &nbsp;# LSI MegaRAID SAS<br/>#device &nbsp; &nbsp;mlx &nbsp; &nbsp;# Mylex DAC960 family<br/>#device &nbsp; &nbsp;pst &nbsp; &nbsp;# Promise Supertrak SX6000<br/>#device &nbsp; &nbsp;twe &nbsp; &nbsp;# 3ware ATA RAID<br/><br/># atkbdc0 controls both the keyboard and the PS/2 mouse<br/>device &nbsp; &nbsp;atkbdc &nbsp; &nbsp;# AT keyboard controller<br/>device &nbsp; &nbsp;atkbd &nbsp; &nbsp;# AT keyboard<br/>device &nbsp; &nbsp;psm &nbsp; &nbsp;# PS/2 mouse<br/><br/>#device &nbsp; &nbsp;kbdmux &nbsp; &nbsp;# keyboard multiplexer<br/><br/>device &nbsp; &nbsp;vga &nbsp; &nbsp;# VGA video card driver<br/><br/>device &nbsp; &nbsp;splash &nbsp; &nbsp;# Splash screen and screen saver support<br/><br/># syscons is the default console driver, resembling an SCO console<br/>device &nbsp; &nbsp;sc<br/><br/># Enable this for the pcvt (VT220 compatible) console driver<br/>#device &nbsp; &nbsp;vt<br/>#options &nbsp; XSERVER &nbsp; &nbsp;# support for X server on a vt console<br/>#options &nbsp; FAT_CURSOR &nbsp;# start with block cursor<br/><br/>device &nbsp; &nbsp;agp &nbsp; &nbsp;# support several AGP chipsets<br/><br/># Power management support (see NOTES for more options)<br/>#device &nbsp; &nbsp;apm<br/># Add suspend/resume support for the i8254.<br/>device &nbsp; &nbsp;pmtimer<br/><br/># PCCARD (PCMCIA) support<br/># PCMCIA and cardbus bridge support<br/>#device &nbsp; &nbsp;cbb &nbsp; &nbsp;# cardbus (yenta) bridge<br/>#device &nbsp; &nbsp;pccard &nbsp; &nbsp;# PC Card (16-bit) bus<br/>#device &nbsp; &nbsp;cardbus &nbsp; &nbsp;# CardBus (32-bit) bus<br/><br/># Serial (COM) ports<br/>device &nbsp; &nbsp;sio &nbsp; &nbsp;# 8250, 16[45]50 based serial ports<br/><br/># Parallel port<br/>device &nbsp; &nbsp;ppc<br/>device &nbsp; &nbsp;ppbus &nbsp; &nbsp;# Parallel port bus (required)<br/>device &nbsp; &nbsp;lpt &nbsp; &nbsp;# Printer<br/>device &nbsp; &nbsp;plip &nbsp; &nbsp;# TCP/IP over parallel<br/>device &nbsp; &nbsp;ppi &nbsp; &nbsp;# Parallel port interface device<br/>#device &nbsp; &nbsp;vpo &nbsp; &nbsp;# Requires scbus and da<br/><br/># If you've got a "dumb" serial or parallel PCI card that is<br/># supported by the puc(4) glue driver, uncomment the following<br/># line to enable it (connects to the sio and/or ppc drivers):<br/>#device &nbsp; &nbsp;puc<br/><br/># PCI Ethernet NICs.<br/>device &nbsp; &nbsp;de &nbsp; &nbsp;# DEC/Intel DC21x4x (``Tulip'')<br/>device &nbsp; &nbsp;em &nbsp; &nbsp;# Intel PRO/1000 adapter Gigabit Ethernet Card<br/>device &nbsp; &nbsp;ixgb &nbsp; &nbsp;# Intel PRO/10GbE Ethernet Card<br/>device &nbsp; &nbsp;txp &nbsp; &nbsp;# 3Com 3cR990 (``Typhoon'')<br/>device &nbsp; &nbsp;vx &nbsp; &nbsp;# 3Com 3c590, 3c595 (``Vortex'')<br/><br/># PCI Ethernet NICs that use the common MII bus controller code.<br/># NOTE: Be sure to keep the 'device miibus' line in order to use these NICs!<br/>device &nbsp; &nbsp;miibus &nbsp; &nbsp;# MII bus support<br/>device &nbsp; &nbsp;bce &nbsp; &nbsp;# Broadcom BCM5706/BCM5708 Gigabit Ethernet<br/>device &nbsp; &nbsp;bfe &nbsp; &nbsp;# Broadcom BCM440x 10/100 Ethernet<br/>device &nbsp; &nbsp;bge &nbsp; &nbsp;# Broadcom BCM570xx Gigabit Ethernet<br/>device &nbsp; &nbsp;dc &nbsp; &nbsp;# DEC/Intel 21143 and various workalikes<br/>device &nbsp; &nbsp;fxp &nbsp; &nbsp;# Intel EtherExpress PRO/100B (82557, 82558)<br/>device &nbsp; &nbsp;lge &nbsp; &nbsp;# Level 1 LXT1001 gigabit Ethernet<br/>device &nbsp; &nbsp;nge &nbsp; &nbsp;# NatSemi DP83820 gigabit Ethernet<br/>device &nbsp; &nbsp;nve &nbsp; &nbsp;# nVidia nForce MCP on-board Ethernet Networking<br/>device &nbsp; &nbsp;pcn &nbsp; &nbsp;# AMD Am79C97x PCI 10/100(precedence over 'lnc')<br/>device &nbsp; &nbsp;re &nbsp; &nbsp;# RealTek 8139C+/8169/8169S/8110S<br/>device &nbsp; &nbsp;rl &nbsp; &nbsp;# RealTek 8129/8139<br/>device &nbsp; &nbsp;sf &nbsp; &nbsp;# Adaptec AIC-6915 (``Starfire'')<br/>device &nbsp; &nbsp;sis &nbsp; &nbsp;# Silicon Integrated Systems SiS 900/SiS 7016<br/>device &nbsp; &nbsp;sk &nbsp; &nbsp;# SysKonnect SK-984x & SK-982x gigabit Ethernet<br/>device &nbsp; &nbsp;ste &nbsp; &nbsp;# Sundance ST201 (D-Link DFE-550TX)<br/>device &nbsp; &nbsp;ti &nbsp; &nbsp;# Alteon Networks Tigon I/II gigabit Ethernet<br/>device &nbsp; &nbsp;tl &nbsp; &nbsp;# Texas Instruments ThunderLAN<br/>device &nbsp; &nbsp;tx &nbsp; &nbsp;# SMC EtherPower II (83c170 ``EPIC'')<br/>device &nbsp; &nbsp;vge &nbsp; &nbsp;# VIA VT612x gigabit Ethernet<br/>device &nbsp; &nbsp;vr &nbsp; &nbsp;# VIA Rhine, Rhine II<br/>device &nbsp; &nbsp;wb &nbsp; &nbsp;# Winbond W89C840F<br/>device &nbsp; &nbsp;xl &nbsp; &nbsp;# 3Com 3c90x (``Boomerang'', ``Cyclone'')<br/><br/># ISA Ethernet NICs. &nbsp;pccard NICs included.<br/>#device &nbsp; &nbsp;cs &nbsp; &nbsp;# Crystal Semiconductor CS89x0 NIC<br/># 'device ed' requires 'device miibus'<br/>#device &nbsp; &nbsp;ed &nbsp; &nbsp;# NE[12]000, SMC Ultra, 3c503, DS8390 cards<br/>#device &nbsp; &nbsp;ex &nbsp; &nbsp;# Intel EtherExpress Pro/10 and Pro/10+<br/>#device &nbsp; &nbsp;ep &nbsp; &nbsp;# Etherlink III based cards<br/>#device &nbsp; &nbsp;fe &nbsp; &nbsp;# Fujitsu MB8696x based cards<br/>#device &nbsp; &nbsp;ie &nbsp; &nbsp;# EtherExpress 8/16, 3C507, StarLAN 10 etc.<br/>#device &nbsp; &nbsp;lnc &nbsp; &nbsp;# NE2100, NE32-VL Lance Ethernet cards<br/>#device &nbsp; &nbsp;sn &nbsp; &nbsp;# SMC's 9000 series of Ethernet chips<br/>#device &nbsp; &nbsp;xe &nbsp; &nbsp;# Xircom pccard Ethernet<br/><br/># Wireless NIC cards<br/>#device &nbsp; &nbsp;wlan &nbsp; &nbsp;# 802.11 support<br/>#device &nbsp; &nbsp;an &nbsp; &nbsp;# Aironet 4500/4800 802.11 wireless NICs.<br/>#device &nbsp; &nbsp;awi &nbsp; &nbsp;# BayStack 660 and others<br/>#device &nbsp; &nbsp;ral &nbsp; &nbsp;# Ralink Technology RT2500 wireless NICs.<br/>#device &nbsp; &nbsp;wi &nbsp; &nbsp;# WaveLAN/Intersil/Symbol 802.11 wireless NICs.<br/>#device &nbsp; &nbsp;wl &nbsp; &nbsp;# Older non 802.11 Wavelan wireless NIC.<br/><br/># Pseudo devices.<br/>device &nbsp; &nbsp;loop &nbsp; &nbsp;# Network loopback<br/>device &nbsp; &nbsp;random &nbsp; &nbsp;# Entropy device<br/>device &nbsp; &nbsp;ether &nbsp; &nbsp;# Ethernet support<br/>device &nbsp; &nbsp;sl &nbsp; &nbsp;# Kernel SLIP<br/>device &nbsp; &nbsp;ppp &nbsp; &nbsp;# Kernel PPP<br/>device &nbsp; &nbsp;tun &nbsp; &nbsp;# Packet tunnel.<br/>device &nbsp; &nbsp;pty &nbsp; &nbsp;# Pseudo-ttys (telnet etc)<br/>device &nbsp; &nbsp;md &nbsp; &nbsp;# Memory "disks"<br/>device &nbsp; &nbsp;gif &nbsp; &nbsp;# IPv6 and IPv4 tunneling<br/>device &nbsp; &nbsp;faith &nbsp; &nbsp;# IPv6-to-IPv4 relaying (translation)<br/><br/># The `bpf' device enables the Berkeley Packet Filter.<br/># Be aware of the administrative consequences of enabling this!<br/># Note that 'bpf' is required for DHCP.<br/>device &nbsp; &nbsp;bpf &nbsp; &nbsp;# Berkeley packet filter<br/><br/># USB support<br/>#device &nbsp; &nbsp;uhci &nbsp; &nbsp;# UHCI PCI->USB interface<br/>#device &nbsp; &nbsp;ohci &nbsp; &nbsp;# OHCI PCI->USB interface<br/>#device &nbsp; &nbsp;ehci &nbsp; &nbsp;# EHCI PCI->USB interface (USB 2.0)<br/>device &nbsp; &nbsp;usb &nbsp; &nbsp;# USB Bus (required)<br/>#device &nbsp; &nbsp;udbp &nbsp; &nbsp;# USB Double Bulk Pipe devices<br/>device &nbsp; &nbsp;ugen &nbsp; &nbsp;# Generic<br/>#device &nbsp; &nbsp;uhid &nbsp; &nbsp;# "Human Interface Devices"<br/>device &nbsp; &nbsp;ukbd &nbsp; &nbsp;# Keyboard<br/>#device &nbsp; &nbsp;ulpt &nbsp; &nbsp;# Printer<br/>#device &nbsp; &nbsp;umass &nbsp; &nbsp;# Disks/Mass storage - Requires scbus and da<br/>device &nbsp; &nbsp;ums &nbsp; &nbsp;# Mouse<br/>#device &nbsp; &nbsp;ural &nbsp; &nbsp;# Ralink Technology RT2500USB wireless NICs<br/>#device &nbsp; &nbsp;urio &nbsp; &nbsp;# Diamond Rio 500 MP3 player<br/>#device &nbsp; &nbsp;uscanner &nbsp;# Scanners<br/># USB Ethernet, requires miibus<br/>#device &nbsp; &nbsp;aue &nbsp; &nbsp;# ADMtek USB Ethernet<br/>#device &nbsp; &nbsp;axe &nbsp; &nbsp;# ASIX Electronics USB Ethernet<br/>#device &nbsp; &nbsp;cdce &nbsp; &nbsp;# Generic USB over Ethernet<br/>#device &nbsp; &nbsp;cue &nbsp; &nbsp;# CATC USB Ethernet<br/>#device &nbsp; &nbsp;kue &nbsp; &nbsp;# Kawasaki LSI USB Ethernet<br/>#device &nbsp; &nbsp;rue &nbsp; &nbsp;# RealTek RTL8150 USB Ethernet<br/><br/># FireWire support<br/>#device &nbsp; &nbsp;firewire &nbsp;# FireWire bus code<br/>#device &nbsp; &nbsp;sbp &nbsp; &nbsp;# SCSI over FireWire (Requires scbus and da)<br/>#device &nbsp; &nbsp;fwe &nbsp; &nbsp;# Ethernet over FireWire (non-standard!)</div></div><br/><br/>编辑完了以后就保存退出。然后执行：<br/>cd /usr/src<br/>make kernel KERNCONF=ArthurXF<br/>系统开始编译内核了，如果全部通过了就可以继续操作了，如果编译出错了，就可能是哪个必须要用到的设备被你注释掉了，好好找找，把注释取消重新编译，直到编译通过为止。呵呵<br/>编译通过之后，就重起让新内核加载：<br/>shutdown –r now <br/>重起之后，我们执行这个命令：<br/>dmesg<br/>这时我们将看到返回来的信息。<br/><div class="quote"><div class="quote-title">引用</div><div class="quote-content">Copyright (c) 1992-2006 The FreeBSD Project.<br/>Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994<br/> &nbsp; &nbsp; &nbsp; &nbsp;The Regents of the University of California. All rights reserved.<br/>FreeBSD 6.1-RELEASE #0: Sun May &nbsp;7 04:32:43 UTC 2006<br/> &nbsp; &nbsp;root@opus.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC<br/>ACPI APIC Table: <AMIINT INTEL845><br/>Timecounter "i8254" frequency 1193182 Hz quality 0<br/>CPU: Intel(R) Celeron(R) CPU 2.13GHz (2126.45-MHz 686-class CPU)<br/> &nbsp;Origin = "GenuineIntel" &nbsp;Id = 0xf41 &nbsp;Stepping = 1<br/> &nbsp;Features=0xbfebfbff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CLFLUSH,DTS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE><br/> &nbsp;Features2=0x441d<SSE3,RSVD2,MON,DS_CPL,CNTX-ID,<b14>><br/>real memory &nbsp;= 528416768 (503 MB)<br/>avail memory = 507715584 (484 MB)<br/>ioapic0 <Version 2.0> irqs 0-23 on motherboard<br/>kbd1 at kbdmux0<br/>acpi0: <AMIINT INTEL845> on motherboard<br/>acpi0: Power Button (fixed)<br/>Timecounter "ACPI-fast" frequency 3579545 Hz quality 1000<br/>acpi_timer0: <24-bit timer at 3.579545MHz> port 0x808-0x80b on acpi0<br/>cpu0: <ACPI CPU> on acpi0<br/>acpi_throttle0: <ACPI CPU Throttling> on cpu0<br/>acpi_button0: <Power Button> on acpi0<br/>pcib0: <ACPI Host-PCI bridge> port 0xcf8-0xcff on acpi0<br/>pci0: <ACPI PCI bus> on pcib0<br/>agp0: <Intel 82845G (845G GMCH) SVGA controller> mem 0xd0000000-0xd7ffffff,0xdff80000-0xdfffffff irq 16 at device 2.0 on pci0<br/>agp0: detected 8060k stolen memory<br/>agp0: aperture size is 128M<br/>uhci0: <Intel 82801DB (ICH4) USB controller USB-A> port 0xe400-0xe41f irq 16 at device 29.0 on pci0<br/>uhci0: [GIANT-LOCKED]<br/>usb0: <Intel 82801DB (ICH4) USB controller USB-A> on uhci0<br/>usb0: USB revision 1.0<br/>uhub0: Intel UHCI root hub, class 9/0, rev 1.00/1.00, addr 1<br/>uhub0: 2 ports with 2 removable, self powered<br/>uhci1: <Intel 82801DB (ICH4) USB controller USB-B> port 0xe800-0xe81f irq 19 at device 29.1 on pci0<br/>uhci1: [GIANT-LOCKED]<br/>usb1: <Intel 82801DB (ICH4) USB controller USB-B> on uhci1<br/>usb1: USB revision 1.0<br/>uhub1: Intel UHCI root hub, class 9/0, rev 1.00/1.00, addr 1<br/>uhub1: 2 ports with 2 removable, self powered<br/>uhci2: <Intel 82801DB (ICH4) USB controller USB-C> port 0xec00-0xec1f irq 18 at device 29.2 on pci0<br/>uhci2: [GIANT-LOCKED]<br/>usb2: <Intel 82801DB (ICH4) USB controller USB-C> on uhci2<br/>usb2: USB revision 1.0<br/>uhub2: Intel UHCI root hub, class 9/0, rev 1.00/1.00, addr 1<br/>uhub2: 2 ports with 2 removable, self powered<br/>ehci0: <Intel 82801DB/L/M (ICH4) USB 2.0 controller> mem 0xdff7bc00-0xdff7bfff irq 23 at device 29.7 on pci0<br/>ehci0: [GIANT-LOCKED]<br/>usb3: EHCI version 1.0<br/>usb3: companion controllers, 2 ports each: usb0 usb1 usb2<br/>usb3: <Intel 82801DB/L/M (ICH4) USB 2.0 controller> on ehci0<br/>usb3: USB revision 2.0<br/>uhub3: Intel EHCI root hub, class 9/0, rev 2.00/1.00, addr 1<br/>uhub3: 6 ports with 6 removable, self powered<br/>pcib1: <ACPI PCI-PCI bridge> at device 30.0 on pci0<br/>pci3: <ACPI PCI bus> on pcib1<br/>rl0: <RealTek 8139 10/100BaseTX> port 0xcc00-0xccff mem 0xdfdfff00-0xdfdfffff irq 17 at device 4.0 on pci3<br/>miibus0: <MII bus> on rl0<br/>rlphy0: <RealTek internal media interface> on miibus0<br/>rlphy0: &nbsp;10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, auto<br/>rl0: Ethernet address: 00:14:78:25:fd:e6<br/>rl1: <RealTek 8139 10/100BaseTX> port 0xc800-0xc8ff mem 0xdfdffe00-0xdfdffeff irq 18 at device 5.0 on pci3<br/>miibus1: <MII bus> on rl1<br/>rlphy1: <RealTek internal media interface> on miibus1<br/>rlphy1: &nbsp;10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, auto<br/>rl1: Ethernet address: 00:14:78:26:26:58<br/>rl2: <RealTek 8139 10/100BaseTX> port 0xc400-0xc4ff mem 0xdfdffd00-0xdfdffdff irq 17 at device 10.0 on pci3<br/>miibus2: <MII bus> on rl2<br/>rlphy2: <RealTek internal media interface> on miibus2<br/>rlphy2: &nbsp;10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, auto<br/>rl2: Ethernet address: 00:13:8f:78:da:51<br/>isab0: <PCI-ISA bridge> at device 31.0 on pci0<br/>isa0: <ISA bus> on isab0<br/>atapci0: <Intel ICH4 UDMA100 controller> port 0x1f0-0x1f7,0x3f6,0x170-0x177,0x376,0xfc00-0xfc0f at device 31.1 on pci0<br/>ata0: <ATA channel 0> on atapci0<br/>ata1: <ATA channel 1> on atapci0<br/>pci0: <multimedia, audio> at device 31.5 (no driver attached)<br/>fdc0: <floppy drive controller> port 0x3f2-0x3f3,0x3f4-0x3f5,0x3f7 irq 6 drq 2 on acpi0<br/>fdc0: [FAST]<br/>sio0: <16550A-compatible COM port> port 0x3f8-0x3ff irq 4 flags 0x10 on acpi0<br/>sio0: type 16550A<br/>sio1: <Generic IRDA-compatible device> port 0x2f8-0x2ff irq 3 on acpi0<br/>sio1: type 16550A<br/>ppc0: <ECP parallel printer port> port 0x378-0x37f,0x778-0x77b irq 7 drq 3 on acpi0<br/>ppc0: SMC-like chipset (ECP/EPP/PS2/NIBBLE) in COMPATIBLE mode<br/>ppc0: FIFO with 16/16/9 bytes threshold<br/>ppbus0: <Parallel port bus> on ppc0<br/>plip0: <PLIP network interface> on ppbus0<br/>lpt0: <Printer> on ppbus0<br/>lpt0: Interrupt-driven port<br/>ppi0: <Parallel I/O> on ppbus0<br/>pmtimer0 on isa0<br/>atkbdc0: <Keyboard controller (i8042)> at port 0x60,0x64 on isa0<br/>atkbd0: <AT Keyboard> irq 1 on atkbdc0<br/>kbd0 at atkbd0<br/>atkbd0: [GIANT-LOCKED]<br/>sc0: <System console> at flags 0x100 on isa0<br/>sc0: VGA <16 virtual consoles, flags=0x300><br/>vga0: <Generic ISA VGA> at port 0x3c0-0x3df iomem 0xa0000-0xbffff on isa0<br/>Timecounter "TSC" frequency 2126445016 Hz quality 800<br/>Timecounters tick every 1.000 msec<br/>ad0: 76319MB <WDC WD800BB-00JHC0 05.01C05> at ata0-master UDMA100<br/>Trying to mount root from ufs:/dev/ad0s1a<br/>Waiting (max 60 seconds) for system process `vnlru' to stop...done<br/>Waiting (max 60 seconds) for system process `bufdaemon' to stop...done<br/>Waiting (max 60 seconds) for system process `syncer' to stop...<br/>Syncing disks, vnodes remaining...1 1 1 0 0 0 done<br/>All buffers synced.<br/>Uptime: 23h16m32s<br/>Shutting down ACPI<br/>Rebooting...<br/>Copyright (c) 1992-2006 The FreeBSD Project.<br/>Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994<br/> &nbsp; &nbsp; &nbsp; &nbsp;The Regents of the University of California. All rights reserved.<br/>FreeBSD 6.1-RELEASE #2: Thu Jan 18 07:52:26 CST 2007<br/> &nbsp; &nbsp;arthur@www.wap.com:/usr/obj/usr/src/sys/ArthurXF<br/>ACPI APIC Table: <AMIINT INTEL845><br/>Timecounter "i8254" frequency 1193182 Hz quality 0<br/>CPU: Intel(R) Celeron(R) CPU 2.13GHz (2126.44-MHz 686-class CPU)<br/> &nbsp;Origin = "GenuineIntel" &nbsp;Id = 0xf41 &nbsp;Stepping = 1<br/> &nbsp;Features=0xbfebfbff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CLFLUSH,DTS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE><br/> &nbsp;Features2=0x441d<SSE3,RSVD2,MON,DS_CPL,CNTX-ID,<b14>><br/>real memory &nbsp;= 528416768 (503 MB)<br/>avail memory = 507731968 (484 MB)<br/>ioapic0 <Version 2.0> irqs 0-23 on motherboard<br/>acpi0: <AMIINT INTEL845> on motherboard<br/>acpi0: Power Button (fixed)<br/>Timecounter "ACPI-fast" frequency 3579545 Hz quality 1000<br/>acpi_timer0: <24-bit timer at 3.579545MHz> port 0x808-0x80b on acpi0<br/>cpu0: <ACPI CPU> on acpi0<br/>acpi_throttle0: <ACPI CPU Throttling> on cpu0<br/>acpi_button0: <Power Button> on acpi0<br/>pcib0: <ACPI Host-PCI bridge> port 0xcf8-0xcff on acpi0<br/>pci0: <ACPI PCI bus> on pcib0<br/>agp0: <Intel 82845G (845G GMCH) SVGA controller> mem 0xd0000000-0xd7ffffff,0xdff80000-0xdfffffff irq 16 at device 2.0 on pci0<br/>agp0: detected 8060k stolen memory<br/>agp0: aperture size is 128M<br/>pci0: <serial bus, USB> at device 29.0 (no driver attached)<br/>pci0: <serial bus, USB> at device 29.1 (no driver attached)<br/>pci0: <serial bus, USB> at device 29.2 (no driver attached)<br/>pci0: <serial bus, USB> at device 29.7 (no driver attached)<br/>pcib1: <ACPI PCI-PCI bridge> at device 30.0 on pci0<br/>pci3: <ACPI PCI bus> on pcib1<br/>rl0: <RealTek 8139 10/100BaseTX> port 0xcc00-0xccff mem 0xdfdfff00-0xdfdfffff irq 17 at device 4.0 on pci3<br/>miibus0: <MII bus> on rl0<br/>rlphy0: <RealTek internal media interface> on miibus0<br/>rlphy0: &nbsp;10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, auto<br/>rl0: Ethernet address: 00:14:78:25:fd:e6<br/>rl1: <RealTek 8139 10/100BaseTX> port 0xc800-0xc8ff mem 0xdfdffe00-0xdfdffeff irq 18 at device 5.0 on pci3<br/>miibus1: <MII bus> on rl1<br/>rlphy1: <RealTek internal media interface> on miibus1<br/>rlphy1: &nbsp;10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, auto<br/>rl1: Ethernet address: 00:14:78:26:26:58<br/>rl2: <RealTek 8139 10/100BaseTX> port 0xc400-0xc4ff mem 0xdfdffd00-0xdfdffdff irq 17 at device 10.0 on pci3<br/>miibus2: <MII bus> on rl2<br/>rlphy2: <RealTek internal media interface> on miibus2<br/>rlphy2: &nbsp;10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, auto<br/>rl2: Ethernet address: 00:13:8f:78:da:51<br/>isab0: <PCI-ISA bridge> at device 31.0 on pci0<br/>isa0: <ISA bus> on isab0<br/>atapci0: <Intel ICH4 UDMA100 controller> port 0x1f0-0x1f7,0x3f6,0x170-0x177,0x376,0xfc00-0xfc0f at device 31.1 on pci0<br/>ata0: <ATA channel 0> on atapci0<br/>ata1: <ATA channel 1> on atapci0<br/>pci0: <multimedia, audio> at device 31.5 (no driver attached)<br/>sio0: <16550A-compatible COM port> port 0x3f8-0x3ff irq 4 flags 0x10 on acpi0<br/>sio0: type 16550A<br/>sio1: <Generic IRDA-compatible device> port 0x2f8-0x2ff irq 3 on acpi0<br/>sio1: type 16550A<br/>ppc0: <ECP parallel printer port> port 0x378-0x37f,0x778-0x77b irq 7 drq 3 on acpi0<br/>ppc0: SMC-like chipset (ECP/EPP/PS2/NIBBLE) in COMPATIBLE mode<br/>ppc0: FIFO with 16/16/9 bytes threshold<br/>ppbus0: <Parallel port bus> on ppc0<br/>plip0: <PLIP network interface> on ppbus0<br/>lpt0: <Printer> on ppbus0<br/>lpt0: Interrupt-driven port<br/>ppi0: <Parallel I/O> on ppbus0<br/>pmtimer0 on isa0<br/>atkbdc0: <Keyboard controller (i8042)> at port 0x60,0x64 on isa0<br/>atkbd0: <AT Keyboard> irq 1 on atkbdc0<br/>kbd0 at atkbd0<br/>atkbd0: [GIANT-LOCKED]<br/>sc0: <System console> at flags 0x100 on isa0<br/>sc0: VGA <16 virtual consoles, flags=0x300><br/>vga0: <Generic ISA VGA> at port 0x3c0-0x3df iomem 0xa0000-0xbffff on isa0<br/>Timecounter "TSC" frequency 2126443912 Hz quality 800<br/>Timecounters tick every 1.000 msec<br/>ad0: 76319MB <WDC WD800BB-00JHC0 05.01C05> at ata0-master UDMA100<br/>Trying to mount root from ufs:/dev/ad0s1a</div></div><br/><br/>看到中间有这么一段吗？<br/><div class="quote"><div class="quote-title">引用</div><div class="quote-content">Rebooting...<br/>Copyright (c) 1992-2006 The FreeBSD Project.<br/>Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994<br/> &nbsp; &nbsp; &nbsp; &nbsp;The Regents of the University of California. All rights reserved.<br/>FreeBSD 6.1-RELEASE #2: Thu Jan 18 07:52:26 CST 2007<br/> &nbsp; &nbsp;arthur@www.wap.com:/usr/obj/usr/src/sys/ArthurXF</div></div><br/>这里就是在替换内核，说明我们的新内核已经启动了。哈哈，内核编译成功！<br/><br/><div class="quote"><div class="quote-title">引用</div><div class="quote-content">编译完成以后，我们现在的工作就是对系统一些参数进行优化调整。<br/># ee /boot/loader.conf<br/>加入：<br/>kern.ipc.maxsockets=65535<br/>kern.maxusers=256<br/>kern.ipc.nmbclusters=32768<br/>kern.ipc.nsfbufs=2496<br/># ee /etc/sysctl.conf<br/>加入：<br/>net.inet.ip.sourceroute=0<br/>net.inet.ip.accept_sourceroute=0<br/>net.inet.tcp.drop_synfin=1<br/>kern.maxvnodes=8446<br/><br/>kern.maxfiles=65536<br/>kern.maxfilesperproc=32768<br/>kern.ipc.somaxconn=32768<br/>kern.ipc.shmmax=67108864 # 64MB<br/>kern.ipc.shmall=32768<br/>kern.ipc.shm_allow_removed=0<br/>kern.coredump=1<br/>net.inet.ip.portrange.last=65535<br/><br/>net.inet.tcp.msl=2500<br/>net.inet.udp.blackhole=1<br/>net.inet.udp.log_in_vain=1<br/>net.inet.tcp.always_keepalive=1<br/>net.inet.udp.blackhole=1<br/>net.inet.raw.maxdgram=65536<br/>net.inet.raw.recvspace=65536<br/><br/>net.inet.tcp.blackhole=2<br/>net.inet.tcp.delayed_ack=1<br/>net.inet.tcp.inflight.enable=1<br/>net.inet.tcp.inflight.debug=0<br/>net.inet.tcp.inflight.rttthresh=10<br/>net.inet.tcp.inflight.min=6144<br/>net.inet.tcp.inflight.max=1073725440<br/>net.inet.tcp.inflight.stab=20<br/><br/>net.local.stream.sendspace=65536<br/>net.local.stream.recvspace=65536<br/>net.inet.tcp.sendspace=32768<br/>net.inet.tcp.recvspace=65536<br/>net.inet.udp.maxdgram=24576<br/>net.inet.udp.recvspace=49152<br/><br/>net.inet.ip.rtexpire=3600<br/>net.inet.ip.rtminexpire=2<br/><br/>net.inet.ip.random_id=1<br/>net.inet.icmp.icmplim=100<br/>net.inet.icmp.icmplim_output=1<br/>net.inet.icmp.drop_redirect=1<br/>net.inet.icmp.log_redirect=1<br/><br/>net.inet.tcp.keepidle=600000<br/>net.inet.ip.redirect=0<br/>net.isr.direct=1<br/>net.inet.ip.intr_queue_maxlen=4096<br/><br/>kern.ipc.shm_use_phys=1<br/>net.inet.ip.fastforwarding=1<br/><br/>vfs.hirunningspace=4194304<br/>vfs.ufs.dirhash_maxmem=33554432 # 32MB<br/>vfs.write_behind=0<br/>security.bsd.see_other_uids=1<br/>security.bsd.see_other_gids=1</div></div><br/>设置完成以后reboot机器。<br/>如果要不重启机器加载改动的参数还可以使用：<br/># /etc/rc.d/sysctl reload<br/><br/><br/>现在ArthurXF本人正在搞PHP等技术培训，如果想学习的人可以跟我联系。另外培训的招生简章在这个网址，想了解的可以去看看。加我QQ：29011218交流也可。<br/><a href="http://www.bizeway.net/read.php/285.htm" target="_blank">PHP培训招生简章</a><br/>Tags - <a href="tag.php?tag=freebsd" rel="tag">freebsd</a> , <a href="tag.php?tag=%E7%BC%96%E8%AF%91%E5%86%85%E6%A0%B8" rel="tag">编译内核</a> , <a href="tag.php?tag=kernel" rel="tag">kernel</a> , <a href="tag.php?tag=generic" rel="tag">generic</a>
]]>
</description>
</item><item>
<link>http://www.bizeway.net/read.php?&amp;guid=0#topreply</link>
<title><![CDATA[[评论] 跟着ArthurXF学FreeBSD2——给FreeBSD一个优化的新内核]]></title> 
<author> &lt;user@domain.com&gt;</author>
<category><![CDATA[评论]]></category>
<pubDate>Thu, 01 Jan 1970 00:00:00 +0000</pubDate> 
<guid>http://www.bizeway.net/read.php?&amp;guid=0#topreply</guid> 
<description>
<![CDATA[ 
	
]]>
</description>
</item>
</channel>
</rss>