Linux-2.6 kernel upgrade document

xiaoxiao2021-03-06  40

linux-2.6 kernel upgrade document author: killua order to do one thing, we must first know what you are doing, rather than blindly have to upgrade your kernel, upgrade the kernel a little flood, let us first look at the new features a 2.6 kernel, 01. Module subsystem, unified device model (Unified Device Model), and PNP support module subsystems have changed. 02. Stability has improved to completely avoid the kernel loading or export the kernel module being used, or at least to reduce the possibility of using the module while the loading or unloading module (this sometimes causes the system crash), the core loading and export The process of the kernel module has been improved. 03. The creation of the unified equipment model unified equipment model is one of the most important changes in the core of the 2.6 core. It promotes the standardization of the module interface, its purpose is to better control and manage equipment, such as: more accurately determining system equipment. Power management and device power status. Improved system bus structure management. 04. Plug and Play (PNP) Support 1.1.1 and 1.1.2 The changes mentioned in section referred to makes Linux running 2.6 kernels into a real plug-and-play OS. For example, the ISA PNP extension, legacy MCA and EISA bus, and PNP support for hot-swappable devices. 05. Changes in kernel infrastructure In order to distinguish between .o as a conventional object file, the extension of the kernel module is now used. Ko. Created a new SYSFS file system, describe it when the kernel discovers the device tree. Memory support, NUMA support supports a larger number of RAM 2.6 kernel supports a larger number of RAMs, up to 64GB in paging mode. 06.NUMA support for non-uniform memory access - NUMA systems is a new appearance in the 2.6 core. 07. Thread model, NPTL relative to V2.4's LinuxThreads, new appearance in version 2.6 is NPTL (Native Posix Threading Library). NPTL brings enterprise thread support for Linux, and provides performance far exceeding LinuXThreads. The ratio of the user and kernel threads based on it is 1: 1. In October 2003, NPTL support in GNU C library Glibc, Red Hat took the lead in using custom V2.4 kernels in Red Hat Linux 9 and Red Hat Enterprise Linux. NPTL. 08. Performance Improvement New Scheduler Algorithm 2.6 The Linux kernel introduces a new O (1) algorithm. It is very good to run in high load conditions. The new scheduler is based on each CPU to distribute the time slice, which eliminates the global synchronization and reassign cycle, thereby improving performance. Kernel Preemption The new 2.6 core is a preemptive. This will significantly improve the performance of interactive and multimedia applications. I / O Performance Improves Linux I / O Subsystem has also changed, by modifying the I / O scheduler to ensure that there will be no process residing in the queue for too long waiting for input / output operation, so that The I / O operation response is more rapid. Fast User-Space Mutexes "Futexes" (Fast User Space Mutual Enhance) enables thread serialization to avoid stamping conditions, introducing it also increases response speed.

Improvements are implemented by partially implementing "Futexes" in the kernel space to allow priority based on competitive settings waiting tasks. 09. The number of extended processors more than Linux kernel 2.6 can support up to 64 CPUs. Support for larger memory, attributed to PAE (physical address extension, Physical Address Extensions), adding memory supported in the 32-bit system to 64GB. The only user and group of users and groups increase from 65,000 to 4 billion, which is from 16-bit to 32-bit. The number of PIDs PID increased from 32,000 to 1 billion. The number of open file descriptors opens the number of file descriptors does not increase, but no longer sets the parameter in advance, it will adjust itself. 10. Support for more devices Before Linux core 2.6, there is a limit to the large system, such as 256 devices per chain. V2.6 kernel thoroughly breaks these restrictions, not only support more types of equipment, but also supports more types of equipment. In Linux 2.6 systems, 4095 main device types can be supported, each with more than one million sub-devices. File System Size Linux Core 2.6 The addressable file system allowed to 16 TB. 11. Traditional Linux file systems such as file system EXT2, EXT3 and Reiserfs have been significantly improved. The most worthless improvement is the introduction of extended attributes (or file metadata). The most important thing is the implementation of the POSIX ACL, which is an extension of ordinary UNIX privileges that supports more detailed user access control. 12. In addition to the improved support of traditional Linux file systems, new kernels fully support relatively new XFS file systems in Linux. The Linux 2.6 kernel is now introduced to the improved support of the NTFS file system, and the NTFS file system is now allowed to be installed in read / write mode.

Based on the new features of the above 2.6, I decided to use 2.6 kernel, my system is Red Hat Enterprise Linux As Release 3 (TAROON UPDATE 3) Hardware environment is Dell 2850, download decompression and hit the kernel patch, I use 2.6.10 as an example. Patche's example in BK4, the purpose is to let everyone know how to play patch, in fact, I use 2.6.6 kernel because of the kernel of the AS3.0 to 2.6.9 or more, Mount large NFS network hard disk, The DF shows incorrect, obviously 800g discs become 4.2g, but it can still be used normally, I am using NFS and MOUNT bags, / var / log / message prompt is KERNEL: NFS Warning: Mount Version Older Than Kernel, I hope to know, thank you :) BTW: 2.6.8 The kernel has not used the kernel source code: http://www.kernel.org/pub/linux/kernel/v2.6/linux-2.6 .10.tar.bz2 latest kernel patch: http://www.kernel.org/pub/linux/kernel/v2.6/snapshots/patch-2.6.10-bk4.bz2 CD / USR / SRC RM-RM-RINUX TAR JXF /DOWNLOAD/LINUX-2.6.10.TAR.BZ2 ln -s Linux-2.6.10 Linux CD Linux Bunzip2 -dv /download/patch-2.6.10-bk4.bz2 | patch -p1 if in / usr / src Use patch -p0 in the directory, modify the kernel source code (upgrade 2.6 is to optimize, simply change the source code) 1. Modify /usr/src/linux/include/linux/posix_types.h Set the fd_set support Maximum number #define __fd_setsize 1024 ---> 65536 2. Modification /usr/src/linux/include/linux/fs.h Set the maximum opening file number (TCP connection number) #define INR_Open 1024 ---> 65536 #define nr_file 8192 --- > 65536 #define nr_reserved_files 10 ---> 128 3. Modify /usr/src/linux/include/net/tcp.h Set Timeout time is 1 second #define tcp_timewait_len (60 * hz) 60 ---> 1 * Hz sets the number of retry times in the backlog queue, every time, it will spend the corresponding time, essentially researchers #define tcp_synack_retries 5 ---> 3 For RHEL-AS3, it is stable optimized, but Even if you use RHEL-AS3's own kernel, then you have to modify the above parameters !) Third, install the necessary tools 1. Download Module-Init-Tools-3.1.tar.bz2 http: //www.kernel .org / pub / linux / utils / kernel / module-init-tools / module-init-tools-3.1.tar.bz2 code: ./configure --prefix =

/ Make moved make all install ./generate-modprobe.conf /etc/modprobe.conf 2. Download new mkinitrd ftp://195.220.108.108/linux/6/Fedora/core/3/i386/os/Fedora/i386/OS/Fedora/I386/OS/Fedora/I /mkinitrd-4.1.18-2.i386.rpm It requires lvm2 device-mapper ftp://195.220.108.108/linux/6/Fedora/core/3/i386/4/fedora/rpms/device-mapper-1.00. 19-2.i386. rpm ftp://195.220.108.108/linux/6/Fedora/core/3/i386/OS/Fedora/rpms/LVM2-2.00.25-1.01.i386.rpm If you do not update this package Make Install will prompt the following error: No module mptbase Found for kernel 2.6.10-bk4, aborting. mkinitrd failed make [1]: *** [install] error 1 make: *** [install] error 2 installation LVM2-2.00.25-1.01.i386.25-1.01.i386.rpm Please use rpm -ivh --Node Package Name four, make menuconfig code: 01.code maturity level options ---> [*] Prompt for development and / or ibPlete code / Drivers [*] select online cleanly 02.general setup ---> [*] support for paging of anonymous memory (swap) [*] System V IPC [*] POSIX Message Queues [] BSD Process Accounting [*] Sysctl support [] Auditing support [] Support for hot-pluggable devices [*] Kernel Userspace Events [] Kernel .config support [*] Configure standard kernel features (for small Systems --->

[*] Load all symbols for debugging / kksymoops [] Do an extra kallsyms pass [*] Enable futex support [*] Enable eventpoll support [] Optimize for size [*] Use full shmem filesystem 03.Loadable module support ---> [*] Enable loadable module support [*] Module unloading [] Forced module unloading [] Module versioning support (EXPERIMENTAL) [] Source checksum for all modules [*] Automatic kernel module loading 04.Processor type and features ---> Subarchitecture TYPE (PC-Compatible) ---> Processor Family (Pentium-4 / Celeron (P4-Based) / Pentium-4 m / Xeon) ---> [*] generic x86 support [] hpet timer support [*] Symmetric Multi -processing support multiple CPU (8) Maximum number of CPUs (2-255) [*] SMT (Hyperthreading) scheduler support [*] Preemptible Kernel preemptive kernel, select its [] Machine Check Exception <> Toshiba Laptop support < > Dell laptop support <> / dev / cpu / microcode - Intel IA32 CPU microcode support <> / dev / cpu / * / msr - Model-specific register support <> / dev / cpu / * / cpuid - CPU information support Firmware Drivers ---> High Memory Support (4GB) --->

High memory [] Allocate 3rd-level pagetables from highmem [] Math emulation [*] MTRR (Memory Type Range Register) support [*] Enable kernel irq balancing [] Use register arguments (EXPERIMENTAL) 05.Power management options (ACPI, APM ) ---> Power management self-qualified (even no choice) 06.bus options (PCI, PCMCIA, EISA, MCA, ISA) ---> board support custom [*] PCI support PCI Access Mode (ANY) - -> [] Message Signaled Interrupts (MSI and MSI-X) [*] Legacy / Proc / PCI Interface [*] PCI Device Name Database [] ISA Support [] MCA Support <> Natsemi SCX200 Support 07.executable file formats - -> [*] Kernel Support for Elf Binaries kernel support for a.out and ecoff binaries kernel SUPP Ort for Misc Binaries 08.Device drivers ---> Device Drive and Network Support Generic Driver Options ---> Default [*] Select Only Drivers That Don't Need Compile-Time External Firmware [*] Prevent Firmware from Being Built Memory TECHNOLOGY DEVICES (MTD) ---> Do not choose Parallel port support ---> Parallel ports Custom (even no choice) PLUG and play support ---> Support hot plugs Custom (even no choice) Block Devices - -> <*> Normal Floppy Disk Support <> Compaq Smart2 Support <> Compaq Smart Array 5xxx Support <>

Mylex DAC960 / DAC1100 PCI RAID Controller support <> Micro Memory MM5415 Battery Backed RAM support (EXPERIMENTAL) Loopback device support <> Cryptoloop Support Network block device support <> Promise SATA SX8 support RAM disk support ( 16) DEFAULT NUMBER OF RAM Disks (4096) Default Ram Disk Size (Kbytes) () Source Directory of CPIO_LIST [] Support for Large Block Devices <> Packet Writing on CD / DVD Media Io Schedules ---> IO Scheduler, Select how to specify IO schedule in Grub.conf, which method will be scheduled later, the <*> Anticipatory I / O Scheduler <*> deadline I / O Scheduler <*> CFQ I / O Scheduler ATA / ATAPI / MFM / RLL Support ---> ATA device self-qualified (even no choice) SCSI Device Support ---> SCSI device custom me with SCSI So the following option <*> scsi device support [*] legacy / proc / scsi / support --- SCSI Support Type (Disk, Tape, CD-ROM) <*> SCSI Disk support because of the SCSI of the doll MPT, No, omitted Multi-Device Support (RAID AND LVM) ---> Support RAID and LVM (Logical Volume) Customize [*] Multiple Devices Driver Support (RAID Support <> LINEAR (append) MODE <*> RAID-0 (Striping) Mode <>

RAID-1 (mirroring) Mode <> raid-10 (mirrored striping) mode (experimental) <*> raid-4 / raid-5 mode <> raid-6 mode (experimental) <*> Multipath I / O Support <> Faulty test module for MD <*> Device mapper support <> Crypt target support <> Snapshot target (EXPERIMENTAL) <> Mirror target (EXPERIMENTAL) <> Zero target (EXPERIMENTAL) Fusion MPT device support ---> is the dual SCSI So, choose or customize <*> fusion mpt (base scsihost) Drivers (40) maximum number of scatter Gather Entries <*> Fusion MPT Misc Device (IOCTL) Driver IEEE 1394 (FireWire) Support ---> Custom (Even no choice) I2O Device Support ---> Custom (even no choice) Networking support ---> Network option [*] networking support networking options ---> <*> Packet socket [] packet socket: mmapped IO <> NetLink Device Emulation <*> UNIX Domain Sockets If you have a network, you choose <>

PF_KEY SOCKETS [*] TCP / IP Networking [] IP: Multicasting [] IP: Advanced Router [] IP: Kernel Level AutoConfiguration <> ip: tunneling <> IP: GRE Tunnels over ip [] IP: ARP DAEMON Support (Experimental) [*] IP: TCP SYNCOOKIE Support (Disabled Per Default) can prevent DOS attacks, but will reduce a little performance, generally cost-effective, good <> ip: ah transformation <> IP: ESP Transformation <> ip: ipcomp transformation <> ip : tunnel transformation <*> ip: TCP Socket Monitoring Interface IP: Virtual Server Configuration ---> LVS Supports <> The IPv6 Protocol (Experimental) [*] NetWork Packet Filtering (Replace Ipchains) ---> Pack Filter 省省 (Know yourself, unfamiliar all) Select, omission [] Amateur Radio Support ---> <> Irda (Infrared) Subsystem Support ---> <> Bluetooth Subsystem Support ---> [*] Network Device Support <> Dummy Net Driver Support This is a NIS server Let's not be clear, no use <*>

Bonding Driver Support Dual NIC Bind <> EQL (Serial Line Load Balancing) Support <> universal tun / tap device driver support arcnet defices ---> Ethernet (10 or 100Mbit) ---> Ethernet (1000 mbit) -> <> Alteon AceNIC / 3Com 3C985 / NetGear GA620 Gigabit support <> D-Link DL2000-based Gigabit Ethernet support <> Intel (R) PRO / 1000 Gigabit Ethernet support <> National Semiconduct DP83820 support <> Packet Engines Hamachi GNIC- II support <> packet engines YellowFin GigaBit-Nic Support (Experimental) <> realtek 8169 Gigabit Ethernet support <> Marvell Yukon Chipset / Syskonnect SK-98XX Support <*> Broadcom TIGON3 Support, Isolated, ISDN SUBSYSTEM ---> Telephony Support ---> Input Device Support ---> Character Devices ---> I2C Support ---> Dallas's 1-Wire Bus - -> MULTIMEDIA DEVICES ---> graphics support ---> Sound ---> USB support ---> mmc / sd card support ---> Already not selected, you need to choose 09 .File systems ---> File System <> Second Extended Fs Support <*>

Ext3 journalling file system support [] Ext3 extended attributes [*] JBD (ext3) debugging support <> Reiserfs support <> JFS filesystem support <> XFS filesystem support <> Minix fs support <> ROM file system support [] Quota support <> kernel automounter support <*> kernel automounter version 4 support (also supports v3) CDROM / DVD Filesystems ---> <*> ISO 9660 CDROM file system support [] Microsoft Joliet CDROM extensions [] Transparent decompression extension <> UDF file SYSTEM Support DOS / FAT / NT FileSystems ---> FLOPPY to use file format <*> msdos fs support <*> vfat (windows-95) FS Support (437) Default CodePage for Fat (NEW) (ISO8859-1) Default Iocharset for fat (new) <> ntfs file system support pseudo filesystems --->

[*] / proc file system support [] / proc / kcore support [] / dev file system support (obsolete) [] / dev / pts extended attributes [*] Virtual Memory File System Support (FORMER SHM FS) virtual memory support [] tmpfs Extended Attributes [] HugeTLB file system support Miscellaneous filesystems ---> Network File Systems ---> <*> NFS file system support nfs client support [*] Provide NFSv3 client support [] Provide NFSv4 client Support (Experimental) [] Allow Direct I / O on NFS Files (Experimental) <> NFS Server Support NFS <> Secure RPC: Kerberos V mechanism (EXPERIMENTAL) <> Secure RPC: SPKM3 mechanism (EXPERIMENTAL) <> SMB file system support (to mount Windows shares etc.) samba support <> CIFS support (advanced network filesystem for Samba, Window and Other CIFS Compliant Servers <> NCP File System Support (To Mount NetWare Volumes) <> CODA File System Support (Advanced Network FS) <> Andrew File System Support (AFS) (AFS) (AFS) (AFS) (Experimental) Partition Types --->

Native language support ---> ourselves 10.Profiling support ---> No 11.kernel Hacking ---> No 12.Security Options ---> No 13.cryptographic options ---> No selected 14 .Library routines ---> <> crc32 functions CRC32C (Castagnoli, et al) CYCLIC Redundancy-check 5, compilation and installation steps: make -jn (n represents the process of compiling simultaneously, Accelerate compilation speed, N is determined by your configuration, I use 15-25) Make modules_install make install six, first introduce 2.6 I / O scheduler 2.6 included four I / O scheduler included four I / O scheduler NO-OP I / O Scheduler, Anticipatory I / O Scheduler, Deadline I / O Scheduler and CFQ I / O Scheduler. It is simply referred to as NS, AS, DS and CFQ, respectively. NS is a simplified scheduler that is only the most basic merger and sort. The relationship with the desktop system is not very large, mainly used in some special software and hardware environments, which generally have its own scheduling mechanism to have its own scheduling mechanism small, which is suitable for some embedded system environments. As a desktop user we generally do not choose it. As is the default I / O scheduler in the current core. It has a very good performance, which is quite attractive in 2.5. In a comparative test with the 2.4 kernel, a number in 2.4 is done in a minute unit, which is done in seconds. Because of this is the default I / O scheduler currently 2.6 beta. But it also has weaknesses, it itself is a relatively large complicated, in some special cases, especially in a database system in which the data throughput is very large, it will become slower. The DS is improving for the shortcomings of AS, but also in the test phase, but it is already stable. The performance currently exhibited is almost as good as AS. Plus is more compact than AS, is a fairly promising scheduler, worth a try :) CFQ assigns the same bandwidth for all tasks in the system, providing a fair working environment, which is more suitable for desktop environments. In fact, it also has a good performance in the test. MPlayer XMMS and other multimedia players are quite good, and the backfinder is hardly leaving the jumper phenomenon that occurs because of accessing the disk. Friends who like to listen to music in Linux can try it.

转载请注明原文地址:https://www.9cbs.com/read-55623.html

New Post(0)