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

LINUX Ï̺߳¯Êý´óÈ«


LINUX Ï̺߳¯Êý´óÈ«
Ïß³Ì
´´½¨Ò»¸öȱʡµÄÏß³Ì
ȱʡµÄÏ̵߳ÄÊôÐÔ£º
l         ·Ç°ó¶¨
l         δ·ÖÀë
l         Ò»¸öȱʡ´óСµÄ¶ÑÕ»
l         ¾ßÓк͸¸Ïß³ÌÒ»ÑùµÄÓÅÏȼ¶
Óà phread_attr_init() ´´½¨Ò»¸öȱʡµÄÊôÐÔ¶ÔÏó£¬
ÓÃÊôÐÔ¶ÔÏó´´½¨Ò»¸öÏß³Ì pthread_create(3T)
int p thread_create ( pthread_t *tid, const pthread_attr_t *tattr, void *(*start_routine)(void*), void *arg );
#include<pthread.h>
pthread_attr_t  tattr;
pthread_t  tid;
extern  void  *start_routine(void *arg);
void  *arg;
int  ret;
/*default behavior*/
ret = pthread_create( &tid, NULL, start_routine, arg );
/*init with default attributes*/
ret = pthread_attr_init( &tattr );
/*default behavior specified*/
ret = pthread_create( &tid, &tattr, start_routine, arg );
tattr Öк¬Óгõʼ»¯Ïß³ÌËùÐèµÄÊôÐÔ£¬Öµ¸³Îª NULL ¼´È±Ê¡¡£ start_routine ÊÇÏß³ÌÈë¿Úº¯ÊýµÄÆðʼµØÖ·¡£µ± start_routine ·µ»Øʱ£¬ÏàÓ¦µÄÏ߳̾ͽáÊøÁË¡£Ï߳̽áÊøʱµÄÍ˳ö״ֵ̬ÊÇ start_routine º¯ÊýÓà phread_exit() º¯Êý·µ»ØµÄ·µ»ØÖµ¡£µ± pthread_create() º¯Êýµ÷Óóɹ¦Ê±£¬Ï̱߳êʶ·û±£´æÔÚ²ÎÊý tid Ö¸ÕëÖ¸ÏòÖС£
·µ»ØÖµ£¬ pthread_create() ³É¹¦ºó·µ»Ø 0 £¬
EAGAIN ³¬¹ýÁËij¸öÏÞÖÆ£¬Èç LWPs ¹ý¶à¡£
EINVAL   tattr Öµ·Ç·¨¡£
´´½¨×ÓÏß³Ìʱ£¬´«¸ø×ÓÏ̵߳ÄÊäÈë²ÎÊý×îºÃÊÇ malloc() ·µ»ØµÄÖ¸Õ루ÕâÑùµÄÖ¸ÕëÖ¸Ïò½ø³Ì¶ÑÖеĴ洢¿Õ¼ä£©»òÖ¸ÏòÈ«¾Ö±äÁ¿µÄÖ¸Õ룬¶ø²»ÒªÊÇÖ¸Ïò¾Ö²¿±äÁ¿µÄÖ¸Õë¡£ÒòΪµ±×ÓÏ̷߳ÃÎÊÊäÈë²ÎÊýʱ£¬´´½¨×ÓÏ̵߳ĺ¯Êý¿ÉÄÜÒѽáÊø£¬¾Ö²¿±äÁ¿Ò²¾Í²»´æÔÚÁË¡£
µÈ´ýÏ߳̽áÊø
       pthread_join(3T)
       int pthread_join( pthread_t tid, void **status );
       #include<pthread.h>
       pthread_t  tid;
       int  ret;
       int  status;
   &nbs


Ïà¹ØÎĵµ£º

Installing PHP APC on GNU/Linux Centos 5

Ô­Ìù£ºhttp://2bits.com/articles/installing-php-apc-gnulinux-centos-5.html
Published Mon, 2008/03/24 - 13:49, Updated Wed, 2009/07/15 - 23:40
Complex PHP applications, such as Drupal, can gain a lot of performance benefits from running a PHP op-code cache/accelerators
.
APC,
Alternate ......

linuxÏÂmysqlµÄʹÓÃ


Æô¶¯mysql:  /etc/rc.d/init.d/mysql start
ÐÞ¸ÄÃÜÂë: ¸ñʽ£ºmysqladmin -uÓû§Ãû -p¾ÉÃÜÂë password ÐÂÃÜÂë
ʹÓÃÃÜÂëµÇ¼:  mysql -u root -p
ÏÔʾÊý¾Ý¿â:  show databases;
Ñ¡ÔñÊý¾Ý¿â:  use Êý¾Ý¿âÃû;
ÏÔʾ±í:  show tables;
ÏÔʾ±í½á¹¹:  descibe ±íÃû;
Ô¶³ÌµÇ¼mysqlÐèÒª¿ªÆôÈ ......

ÔÚLinux 2.6ÄÚºËϱàÒë¿ÉÒÔ¼ÓÔصÄÄÚºËÄ£¿é(ת)

  By:
ÎâÛó Date:
2007-05-18 Email:
lazy_fox#msn.com Homepage:
http://blog.csdn.net/wooin Link:
http://blog.csdn.net/wooin/archive/2007/05/21/1619141.aspx °æȨÐÅÏ¢£º
¸ÃÎÄÕ°æȨÓÉWu YinËùÓС£¿ÉÔÚ·ÇÉÌҵĿµÄÏÂÈÎÒâ´«²¥ºÍ¸´ÖÆ¡£
¶ÔÓÚÉÌҵĿµÄ϶Ա¾ÎĵÄÈκÎÐÐΪÐè¾­×÷Õß ......

ÔÚlinuxÏ°²×°ºÍÅäÖÃApache+PHP

£¨1£© °²×°ºÍÅäÖÃApache
      ÔÚÈçÏÂÒ³ÃæÏÂÔØapacheµÄfor Linux µÄÔ´Âë°ühttp://www.apache.org/dist/httpd/
¡¡¡¡´æÖÁ/home/xxĿ¼£¬xxÊÇ×Ô½¨Îļþ¼Ð£¬ÎÒ½¨ÁËÒ»¸öwhyµÄÎļþ¼Ð¡£
¡¡¡¡ÃüÁîÁÐ±í£º¡¡¡¡
              & ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ