P 's Normal Nuclear Configuration For a general user, the requirements for the efficiency and size of the Linux kernel are not high. It is therefore generally not reconfigurable because the Linux installer will default to most of the installation and actual hardware at the installation. Such a core will be more than the actual needs, there are many modules that are not used after loading, but because the current PC's memory is generally hundreds of MB, and a Linux kernel is a few hundred k, so for general In terms of the user, there is no need to recompile the kernel. In a P3-566 Dell machine installed Red-Hat 7.2, the kernel version is 2.4. Here are some of the configuration: loadable module support: y networking support: y PCI support: y system v ipc: y can be done Based on SYSTEM V, KERNEL Support for A.out Binaries: Y Kernel Support for Elf Binaries: Y Block Devices: The corresponding configuration is made according to the hardware of the machine, and the support module of some of the hardware devices that do not have. Such as: Loopback device support Networking options: Packet socket: Y TCP / IP networking: Y Network firewalls: Y The IPX protocol: Y Network device support: Network device support: Y Ethernet (10 or 100Mb / s): Y Character device Virtual terminal : Y Support for console on virtual terminal: Y Filesystems Second extended fs support: Y VFAT fs support: m I sometimes used VFAT partitions on the machine / proc filesystem support Y ISO9660 cdrom filesystem support: m Network File Systems NFS filesystem support: Y SMB FileSystem Support: M Console Drivers VGA Text Console: Y Video Mode Selection Support: y Kernel Hacking Magic Sysrq Key: Y has some default settings that the author did not change. This has been compiled with 700K. After the author debugging does not have any problems. PDA kernel Sets PDA (Personal Digital Assist), such as: mobile phones, expressions, text, and more. Such systems require system stability, low core and high efficiency, often require some special hardware support. For process schedules, file systems require a single, some are single process systems. Support for networks is determined by the need. RedHat's kernel cannot be used directly to design some special requirements of PDA, which is generally added to the hardware's specific module. You can set the following: NetWorking Support: Y: General PDA supports Internet Update function KERNEL Support for Elf Binaries: y compile as elf -if your gcc is elf-gcc: y These two settings make the system's execution files are Elf Advanced Power Manager BIOS Support: Y Block Devices: The hardware special support module NetWorking Options Packet Socket FileSystem SecondEded FS Support: y is N, of course, some functions must be used to support the above modules.
After compiling, a small embedded Linux system is only three basic elements below: 1. Boot tool, 2.Linux microenvironment, composed of memory management, process management, and transaction processing 3. Initialization Process If you want to dry something and continue to be miniaturized, you have to add: 1. Hardware Driver 2. One or more applications that provide the desired function. In addition, it may be necessary to need these: a file system (perhaps in the ROM or RAM) TCP / IP network stack to the system, do not floppy; do not smp, mtrr; do not networking, scsi; put all Block Device removal, leaving only IDE Device; removes all Character Device; removes all FileSystem, leaving only Minix; do not support. This has been removed by all options. After doing this, I got a 188K core. Use -O3 and -O2 in the following two files. ./Makefile ./rch/i386/kernel/ makefile This, the entire core is 9K, becomes 179K. However, this core is probably hard to play Linux's function, so add the network back. Plug the NetWork Support in General Setup, recompile, the core turns 189 K. 10K plus a TCP / IP Stack. There is no Driver with Stack, and the use of the RTL8139 of the Embedded Board back, 195K. If you need a DOS archive system, the size is 213K. If MinIX is replaced with EXT2, the size is grown to 222K. The memory required for Linux is approximately between 600K ~ 800K. 1MB memory may be booted, but it is not useful because it is difficult to connect to the C library. 2MB memory should do something, but to 4MB or more can execute a relatively complete system. Because Linux's FileSystem is quite large, approximately 230K, accounting for 1/3 volume. Memory management accounts for 80K, and the sum of the core other parts is similar. TCP / IP Stack accounted for 65K, and the driver accounted for 120K. Sysv IPC accounts for 21K, if necessary, can take it, the core file should be around 10K. If you want to crop the core size, should you move? The answer is obvious, of course, the file system. Linux's VFS simplifies archive system design, Buffer Cache, Directory Cache adds the efficiency of the system. However, these Embedded systems are not only available at all. If you can take them, the core can be left right away from 20K. If you skip the entire VFS, write the file system directly into a DRIVER model, you should reduce 230K to about 50K. The whole core is reduced to around 100K.
The kernel of the industrial computer is not strict for the core of the industrial computer, and the key requirement is not strict. The key is the correctness, robustness and real-time (some machine requirements are highly real-time). Single, but to ensure the correctness Network on-demand. You can configure the following: Symmetric Multi-Processing Support: yloadable module support: N Industrial Control Machine Generally mounted modules all loaded into memory. NetWorking Support: Y System V IPC: Y Kernel Supply for ELF BINARIES: Y Block Devices: According to the specific hardware configuration network: y, the general industrial computer is connected to the LAN connection according to the specific needs, and the IPX protocol is isolated from the outside world, and the other TCP / IP is generally also needed. QoS and / or fair Queueing: Y Qos (QUALITY OF FAEUELING is a network thread table scheduled for a package, can be sorted for multiple network packets and sequencing according to priority processing, called packet schedules. this Features, especially for real-time systems, when multiple packets are sent to network devices, KERNEL can determine which package must be prioritized. So Kernel provides several packet scheduleuling algorithm. FileSystems Second Extended Fs Support: y The remaining configuration and small embedded systems are different. The kernel size compiled on the same machine is the kernel of more than 800 KB servers: the server's kernel is critical to network settings and process schedules. Do as follows: Symmetric Multi-Processing Support : Y loadable module support: y NetWorking Support: y NetWorking Option Packet Socket: Y. TCP / IP NetWorkeing: Y NetWork FireWalls: Do you use a network firewall. If the computer wants to be FireWalls Server or the network structure of the TCP / IP communication protocol, this item is selected [Y] NetWork Aliasing [Y / M / N /?]: Computer on a network can have Multi-group IP address. If the computer wants to have multiple IP addresses, select [Y]. IP: Forwarding / Gatewaying [Y / M / N /?]: If the user wants to be router, select [Y], but the prerequisite is "two "NIC, a pair of external networks, one for internal networks, and use of ISP that must set ROUTING, allowing users to do this router. IP: MULTICASTING: You can complete the operation of sending a packet to a few computers at once. IP: SYN_COOKIES: A protection measures to encrypt various TCP / IP communication protocols to prevent Attacker attack users, and can record the IP address of the computer's computer. IP: FireWalling: This computer is a firewall server IP: FireWall Packet Logging: Does the Klogd Record Firewall Server to receive which packet. IP: MasqueReding: You can send the internal network computer to the package, pass the firewall server directly to The remote computer, while the remote computer see is the package that the received firewall server is sent, not from the internal computer. This, if there is only one computer to go online, the remaining machines can connect to the firewall server of this machine. Select this option must first determine the previous NetWork FireWalls IP: Forwarding / Gatewaying IP: FireWalling These three options Select [Y].