Linux ÄÚ´æ°ó¶¨ÔÚ¾Ö²¿´æ´¢Æ÷µÄʵÏÖ
3.2.1 Linux ÄÚ´æ°ó¶¨ÔÚ¾Ö²¿´æ´¢Æ÷µÄʵÏÖ×ÜÌå²½Öè
×ÜÌå²½Ö裺
l ²ÉÓ÷½°¸Èý£¬ÔÚÔÚÔÀ´·ÖÎöµÄ»ù´¡ÉÏ£¬ÒÔ¼°ÒÑÖªLinuxϵͳÄÚ´æµÄ³õʼ»¯µÄÇé¿ö£¬¶ÔÄں˴úÂë½øÐÐÐ޸ģ¬Ö÷Òª°üÀ¨È·¶¨ÐÂÇøµÄ·¶Î§£¬½¨Á¢ÐÂÇø£¬ÖØжԷÖÅäÄÚ´æµÄ·ÖÅä»úÖƽøÐÐÉèÖá£
l ÐÂÇø»®·Öºó£¬¶Ôн¨µÄÁ½¸öÇø½øÐÐÒ»¶¨³Ì¶ÈÉϵÄÑÓ³Ù£»
l ½¨Á¢ÏµÍ³µ÷Óã¬ÏµÍ³µ÷Óý«ÌṩÓû§½øÐÐÊÖ¶¯ÉèÖ÷ÃÎÊ·½Ê½¡£
l ¶ÔÄں˽øÐÐÅäÖ㬲¢½øÐÐÏà¹Øµ÷ʽ¡£
l Óû§³ÌÐò½øÐÐ×îÖյIJâÊÔ£¬²¢ÑéÖ¤Ïà¹Ø½áÂÛ¡£
3.2.2 Linux Äں˰ó¶¨ÔÚ¾Ö²¿´æ´¢Æ÷´úÂëʵÏÖ
(Ò»)¡¢Ð޸ĴúÂ룺
1) ÔÚinit/main.cÕâ¸öÎļþÖÐ,ÔÚÕâÒ»¶Î´úÂë
#ifdef CONFIG_X86_LOCAL_APIC
#include <asm/smp.h>
#endif
µÄÏÂÃæÔö¼ÓÕâ¶Î´úÂë:
unsigned long max_normal_low_pfn=0;
EXPORT_SYMBOL(max_normal_low_pfn);
ÕâÀïʹÓÃEXPORT_SYMBOLÊÇÉùÃ÷max_normal_low_pfnÊÇÈ«¾Ö±äÁ¿£¬ËùÓеÄÎļþ¶¼¿ÉÒÔʹÓã¬ËüµÄÓô¦ÊÇΪÁ˱ê¼ÇÐÂÇøZONE_NORMAL_LOWµÄ×î´ó¿ÉÓõÄÒ³¿òºÅ¡£
2) arch/x86/kernel/setup.cÕâ¸öÎļþ£º
l ÔÚstruct boot_params boot_params;
#endifÖ®ºóÌí¼Ó£¬ÉùÃ÷¸Ã±äÁ¿ÒѾÔÚ±ðµÄÎļþÓж¨ÒåÁË
extern unsigned long max_normal_low_pfn;
l ÔÚsetup_arch()Õâ¸öº¯ÊýÖУ¬ÔÚfind_low_pfn_range()Õâ¸öÖ®ºó£¬Ôö¼ÓÕâÒ»¾ä£º
max_normal_low_pfn = max_low_pfn/2;
¸Ã¾äÓÃÓÚ¼ÆËãÐÂÇø(ZONE_NORMAL_LOW)µÄ×î´ó¿ÉÓÃÒ³¿òºÅ¡£
3) ÔÚarch/x86/mm/init_32.cÎļþ
l ÔÚunsigned long max_low_pfn_mapped; unsigned long max_pfn_mapped;Ö®ºóÌí¼Óextern unsigned long max_normal_low_pfn;
l ÔÚstatic void __init zone_sizes_init(void)Õâ¸öº¯ÊýÖÐÔö¼ÓÕâ¾ä´ú
Ïà¹ØÎĵµ£º
×ÜÀÀ
ÓÃiptables -ADC À´Ö¸¶¨Á´µÄ¹æ
Ôò
£¬-AÌí¼Ó -Dɾ³ý -C ÐÞ¸Ä
iptables - [RI] chain rule num rule-specification[option]
ÓÃiptables - RI ͨ¹ý¹æÔòµÄ˳ÐòÖ¸¶¨
iptables -D chain rule num[option]
ɾ³ýÖ¸¶¨¹æÔò
iptables -[LFZ] [chain][option]
ÓÃiptables -LFZ Á´Ãû [Ñ¡Ïî]
iptables -[NX] chain
ÓÃ -NX ......
Ò»¡¢ÒýÑÔ£º
±¾ÎĵµµÄÄÚÈݴ󲿷ÝÄÚÈݶ¼ÊÇ´ÓÍøÉÏÊÕ¼¯¶øÀ´£¬È»ºóÅäºÏһЩеĽØͼ£¨Äں˰汾£ºV2.4.19£©¡£ÔÚÿһÅäÖÃÏîºó»áÓÐÒ»¸öÑ¡ÔñÖ¸ÄϵIJ¿·Ý£¬ÓÃÀ´Ö¸µ¼´ó¼ÒÔõôÑù¸ù¾Ý×Ô¼ºµÄÇé¿öÀ´×öÏàÓ¦µÄÑ¡Ôñ£»»¹ÓÐÔÚÿһ¸ö´óÏîºÍÎĵµµÄ×îºó»áÓÐÒ»¸ö¾Ñé̸£¬ËüÊÇһЩ¸ßÊÖÃÇÔÚÓ¦¶ÔÎÊÌâºÍ´¦ÀíÌØÓÐÓ²¼þʱµÄһЩ¾Ñ飨Õâ¸ö»¹µ ......
×î½ü×öµÄһЩ¹¤×÷ÐèÒªÓõ½Ï̳߳ؼ¼Êõ£¬Òò´Ë²Î¿¼ÁËһЩ×ÊÁϺÍÊé¼®£¬È硶0bug c/c++ÉÌÓù¤³ÌÖ®µÀ¡·¡£
Ϊ´ËÔÚlinuxƽ̨ÉÏÓô¿cдÁËÒ»¸öÏ̳߳صÄʵÏÖ¡£
ÔÚ´ËÁгöÁËÔ´úÂë¡£
Ö÷ÒªÓõ½µÄÊý¾Ý½á¹¹ÓÐ
1.struct thread_pool_t // thread pool µÄʵÏÖ´úÂë
2.struct thread_pool_token_t &nb ......
3.2.1 Linux ÄÚ´æ°ó¶¨ÔÚ¾Ö²¿´æ´¢Æ÷µÄʵÏÖ×ÜÌå²½Öè
×ÜÌå²½Ö裺
l ²ÉÓ÷½°¸Èý£¬ÔÚÔÚÔÀ´·ÖÎöµÄ»ù´¡ÉÏ£¬ÒÔ¼°ÒÑÖªLinuxϵͳÄÚ´æµÄ³õʼ»¯µÄÇé¿ö£¬¶ÔÄں˴úÂë½øÐÐÐ޸ģ¬Ö÷Òª°üÀ¨È·¶¨ÐÂÇøµÄ·¶Î§£¬½¨Á¢ÐÂÇø£¬ÖØжԷÖÅäÄÚ´æµÄ·ÖÅä»úÖƽøÐÐÉèÖá£
l &n ......
3.2.1 Linux ÄÚ´æ°ó¶¨ÔÚ¾Ö²¿´æ´¢Æ÷µÄʵÏÖ×ÜÌå²½Öè
×ÜÌå²½Ö裺
l ²ÉÓ÷½°¸Èý£¬ÔÚÔÚÔÀ´·ÖÎöµÄ»ù´¡ÉÏ£¬ÒÔ¼°ÒÑÖªLinuxϵͳÄÚ´æµÄ³õʼ»¯µÄÇé¿ö£¬¶ÔÄں˴úÂë½øÐÐÐ޸ģ¬Ö÷Òª°üÀ¨È·¶¨ÐÂÇøµÄ·¶Î§£¬½¨Á¢ÐÂÇø£¬ÖØжԷÖÅäÄÚ´æµÄ·ÖÅä»úÖƽøÐÐÉèÖá£
l &n ......