LINUX¼ÆËãCPU¡¢ÄÚ´æµÄʹÓÃÂÊ
"procÎļþϵͳÊÇÒ»¸öαÎļþϵͳ£¬ËüÖ»´æÔÚÄÚ´æµ±ÖУ¬¶ø²»Õ¼ÓÃÍâ´æ¿Õ¼ä¡£ËüÒÔÎļþϵͳµÄ·½Ê½Îª·ÃÎÊϵͳÄÚºËÊý¾ÝµÄ²Ù×÷Ìṩ½Ó¿Ú¡£Óû§ºÍÓ¦ÓóÌÐò¿ÉÒÔͨ¹ýprocµÃµ½ÏµÍ³µÄÐÅÏ¢£¬²¢¿ÉÒԸıäÄں˵ÄijЩ²ÎÊý¡£"
ÕâÀォ½éÉÜÈçºÎ´Ó/procÎļþϵͳÖлñÈ¡Óë·À»ðǽÏà¹ØµÄһЩÐÔÄܲÎÊý£¬ÒÔ¼°ÈçºÎͨ¹ý/procÎļþϵͳÐÞ¸ÄÄں˵ÄÏà¹ØÅäÖá£
1¡¢´Ó/procÎļþϵͳ»ñÈ¡Ïà¹ØµÄÐÔÄܲÎÊý
cpuʹÓÃÂÊ£º /proc/stat
ÄÚ´æʹÓÃÇé¿ö£º /proc/meminfo
ÍøÂ縺ÔØÐÅÏ¢£º /proc/net/dev
ÏàÓ¦µÄ¼ÆËã·½·¨£º(Õª×Ô£ºÊ²Ã´ÊÇprocÎļþϵͳ£¬¼û²Î¿¼×ÊÁÏ)
£¨1£© ´¦ÀíÆ÷ʹÓÃÂÊ
£¨2£© ÄÚ´æʹÓÃÂÊ
£¨3£© Á÷ÈëÁ÷³öÊý¾Ý°ü
£¨4£© ÕûÌåÍøÂ縺ÔØ
ÕâЩÊý¾Ý·Ö±ðÒª´Ó/proc/stat¡¢/proc/net/dev¡¢/proc/meminfoÈý¸öÎļþÖÐÌáÈ¡¡£ÈçÀïÓÐÎÊÌâ»ò¶ÔÒªÌáÈ¡µÄÊý¾Ý²»Ì«Çå³þ£¬¿ÉÒÔʹÓÃman procÀ´²é¿´procÎļþϵͳµÄÁª»úÊֲᡣ
£¨1£© ´¦ÀíÆ÷ʹÓÃÂÊ
ÕâÀïÒª´Ó/proc/statÖÐÌáÈ¡ËĸöÊý¾Ý£ºÓû§Ä£Ê½£¨user£©¡¢µÍÓÅÏȼ¶µÄÓû§Ä£Ê½£¨nice£©¡¢ÄÚºËģʽ£¨system£©ÒÔ¼°¿ÕÏеĴ¦ÀíÆ÷ʱ¼ä£¨idle£©¡£ËüÃǾùλÓÚ/proc/statÎļþµÄµÚÒ»ÐС£CPUµÄÀûÓÃÂÊʹÓÃÈçϹ«Ê½À´¼ÆËã¡£
CPUÀûÓÃÂÊ = 100 *£¨user + nice + system£©/£¨user + nice + system + idle£©
£¨2£© ÄÚ´æʹÓÃÂÊ
ÕâÀïÐèÒª´Ó/proc/meminfoÎļþÖÐÌáÈ¡Á½¸öÊý¾Ý£¬µ±Ç°ÄÚ´æµÄʹÓÃÁ¿(cmem)ÒÔ¼°ÄÚ´æ×ÜÁ¿(amem)¡£
ÄÚ´æʹÓÃ°Ù·Ö±È = 100 * (cmem /&
Ïà¹ØÎĵµ£º
ÀýÒ»£º·¢ËÍSignaling Packet£º
Signaling CommandÊÇ2¸öBluetoothʵÌåÖ®¼äµÄL2CAP²ãÃüÁî´«Êä¡£ËùÒÔµÃSignaling CommandʹÓÃCID 0x0001.
¶à¸öCommand¿ÉÒÔÔÚÒ»¸öC-frame£¨control frame£©Öз¢ËÍ¡£
Èç¹ûÒªÖ±½Ó·¢ËÍSignaling Command.ÐèÒª½¨Á¢SOCK_RAWÀàÐ͵ÄL2CAPÁ¬½ÓSocket¡£ÕâÑù²ÅÓлú»á×Ô¼ºÌî³äCommand Code£¬Identi ......
ÓÐÐí¶àÊ£¬ÐèÒª»Øµ½u-boot²ÅÄÜ˵Çå³þ……
include\configs\XXXX.hÖУ¨XXXXÊÓ¾ßÌåƽ̨¶ø¶¨£©£¬Ò»°ã»á×÷ÀàËÆÈç϶¨Ò壺
#define CONFIG_BOOTCOMMAND "mmcinit; fatload mmc 0 0x81c00000 uImage; bootm 0x81c00000"
±àÒëʱ¸ÃºêCONFIG_BOOTCOMMAND´«µÝ¸øÒ»¸öENVÏîbootcmd£¬¶øÔÚcommon\main.cÖУ¬º¯Êýmain_loopÈ ......
ϵͳÊÕµ½Óʼþ¶¼»á±£´æÔÚ“/var/spool/mail/[linuxÓû§Ãû]”ÎļþÖС£
ÔÚlinuxÖÐÊäÈëmail£¬¾Í½øÐÐÁËÊÕ¼þÏ䣬²¢ÏÔʾ¶þÊ®·âÓʼþÁÐ±í¡£
´ËʱÃüÁîÌáʾ·ûΪ"&"
unread ±ê¼ÇΪδ¶ÁÓʼþ
h|headers ÏÔʾµ±Ç°µÄÓʼþÁбí
l|list ÏÔʾµ±Ç°Ö§³ÖµÄÃüÁîÁбí
?|help ÏÔʾ¶à¸ö²é¿´ÓʼþÁбíµÄÃüÁî²ÎÊýÓ÷¨
d ɾ³ýµ±Ç°ÓÊ ......
New things to learn about Linux Scheduler):
1. Rotating Staircase Deadline cpu scheduler policy
2. CFS (Completely Fair Scheduler)
3. BFS (Brain Fuck Scheduler)
http://lwn.net/Articles/
http://kerneltrap.org/
......
/*
*By Neil Chiao (neilchiao at gmail.com)
*תÔØÇë×¢Ã÷³ö´¦£ºneilengineer.cublog.cn
*±¾ÎIJ¿·ÖÄÚÈÝÀ´×ÔÍøÂç
*»¶Óµ½“ÐÂÐÇÍå(www.xinxingwan.com)”Ö¸µ¼
*/
1¡¢LinuxÍøÂçÉ豸Çý¶¯µÄÌåϵ½á¹¹
LinuxÍøÂçÇý¶¯³ÌÐòµÄÌåϵ½á¹¹¿É»®·ÖΪ4¸ö²ã´Î¡£LinuxÄÚºËÔ´´úÂëÖÐÌṩÁËÍøÂçÉ豸½Ó¿Ú¼°ÒÔÉϲã´ÎµÄ´ ......