Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

Linux»·¾³½ø³Ì¼äͨÐÅ£¨Î壩: ¹²ÏíÄڴ棨ÉÏ£©


 
 
ÎĵµÑ¡Ïî
 
½«´ËÒ³×÷Ϊµç×ÓÓʼþ·¢ËÍ
¼¶±ð£º ³õ¼¶
Ö£ÑåÐË (mlinux@163.com), ¹ú·À¿Æ´ó¹¥¶Á²©Ê¿Ñ§Î»
2003 Äê 5 ÔÂ 01 ÈÕ
¹²ÏíÄÚ´æ¿ÉÒÔ˵ÊÇ×îÓÐÓõĽø³Ì¼äͨÐÅ·½Ê½£¬Ò²ÊÇ×î¿ìµÄIPCÐÎʽ¡£Á½¸ö²»Í¬½ø³ÌA¡¢B¹²ÏíÄÚ´æµÄÒâ˼ÊÇ£¬Í¬Ò»¿éÎïÀíÄÚ´æ±»Ó³Éäµ½½ø³ÌA¡¢B¸÷×ԵĽø³ÌµØÖ·¿Õ¼ä¡£½ø³ÌA¿ÉÒÔ¼´Ê±¿´µ½½ø³ÌB¶Ô¹²ÏíÄÚ´æÖÐÊý¾ÝµÄ¸üУ¬·´Ö®ÒàÈ»¡£ÓÉÓÚ¶à¸ö½ø³Ì¹²Ïíͬһ¿éÄÚ´æÇøÓò£¬±ØÈ»ÐèҪijÖÖͬ²½»úÖÆ£¬»¥³âËøºÍÐźÅÁ¿¶¼¿ÉÒÔ¡£
²ÉÓù²ÏíÄÚ´æͨÐŵÄÒ»¸öÏÔ¶øÒ×¼ûµÄºÃ´¦ÊÇЧÂʸߣ¬ÒòΪ½ø³Ì¿ÉÒÔÖ±½Ó¶ÁдÄڴ棬¶ø²»ÐèÒªÈκÎÊý¾ÝµÄ¿½±´¡£¶ÔÓÚÏñ¹ÜµÀºÍÏûÏ¢¶ÓÁеÈͨÐÅ·½Ê½£¬ÔòÐèÒªÔÚÄں˺ÍÓû§¿Õ¼ä½øÐÐËĴεÄÊý¾Ý¿½±´£¬¶ø¹²ÏíÄÚ´æÔòÖ»¿½±´Á½´ÎÊý¾Ý[1]£ºÒ»´Î´ÓÊäÈëÎļþµ½¹²ÏíÄÚ´æÇø£¬ÁíÒ»´Î´Ó¹²ÏíÄÚ´æÇøµ½Êä³öÎļþ¡£Êµ¼ÊÉÏ£¬½ø³ÌÖ®¼äÔÚ¹²ÏíÄÚ´æʱ£¬²¢²»×ÜÊǶÁдÉÙÁ¿Êý¾Ýºó¾Í½â³ýÓ³É䣬ÓÐеÄͨÐÅʱ£¬ÔÙÖØн¨Á¢¹²ÏíÄÚ´æÇøÓò¡£¶øÊDZ£³Ö¹²ÏíÇøÓò£¬Ö±µ½Í¨ÐÅÍê±ÏΪֹ£¬ÕâÑù£¬Êý¾ÝÄÚÈÝÒ»Ö±±£´æÔÚ¹²ÏíÄÚ´æÖУ¬²¢Ã»ÓÐд»ØÎļþ¡£¹²ÏíÄÚ´æÖеÄÄÚÈÝÍùÍùÊÇÔÚ½â³ýÓ³Éäʱ²Åд»ØÎļþµÄ¡£Òò´Ë£¬²ÉÓù²ÏíÄÚ´æµÄͨÐÅ·½Ê½Ð§ÂÊÊǷdz£¸ßµÄ¡£
LinuxµÄ2.2.xÄÚºËÖ§³Ö¶àÖÖ¹²ÏíÄڴ淽ʽ£¬Èçmmap()ϵͳµ÷Óã¬Posix¹²ÏíÄڴ棬ÒÔ¼°ÏµÍ³V¹²ÏíÄÚ´æ¡£linux·¢Ðа汾ÈçRedhat 8.0Ö§³Ömmap()ϵͳµ÷Óü°ÏµÍ³V¹²ÏíÄڴ棬µ«»¹Ã»ÊµÏÖPosix¹²ÏíÄڴ棬±¾ÎĽ«Ö÷Òª½éÉÜmmap()ϵͳµ÷Óü°ÏµÍ³V¹²ÏíÄÚ´æAPIµÄÔ­Àí¼°Ó¦Óá£
Ò»¡¢ÄÚºËÔõÑù±£Ö¤¸÷¸ö½ø³ÌÑ°Ö·µ½Í¬Ò»¸ö¹²ÏíÄÚ´æÇøÓòµÄÄÚ´æÒ³Ãæ
1¡¢page cache¼°swap cacheÖÐÒ³ÃæµÄÇø·Ö£ºÒ»¸ö±»·ÃÎÊÎļþµÄÎïÀíÒ³Ã涼פÁôÔÚpage cache»òswap cacheÖУ¬Ò»¸öÒ³ÃæµÄËùÓÐÐÅÏ¢ÓÉstruct pageÀ´ÃèÊö¡£struct pageÖÐÓÐÒ»¸öÓòΪָÕëmapping £¬ËüÖ¸ÏòÒ»¸östruct address_spaceÀàÐͽṹ¡£page cache»òswap cacheÖеÄËùÓÐÒ³Ãæ¾ÍÊǸù¾Ýaddress_space½á¹¹ÒÔ¼°Ò»¸öÆ«ÒÆÁ¿À´Çø·ÖµÄ¡£
2¡¢ÎļþÓëaddress_space½á¹¹µÄ¶ÔÓ¦£ºÒ»¸ö¾ßÌåµÄÎļþÔÚ´ò¿ªºó£¬Äں˻áÔÚÄÚ´æÖÐΪ֮½¨Á¢Ò»¸östruct inode½á¹¹£¬ÆäÖеÄi_mappingÓòÖ¸ÏòÒ»¸öaddress_space½á¹¹¡£ÕâÑù£¬Ò»¸öÎļþ¾Í¶ÔÓ¦Ò»¸öaddress_space½á¹¹£¬Ò»¸öaddress_spaceÓëÒ»¸öÆ«ÒÆÁ¿Äܹ»È·¶¨Ò»¸öpage cache »òswap cacheÖеÄÒ»¸öÒ³Ãæ¡£Òò´Ë£¬µ±ÒªÑ°Ö·Ä³¸öÊý¾Ýʱ£¬ºÜÈÝÒ׸ù¾Ý¸ø¶¨µÄÎļþ¼°Êý¾ÝÔÚÎļþÄÚµÄÆ«ÒÆÁ¿¶øÕÒµ½ÏàÓ¦µÄÒ³Ãæ¡£
3¡¢½ø³Ìµ÷ÓÃmmap()ʱ£¬Ö»ÊÇÔÚ½ø³Ì¿Õ¼äÄÚÐÂÔöÁËÒ»¿éÏàÓ¦´óСµÄ»º³åÇø£¬²¢ÉèÖÃÁËÏàÓ¦µÄ·ÃÎʱêʶ£¬


Ïà¹ØÎĵµ£º

LinuxÉ豸Çý¶¯¿ª·¢Ïê½â ±Ê¼Ç2 Çý¶¯Éè¼ÆµÄÓ²¼þ»ù´¡

´¦ÀíÆ÷µÄ·ÖÀ࣬ÈçÏÂͼËùʾ£º
´æ´¢Æ÷¿É·ÖΪֻ¶Á´æ´¢Æ÷£¨ROM£©¡¢ÉÁ´æ£¨Flash£©¡¢Ëæ»ú´æÈ¡´æ´¢Æ÷£¨RAM£©¡¢¹â½éÖÊ´æ´¢Æ÷ºÍ´Å½éÖÊ´æ´¢Æ÷
Nor FlashºÍcpuµÄ½Ó¿ÚÊôÓÚµäÐ͵ÄÀàSRAM½Ó¿Ú£¬²»ÐèÒªÔö¼Ó¶îÍâµÄ¿ØÖƵç·¡£Nor FlashµÄÌصãÊÇ¿ÉоƬÄÚÖ´ÐУ¬³ÌÐò¿ÉÒÔÖ±½ÓÔÚNorÄÚÔËÐС£¶øNand FashºÍcpuµÄ½Ó¿Ú±ØÐëÓÉÏàÓ¦µÄ¿ØÖƵç·½øÐÐת»»£ ......

Linuxѧϰ³õ¼Ç


ÎҵĵÚÒ»¸öshell³ÌÐò£ºtt1.sh
while true
do
       date;
       sleep 1;
done
Ö´Ðз½Ê½1£ºsh tt1.sh
Ö´Ðз½Ê½2£º./tt1.sh£¨ÒªÇó¸ÃÎļþÓпÉÖ´ÐÐȨÏÞ£©
Shell±äÁ¿£º
»·¾³±äÁ¿£º
       ¹¤¾ß£ºecho »ØÏÔ
 &n ......

linux°²×°JDK

Ê×ÏÈ£¬´Óhttp://java.sun.comÖÐÏÂÔØjdk,Îҵİ汾ÊÇjdk1.6.0_20
È»ºó£¬ÖÕ¶ËÊäÈë
´úÂë:
sudo chmod u+x /£¨Â·¾¶Ãû³Æ£©/jdk1.6.0_12.bin
ÐÞ¸ÄbinÎļþȨÏÞ£¬Ê¹Æä¿ÉÖ´ÐÐ
È»ºó£¬Ö´ÐÐ
´úÂë:
sudo £¨Â·¾¶Ãû³Æ£©/jdk1.6.0_20.bin
½«»á³öÏÖ×ÖÄ»£¬³ÖÐø°´»Ø³µ¼ü£¬Ö±ÖÁÆÁÄ»ÏÔʾҪÇóÊäÈë yes/no£¬´ËʱÊäÈëy»Ø³µ£¬½«»á°Ñjdk½âѹµ½Î ......

Linux¾²Ì¬¿âºÍ¶¯Ì¬¿â

¿â´Ó±¾ÖÊÉÏÀ´ËµÊÇÒ»ÖÖ¿ÉÖ´ÐдúÂëµÄ¶þ½øÖƸñʽ£¬¿ÉÒÔ±»ÔØÈëÄÚ´æÖÐÖ´ÐС£¿â·Ö¾²Ì¬¿âºÍ¶¯Ì¬¿âÁ½ÖÖ¡£ 
¾²Ì¬¿âºÍ¶¯Ì¬¿âµÄÇø±ð
1. ¾²Ì¬º¯Êý¿â
    ÕâÀà¿âµÄÃû×ÖÒ»°ãÊÇlibxxx.a£»ÀûÓþ²Ì¬º¯Êý¿â±àÒë³ÉµÄÎļþ±È½Ï´ó£¬ÒòΪÕû¸ö º¯Êý¿âµÄËùÓÐÊý¾Ý¶¼»á±»ÕûºÏ½øÄ¿±ê´úÂëÖУ¬ËûµÄÓŵã¾ÍÏÔ¶øÒ×¼ûÁË£¬¼´±àÒëºóµÄÖ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ