Linux ½ø³Ì¹ÜÀí
ͻ񻣼
±¾ÎĽ²ÊöµÄʱ½ø³Ì¹ÜÀíµÄ»ù±¾¸ÅÄîºÍ½ø³Ì¹ÜÀí¹¤¾ß½éÉÜ£»ÎÄÖеÄÖصã¶Ô½ø³Ì¹ÜÀí¹¤¾ßµÄ·ÖÀà½éÉܼ°Ó¦ÓþÙÀý£¬°üÀ¨ ps¡¢pgrep¡¢top
¡¢kill¡¢pkill¡¢killall¡¢niceºÍrenice µÈ¹¤¾ß¡£
http://www.linuxsir.org/main/?q=node/210
1¡¢³ÌÐòºÍ½ø³Ì£»
³ÌÐòÊÇΪÁËÍê³ÉijÖÖÈÎÎñ¶øÉè¼ÆµÄÈí¼þ£¬±ÈÈçOpenOfficeÊdzÌÐò¡£Ê²Ã´Êǽø³ÌÄØ£¿½ø³Ì¾ÍÊÇÔËÐÐÖеijÌÐò¡£
Ò»¸öÔËÐÐ×ŵijÌÐò£¬¿ÉÄÜÓжà¸ö½ø³Ì¡£ ±ÈÈç LinuxSir.Org
ËùÓõÄWWW·þÎñÆ÷ÊÇapache·þÎñÆ÷£¬µ±¹ÜÀíÔ±Æô¶¯·þÎñºó£¬¿ÉÄÜ»áÓкöàÈËÀ´·ÃÎÊ£¬Ò²¾ÍÊÇ˵Ðí¶àÓû§À´Í¬Ê±ÇëÇóhttpd·þÎñ£¬apache·þÎñÆ÷½«»á´´½¨Óжà¸öhttpd½ø³ÌÀ´¶ÔÆä½øÐзþÎñ¡£
1.1 ½ø³Ì·ÖÀࣻ
½ø³ÌÒ»°ã·ÖΪ½»»¥½ø³Ì¡¢Åú´¦Àí½ø³ÌºÍÊØ»¤½ø³ÌÈýÀà¡£
ÖµµÃÒ»ÌáµÄÊÇÊØ»¤½ø³Ì×ÜÊÇ»îÔ¾µÄ£¬Ò»°ãÊǺǫ́ÔËÐУ¬ÊØ»¤½ø³ÌÒ»°ãÊÇÓÉϵͳÔÚ¿ª»úʱͨ¹ý½Å±¾×Ô¶¯¼¤»îÆô¶¯»ò³¬¼¶¹ÜÀíÓû§rootÀ´Æô¶¯¡£±ÈÈçÔÚFedora»òRedhatÖУ¬ÎÒÃÇ¿ÉÒÔ¶¨Òåhttpd
·þÎñÆ÷µÄÆô¶¯½Å±¾µÄÔËÐм¶±ð£¬´ËÎļþλÓÚ/etc/init.dĿ¼Ï£¬ÎļþÃûÊÇhttpd£¬/etc/init.d/httpd
¾ÍÊÇhttpd·þÎñÆ÷µÄÊØ»¤³ÌÐò£¬µ±°ÑËüµÄÔËÐ춱ðÉèÖÃΪ3ºÍ5ʱ£¬µ±ÏµÍ³Æô¶¯Ê±£¬Ëü»á¸ú×ÅÆô¶¯¡£
[root@localhost ~]# chkconfig --level 35 httpd
on
ÓÉÓÚÊØ»¤½ø³ÌÊÇÒ»Ö±ÔËÐÐ×ŵģ¬ËùÒÔËüËù´¦µÄ״̬ÊǵȴýÇëÇó´¦ÀíÈÎÎñ¡£±ÈÈ磬ÎÒÃÇÊDz»ÊÇ·ÃÎÊ LinuxSir.Org £¬LinuxSir.Org
µÄhttpd·þÎñÆ÷¶¼ÔÚÔËÐУ¬µÈ´ý×ÅÓû§À´·ÃÎÊ£¬Ò²¾ÍÊǵȴý×ÅÈÎÎñ´¦Àí¡£
1.2 ½ø³ÌµÄÊôÐÔ£»
½ø³ÌID£¨PID)£ºÊÇΨһµÄÊýÖµ£¬ÓÃÀ´Çø·Ö½ø³Ì£»
¸¸½ø³ÌºÍ¸¸½ø³ÌµÄID£¨PPID)£»
Æô¶¯½ø³ÌµÄÓû§ID£¨UID£©ºÍËù¹éÊôµÄ×飨GID£©£»
½ø³Ì״̬£º×´Ì¬·ÖΪÔËÐÐR¡¢ÐÝÃßS¡¢½©Ê¬Z£»
½ø³ÌÖ´ÐеÄÓÅÏȼ¶£»
½ø³ÌËùÁ¬½ÓµÄÖÕ¶ËÃû£»
½ø³Ì×ÊÔ´Õ¼Ó㺱ÈÈçÕ¼ÓÃ×ÊÔ´´óС£¨ÄÚ´æ¡¢CPUÕ¼ÓÃÁ¿£©£»
1.3 ¸¸½ø³ÌºÍ×Ó½ø³Ì£»
ËûÃǵĹØϵÊǹÜÀíºÍ±»¹ÜÀíµÄ¹Øϵ£¬µ±¸¸½ø³ÌÖÕֹʱ£¬×Ó½ø³ÌÒ²ËæÖ®¶øÖÕÖ¹¡£µ«×Ó½ø³ÌÖÕÖ¹£¬¸¸½ø³Ì²¢²»Ò»¶¨ÖÕÖ¹¡£±ÈÈçhttpd·þÎñÆ÷ÔËÐÐʱ£¬ÎÒÃÇ¿ÉÒÔɱµôÆä×Ó½ø³Ì£¬¸¸½ø³Ì²¢²»»áÒòΪ×Ó½ø³ÌµÄÖÕÖ¹¶øÖÕÖ¹¡£
ÔÚ½ø³Ì¹ÜÀíÖУ¬µ±ÎÒÃÇ·¢ÏÖÕ¼ÓÃ×ÊÔ´¹ý¶à£¬»òÎÞ·¨¿ØÖƵĽø³Ìʱ£¬Ó¦¸ÃɱËÀËü£¬ÒÔ±£»¤ÏµÍ³µÄÎȶ¨°²È«ÔËÐУ»
2¡¢½ø³Ì¹ÜÀí£»
¶ÔÓÚLinux½ø³ÌµÄ¹ÜÀí£¬ÊÇͨ¹ý½ø³Ì¹ÜÀí¹¤¾ßʵÏֵģ¬±ÈÈçps¡¢kill¡¢pgrepµÈ¹¤¾ß£»
2.1 ps ¼àÊÓ½ø³Ì¹¤¾ß£»
ps ΪÎÒÃÇÌṩÁ˽ø³ÌµÄÒ»´ÎÐԵIJ鿴£¬ËüËùÌṩµÄ²é¿´½á¹û²¢²»¶¯Ì¬Á¬ÐøµÄ£»Èç¹ûÏë¶Ô½ø³Ìʱ¼ä¼à¿Ø£¬Ó¦¸ÃÓÃtop¹¤¾ß£»
Ïà¹ØÎĵµ£º
1. HCI²ãÐÒé¸ÅÊö£º
HCIÌṩһÌ×ͳһµÄ·½·¨À´·ÃÎÊBluetoothµ×²ã¡£ÈçͼËùʾ£º
´ÓͼÉÏ¿ÉÒÔ¿´³ö£¬Host Controller Interface(HCI) ¾ÍÊÇÓÃÀ´¹µÍ¨HostºÍModule¡£Hostͨ³£¾ÍÊÇPC£¬ ModuleÔòÊÇÒÔ¸÷ÖÖÎïÀíÁ¬½ÓÐÎʽ£¨USB,serial,pc-cardµÈ£©Á¬½Óµ½PCÉϵÄbluetooth Dongle¡£
ÔÚHostÕâÒ»¶Ë£ºapplication,SDP,L2capµÈÐÒé ......
Service Discovery Protocol(SDP)ÌṩһÖÖÄÜÁ¦£¬ÈÃÓ¦ÓóÌÐòÓз½·¨·¢ÏÖÄÄÖÖ·þÎñ¿ÉÓÃÒÔ¼°ÕâÖÖ·þÎñµÄÌØÐÔ¡£
·þÎñ·¢ÏÖÐÒé(SDP»òBluetooth SDP)ÔÚÀ¶ÑÀÐÒéÕ»ÖжÔÀ¶ÑÀ»·¾³ÖеÄÓ¦ÓóÌÐòÓÐÌØÊâµÄº¬Ò⣬·¢ÏÖÄĸö·þÎñÊÇ¿ÉÓõĺÍÈ·¶¨ÕâЩ¿ÉÓ÷þÎñµÄÌØÕ÷¡£SDP¶¨ÒåÁËbluetooth client·¢ÏÖ¿ÉÓÃbluetooth server·þÎñºÍËüÃǵÄÌØÕ÷µÄ·½·¨¡£ ......
Ò»£ºÇ°ÑÔ
×î½üÔÚÑо¿androidµÄsensor driver£¬Ö÷ÒªÊÇE-compass£¬ÆäÖÐÓõ½ÁËLinux input×Óϵͳ.ÔÚÍøÉÏÒ²¿´Á˺ܶàÕâ·½ÃæµÄ×ÊÁÏ£¬¸Ð¾õ»¹ÊÇÕâƪ·ÖÎöµÄ±È½ÏϸÖÂ͸³¹£¬Òò´ËתÔØÒ»ÏÂÒÔ±ã×Ô¼ºÑ§Ï°£¬Í¬Ê±ºÍ´ó¼Ò·ÖÏí£¡
£¨Õâƪ²©¿ÍÖ÷ÒªÊÇÒÔ¼üÅÌÇý¶¯ÎªÀýµÄ£¬²»¹ý½²½âµÄÊÇLinux Input Subsystem£¬¿ÉÒÔ×ÐϸµÄÑо¿Ò»Ï£¡£©
¼üÅÌÇý¶¯½«¼ì ......
ϵͳµ÷ÓÃÊÇÓ¦ÓóÌʽºÍ²Ù×÷ϵͳÄÚºËÖ®¼äµÄ¹¦Äܽӿڡ£ÆäÖ÷ҪĿµÄÊÇʹµÃÓû§
ÄÜʹÓòÙ×÷ϵͳÌṩµÄÓйØÉ豸¹ÜÀí¡¢ÊäÈë/ÊäÈëϵͳ¡¢ÎļþϵͳºÍ½ø³Ì¿ØÖÆ¡¢
ͨÐż°´æ´¢¹ÜÀíµÈ·½ÃæµÄ¹¦ÄÜ£¬¶ø²»±ØÁ˽âϵͳ³ÌʽµÄÄÚ²¿½á¹¹ºÍÓйØÓ²¼þϸ
½Ú£¬´Ó¶øÆðµ½¼õÇáÓû§¸ºµ£ºÍ±£»¤ÏµÍ³¼°Ìá¸ß×ÊÔ´ÀûÓÃÂʵÄ×÷Óá£
¡¡¡¡Linux²Ù×÷ϵͳ×÷ΪÃâ·ÑÈí¼þ ......
1¡¢ÒýÑÔ
ÔÚlinuxϵͳÏ£¬Èç¹ûÄãÏÂÔز¢°²×°ÁËÓ¦ÓóÌÐò£¬ºÜÓпÉÄÜÔÚ¼üÈëËüµÄÃû³Æʱ³öÏÖ“command not
found”µÄÌáʾÄÚÈÝ¡£Èç¹ûÿ´Î¶¼µ½°²×°Ä¿±êÎļþ¼ÐÄÚ£¬ÕÒµ½¿ÉÖ´ÐÐÎļþÀ´½øÐвÙ×÷¾ÍÌ«·±ËöÁË¡£ÕâÉæ¼°µ½»·¾³±äÁ¿PATHµÄÉèÖÃÎÊÌ⣬¶øPATHµÄÉèÖÃÒ²
ÊÇÔÚlinux϶¨ÖÆ»·¾³±äÁ¿µÄÒ»¸ö×é³É²¿·Ö¡£±¾Î ......