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

¹ØÓÚlinuxÄÚºËÖеÄ"__attribute__ ((packed))"

¹ØÓÚlinuxÄÚºËÖеÄ"__attribute__ ((packed))"  
À´Ô´£º
http://jimmy-lee.blog.hexun.com/8001013_d.html
__attrubte__ ((packed)) µÄ×÷ÓþÍÊǸæËß±àÒëÆ÷È¡Ïû½á¹¹ÔÚ±àÒë¹ý³ÌÖеÄÓÅ»¯¶ÔÆë,°´ÕÕʵ¼ÊÕ¼ÓÃ×Ö½ÚÊý½øÐÐ¶ÔÆë¡£
#define __u8    unsigned char
#define __u16   unsigned short
/* __attribute__ ((packed)) µÄλÖÃÔ¼ÊøÊÇ·ÅÓÚÉùÃ÷µÄβ²¿“£»”֮ǰ */
struct str_struct{
        __u8    a;
        __u8    b;
        __u8    c;
        __u16   d;
} __attribute__ ((packed));
/*  µ±Óõ½typedefʱ£¬ÒªÌرð×¢Òâ__attribute__ ((packed))·ÅÖõÄλÖã¬Ï൱ÓÚ£º
  *  typedef struct str_stuct str;
  *  ¶østruct str_struct ¾ÍÊÇÉÏÃæµÄÄǸö½á¹¹¡£
  */
typedef struct {
        __u8    a;
        __u8    b;
        __u8    c;
        __u16   d;
} __attribute__ ((packed)) str;
/* ÔÚÏÂÃæÕâ¸ötypedef½á¹¹ÖУ¬__attribute__ ((packed))·ÅÔڽṹÃûstr_tempÖ®ºó£¬Æä×÷ÓÃÊDZ»ºöÂԵģ¬×¢ÒâÓë½á¹¹strµÄÇø±ð¡£*/
typedef struct {
        __u8    a;
        __u8    b;
        __u8    c;
        __u16   d;
}str_temp __attribute__ ((packed));
typedef struct {
        __u8    a;
        __u8    b;
        __u8    c;
        __u16   d;
}str_nopacked;
int main(void)
{
        printf("sizeof str = %d\n", sizeof(str));
      


Ïà¹ØÎĵµ£º

Linux iptableÎĵµ

×ÜÀÀ
ÓÃiptables -ADC À´Ö¸¶¨Á´µÄ¹æ
Ôò
£¬-AÌí¼Ó -Dɾ³ý -C ÐÞ¸Ä
iptables - [RI] chain rule num rule-specification[option]
ÓÃiptables - RI ͨ¹ý¹æÔòµÄ˳ÐòÖ¸¶¨
iptables -D chain rule num[option]
ɾ³ýÖ¸¶¨¹æÔò
iptables -[LFZ] [chain][option]
ÓÃiptables -LFZ Á´Ãû [Ñ¡Ïî]
iptables -[NX] chain
ÓÃ -NX ......

Linux µÄ¶àÏ̱߳à³ÌµÄ¸ßЧ¿ª·¢¾­Ñé

2009 Äê 4 ÔÂ 23 ÈÕ
±¾ÎÄÖÐÎÒÃÇÕë¶Ô Linux É϶àÏ̱߳à³ÌµÄÖ÷ÒªÌØÐÔ×ܽá³ö 5 Ìõ¾­Ñ飬ÓÃÒÔ¸ÄÉÆ Linux ¶àÏ̱߳à³ÌµÄϰ¹ßºÍ±ÜÃâÆäÖеĿª·¢ÏÝÚå¡£ÔÚ±¾ÎÄÖУ¬ÎÒÃÇ´©²åһЩ Windows µÄ±à³ÌÓÃÀýÓÃÒÔ¶Ô±È Linux ÌØÐÔ£¬ÒÔ¼ÓÉî¶ÁÕßÓ¡Ïó¡£
±³¾°
Linux ƽ̨ÉϵĶàÏ̳߳ÌÐò¿ª·¢Ïà¶ÔÓ¦ÆäËûƽ̨£¨±ÈÈç Windows£©µÄ¶àÏß³Ì API ÓÐһЩϸ΢ ......

linux£¨unix·þÎñÆ÷£©Ïºǫ́ÔËÐÐmatlab

http://hi.baidu.com/imheaventian/blog/item/c238604f7d3551c6d1c86a0e.html
(cited from:http://hi.baidu.com/yilinghl/blog/item/c9a9be34a459b2bfd1a2d3b5.html)
ºǫ́ÔËÐÐmatlab½Å±¾ÎļþµÄ·½·¨£ºnohup
ʵÏÖ¹¦ÄÜ£º
1. ×Ö·û»·¾³ÏÂÔËÐÐmatlab.
2.×Ö·û»·¾³ÏÂÔËÐÐmatlab½Å±¾Îļþ£¬½Å±¾ÎļþÎÞͼÏñµÄÆÁÄ»Êä³ö¡£
3.½Å±¾ÎÄ ......

linux ÐÞ¸ÄÖ÷»úÃû

ubuntu: ÐÞ¸ÄΪmaserat1
1) ÐÞ¸Ä /etc/hostname
master1
2£© /etc/hosts
127.0.0.1 localhost.localdomain localhost
172.16.111.102 master1.localdomain master1
172.16.111.103 slaver1.localdomain slaver1
172.16.111.106 slaver2.localdomain slaver2
3£© ÖØÆôÍøÂç
Redhat  ÐÞ¸ÄΪslaver2
1) Ð ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ