Linux ²âÊÔsendmailÓʼþ·¢ËÍ
ÓÖÅöµ½ÓʼþÎÊÌ⣬ÔÚmagentoǰ̨ע²áÐÂÓû§£¬Ï¶©µ¥¶¼Ã»ÓÐÊÕµ½Óʼþ¡£µ«ÊÇÌáʾ¶¼ÊÇ˵Õý³£¡£
Ö±½ÓÔÚsshÖÐʹÓÃÏÂÁÐÃüÁî²âÊÔ£¬Á¬½Ó³¬Ê±£º
echo "Subject: test" | /usr/lib/sendmail -v xinhaozheng@gmail.com
Ìáʾ£º
WARNING: local host name (server) is not qualified; see cf/README: WHO AM I?
xinhaozheng@gmail.com... Connecting to [127.0.0.1] via relay...
xinhaozheng@gmail.com... Deferred: Connection timed out with [127.0.0.1]
»³ÒÉÊÇISP·âµôÁË25¶Ë¿Ú¡£¼ì²éһϷÀ»ðǽ£¬ÔÝʱ¹Øµôiptables£¬ÔÙÓÃÕâ¸öÃüÁî²âÊÔ£¬¿ÉÒÔͨ¹ý£º
WARNING: local host name (server) is not qualified; see cf/README: WHO AM I?
xinhaozheng@gmail.com... Connecting to [127.0.0.1] via relay...
220 server ESMTP Sendmail 8.13.8/8.13.8; Thu, 29 Apr 2010 03:22:42 +0200
>>> EHLO server
250-server Hello localhost.localdomain [127.0.0.1], pleased to meet you
250-ENHANCEDSTATUSCODES
250-PIPELINING
250-8BITMIME
250-SIZE
250-DSN
250-ETRN
250-DELIVERBY
250 HELP
>>> MAIL from:<root@server> SIZE=14
250 2.1.0 <root@server>... Sender ok
>>> RCPT To:<xinhaozheng@gmail.com>
>>> DATA
250 2.1.5 <xinhaozheng@gmail.com>... Recipient ok
354 Enter mail, end with "." on a line by itself
>>> .
250 2.0.0 o3T1Mg5Z016990 Message accepted for delivery
xinhaozheng@gmail.com... Sent (o3T1Mg5Z016990 Message accepted for delivery)
Closing connection to [127.0.0.1]
>>> QUIT
221 2.0.0 server closing connection
Ïà¹ØÎĵµ£º
Ò»¡¢ ShellÃüÁî
1. man vi
2. echo $PATH
3. catÏÔʾÎļþÄÚÈÝ
1 cat ÎļþÃûÒ»ÎļþÃû¶þ
2 moreÎļþÃû
3 lessÎļþÃû ÏòÇ°·°´b¼ü;Ïòºó·°´p¼ü;Ö¸¶¨Î»ÖÃÊäÈë°Ù·Ö±È;Í˳ö ......
ת×Ôhttp://liuleijsjx.javaeye.com/blog/450933
1.²ßÂÔ·ÓÉ
»ùÓÚ²ßÂԵķÓɱȴ«Í³Â·ÓÉÔÚ¹¦ÄÜÉϸüÇ¿´ó£¬Ê¹ÓøüÁé»î£¬ËüʹÍøÂç¹ÜÀíÔ±²»½öÄܹ»¸ù¾ÝÄ¿µÄµØÖ·¶øÇÒÄܹ»¸ù¾Ý±¨ÎÄ´óС¡¢Ó¦ÓûòIPÔ´µØÖ·À´Ñ¡Ôñת·¢Â·¾¶...
#/etc/iprout ......
http://club.topsage.com/thread-1201128-1-1.html
ºÜ¶àÈ˶¼¶Ô¹ýÃüÁîÐÐÌáʾµÄÖØÒªÐÔ²»Ð¼Ò»¹Ë£¬ÉõÖÁÊÇÒ»µã¶¼²»¹ØÐÄ¡£µ«ÊÇÎÒÈ´Ò»µã¶¼²»ÕâôÈÏΪ£¬Ò»¸öºÃµÄÃüÁîÐÐÌáʾ¿ÉÒԸıäÄãʹÓÃÃüÁîµÄ·½Ê½¡£Îª´Ë£¬ÎÒÔÚinternetÉÏÕÒµ½Ò»Ð©·Ç³£ÊµÓã¬ÓÅÐ㣬²¢ÓÐȤµÄbashµÄÃüÁîÐÐÌáʾ¡£ÏÂÃæÎÒ½«ÎÒ×îϲ»¶Ê¹ÓõÄһЩÃüÁîÐÐÌáʾÂÞÁÐÈçÏ¡£
¡¡¡ ......
ÕâÊÇCµÄÔ³ÌÐò
#include <stdio.h>
#include <regex.h>
int main(int argc, char** argv)
{
regex_t reg;
regmatch_t pm[10];
char *pattern;
char buf[50];
const size_t nmatch = 10;
pattern = argv[1];
int result = regcomp(®, pattern, REG_EXTENDED);
while( fgets ......
¹¹½¨»ù±¾µÄLinux C ±à³Ì»·¾³ ÊÕ²Ø
±¾ÎÄ»ùÓÚdebian-40r0(ÄÚºË2.6.18)½éÉÜÒ»ÏÂÈçºÎÔÚÒ»¸ö±ê׼ϵͳÖй¹½¨Linux CµÄ»ù±¾±à³Ì¿ª·¢»·¾³¡£
Ò»¸öÍêÕûµÄ¿ª·¢»·¾³Ö÷Òª°üÀ¨Ëĸö²¿·Ö£º±ê×¼C¿â¡¢Í·Îļþ¡¢¹¤¾ßÁ´¡¢±à¼Æ÷¡¢°ïÖúÎĵµ£¬ÏÂÃæÒÀ´Î½éÉÜ¡£
±ê×¼C¿âglibc
glibcÊÇgnu·¢²¼µÄlibc¿â£¬¼´cÔËÐп⡣glibcÊÇlinuxϵͳÖÐÄÚºËÖ ......