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

linux ¹²ÏíÄÚ´æµÄɾ³ý

ʹÓÃshmget£¨£©µÃµ½µÄ¹²ÏíÄڴ棬ÔÚËùÓнø³Ì¶¼Ê¹ÓÃshmdt£¨£©ÓëÖ®·ÖÀëºó£¬ÏµÍ³ÊÇ·ñ»á×Ô¶¯É¾³ýÕâ¸ö¹²ÏíÄÚ´æ¡£
Èç¹ûµ÷ÓÃshmat£¨£© ʧ°Ü£¬±ã²»ÄÜʹÓÃshmdt£¨£©ÁË£¬ÕâʱºòÓÖÔõôɾ³ý¹²ÏíÄÚ´æÄØ£¿

²»»á×Ô¶¯É¾³ý
shmctl(shmid, IPC_RMID, NULL);

shmdt ²»ÊÇɾ³ý

Èç¹ûÁ½¸ö½ø³Ì¶¼Ê¹ÓÃÁË shmctl(shmid, IPC_RMID, NULL); ºóÃæµÄ»áʧ°ÜÂð£¿

¹²ÏíÄÚ´æÊÇÓÉÄں˹ÜÀí£¬Äãµ÷ÓÃÁËshmctl(shmid,IPC_RMID,NULL);Ö®ºóÍ˳ö³ÌÐò£¬Èç¹û»¹ÓÐÆäËû½ø³ÌʹÓÃÕâ¿é¹²ÏíÄڴ棬ÄÇôÄں˻¹»á±£ÁôÕâ¿éÄÚ´æÇøÓò£¬Ö±µ½Ã»Óнø³ÌʹÓÃÕâ¿éÄÚ´æ¡£
Äã¿ÉÒÔÔÚ³ÌÐòÖнøÐвâÊÔ£¬ÔÚ³ÌÐòÔËÐÐÇ° ÔËÐÐÖÐ ÔËÐкó
SHELLÀïÊäÈëipcs -m²é¿´¹²ÏíÄÚ´æÐÅÏ¢

ÕâÕýÊÇÎÒÒªµÄ´ð°¸£¬Ð»Ð»£¡

µÚÒ»¸ö½ø³Ìµ÷Óà shmctl(shmid,IPC_RMID,NULL)ɾ³ýÄÚ´æÖ®ºó£¬µÚ¶þ¸ö½ø³ÌÔÙµ÷ÓÃshmctl(shmid,IPC_RMID,NULL)¾Í»áʧ°Ü¡£ÕâÑùµÄ»° ¼ì²éshmctl£¨£© µÄ·µ»ØÖµÊDz»ÊÇûÓÐÒâÒåÁË£¿


Ïà¹ØÎÊ´ð£º

linux»·¾³ÏÂgethostbynameº¯ÊýÎÊÌâ - C/C++ / CÓïÑÔ

дÁ˸ö²âÊÔ³ÌÐòÈçÏÂ
   
  struct hostent *hp; 
char AlarmDevIP[20];  
  int x2;

hp = gethostbyname("www.google.com");
if (hp)
{ ......

Linux Ŀ¼ÎÊÌâ

LinuxÐÂÊÖ£¬Çë´ó¸ç´ó½ã²»Òª¼ûЦ¡£

ÎÒÓÃrootÓû§µÇ¼µ½Linuxϵͳ¡£ÔÚ¸ùĿ¼ÏÂÃ潨ÁËĿ¼dir1£¬ºóÓÃÃüÁîcd /dir1½øÈëµ½dir1Ŀ¼Ï£¬È»ºóÔÙÓÃmkdir dir2½¨Á¢ÁËĿ¼dir2 £¬ÔÙºóÀ´ÓÃÃüÁîcd /dir2ÊÇ£¬ÌáʾΪ£º-bush ......

php±àдִÐÐlinux shellÃüÁîµÄ´úÂë

ʹÓÃPHPµÄexecº¯Êýµ÷ÓÃlinuxµÄshellÃüÁÈçdateÈ¥ÐÞ¸Äʱ¼ä»òshutdownȥʵÏֹػú/ÖØÆô£¬µ«ÊÇ·µ»ØÖµ¶¼ÊÇʧ°ÜµÄ¡£¾­¹ý¶à´ÎÊÔÑ飬È϶¨ÊÇûÓÐȨÏÞµÄÎÊÌâ¡£
ËùÒÔ£¬Ð¡µÜÔÚ´ËÇë½Ì¸÷룬ÈçºÎ²ÅÄÜÉèÖÃȨÏÞ£¬µ÷ÓÃlinux shellà ......

LinuxÏ°²×°ÎÊÌâ

Ô­ÏȵÄGCC°æ±¾Îª4.1.2,ÎÒÖØбàÒë°²×°ÁËGCC4.3.2£¬µ«ÊDZàÒëÍê³ÌÐòÔËÐгÌÐòʱ»á³öÏÖversion `GLIBCXX_3.4.9' not found Õâ¸öÎÊÌ⣬ÎÒ²»Ì«Ã÷°×Ôõô»ØÊ£¬Çë¸÷λ´óϺָµãһϡ£
ÊÖ¶¯ÔÙ×°Ò»´Îglibc*_3.4.9

ÕâÊÇÎ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ