linux coredumpÅäÖÃÓëµ÷ÊÔ
linux coredumpÅäÖÃÓëµ÷ÊÔ
À´Ô´:
ChinaUnix²©¿Í ¡¡ÈÕÆÚ£º
2009.02.09 17:11¡¡(¹²ÓÐ0
ÌõÆÀÂÛ) ÎÒÒªÆÀÂÛ
linux coredumpÅäÖÃÓëµ÷ÊÔ
Linux
Core Dump ÅäÖÃÓëµ÷ÊÔ
1.coreÎļþµÄÉú³É¿ª¹ØºÍ´óСÏÞÖÆ
---------------------------------
1£©Ê¹ÓÃulimit
-cÃüÁî¿É²é¿´coreÎļþµÄÉú³É¿ª¹Ø¡£Èô½á¹ûΪ0£¬Ôò±íʾ¹Ø±ÕÁ˴˹¦ÄÜ£¬²»»áÉú³ÉcoreÎļþ¡£
2£©
ʹÓÃulimit
-cfilesizeÃüÁ¿ÉÒÔÏÞÖÆcoreÎļþµÄ´óС£¨filesizeµÄµ¥Î»Îªkbyte£©¡£Èôulimit
-cunlimited£¬Ôò±íʾcoreÎļþµÄ´óС²»ÊÜÏÞÖÆ¡£Èç¹ûÉú³ÉµÄÐÅÏ¢³¬¹ý´Ë´óС£¬½«»á±»²Ã¼ô£¬×îÖÕÉú³ÉÒ»¸ö²»ÍêÕûµÄcoreÎļþ¡£ÔÚµ÷ÊÔ´Ë
coreÎļþµÄʱºò£¬gdb»áÌáʾ´íÎó¡£
2.coreÎļþµÄÃû³ÆºÍÉú³É·¾¶
----------------------------
ÈôϵͳÉú³ÉµÄcoreÎļþ²»´øÆäËüÈκÎÀ©Õ¹Ãû³Æ£¬ÔòÈ«²¿ÃüÃûΪcore¡£ÐµÄcoreÎļþÉú³É½«¸²¸ÇÔÀ´µÄcoreÎļþ¡£
1£©/proc/sys/kernel/core_uses_pid¿ÉÒÔ¿ØÖÆcoreÎļþµÄÎļþÃûÖÐÊÇ·ñÌí¼Ópid×÷ΪÀ©Õ¹¡£ÎļþÄÚÈÝΪ1£¬±íʾÌí¼Ópid×÷ΪÀ©Õ¹Ãû£¬Éú³ÉµÄcoreÎļþ¸ñʽΪcore.xxxx£»Îª0Ôò±íʾÉú³ÉµÄcoreÎļþͬһÃüÃûΪcore¡£
¿Éͨ¹ýÒÔÏÂÃüÁîÐ޸ĴËÎļþ£º
echo
"1" >
/proc/sys/kernel/core_uses_pid
2£©proc/sys/kernel/core_pattern¿ÉÒÔ¿ØÖÆcoreÎļþ±£´æλÖúÍÎļþÃû¸ñʽ¡£
¿Éͨ¹ýÒÔÏÂÃüÁîÐ޸ĴËÎļþ£º
echo
"/corefile/core-%e-%p-%t" >
core_pattern£¬¿ÉÒÔ½«coreÎļþͳһÉú³Éµ½/corefileĿ¼Ï£¬²úÉúµÄÎļþÃûΪcore-ÃüÁîÃû-pid-ʱ¼ä´Á
ÒÔÏÂÊDzÎÊýÁбí:
%p - insert pid into filename Ìí¼Ópid
%u - insert current uid into filename Ìí¼Óµ±Ç°uid
%g - insert current gid into filename Ìí¼Óµ±Ç°gid
%s - insert signal that caused the coredump into the filename
Ìí¼Óµ¼Ö²úÉúcoreµÄÐźÅ
%t - insert UNIX time that the coredump occurred into filename
Ìí¼ÓcoreÎļþÉú³ÉʱµÄunixʱ¼ä
%h - insert hostname where the coredump happened into filename
Ìí¼ÓÖ÷»úÃû
%e - insert coredumping executable name into f
Ïà¹ØÎĵµ£º
´´½¨×ÀÃæͼ±ê
Ä¿Ç°½«ÍøÂçÓ¦ÓÃÀ©Õ¹µ½×ÀÃæÊÇÒ»¸öÇ÷ÊÆ£¬´æÔÚןܶà½â¾ö·½°¸£¬±¾ÎÄÒÔ Mozilla Prism ΪÀý£¬ÀàËƵķ½·¨Í¬ÑùÊÊÓÃÓÚ Google Chrome ¡£
1. µ½ Mozilla Prism µÄÍøÕ¾ÉÏÏÂÔØ Prism£¬µã»÷ Download Now Ö®ºó»áÌáʾÓÐÁ½ÖÖ£¬Ò»ÖÖÊÇÒÔ Mozilla Firefox À©Õ¹µÄ·½Ê½£¬ÊʺÏÒѾ°²×°ÓÐ Firefox µÄÅóÓÑ£»Ò»Ö ......
LinuxÏÂracµÄ°²×°
1£¬»·¾³×¼±¸
192.168.5.10 rac1
192.168.5.100 prac1
10.20.0.10 vrac1
192.168.5.20 rac2
192.168.5.200 prac2
10.20.0.20 vrac2
2.Íø¿¨ÉèÖÃÇ°ÌáÊÇÁ½¿éÍø¿¨
cd /etc/sysconfig/network-scripts
& ......
1. ÐÞ¸ÄIPµØÖ· # vi /etc/sysconfig/network-scripts/ifcfg-eth0
ÐÞ¸ÄÒÔÏÂÄÚÈÝ
DEVICE=eth0 #ÃèÊöÍø¿¨¶ÔÓ¦µÄÉ豸±ðÃû£¬ÀýÈçifcfg-eth0µÄÎļþÖÐËüΪeth0
BOOTPROTO=static #ÉèÖÃÍø¿¨»ñµÃipµØÖ·µÄ·½Ê½£¬¿ÉÄܵÄÑ¡ÏîΪstatic£¬dhcp»òbootp£¬·Ö±ð¶ÔÓ¦¾²Ì¬Ö¸¶¨µÄ ipµØÖ·£¬Í¨¹ýdhcpÐÒé»ñµÃµÄipµØÖ·£ ......
linuxÈçºÎϵͳÐÅÏ¢
Äõ½Ò»¸öϵͳ£¬¿Ï¶¨Òª¿´¿´ÏµÍ³ÅäÖã¬linuxÏ¿´ÅäÖ㬿ÉûÓÐwindowsÄÇôֱ¹Û¡£ÄãÖ»ÄÜÒ»¸öÒ»¸ö²é¿´¡£
Ò»£ºcpu
[root@srv /]# more /proc/cpuinfo | grep "model name"
model name : Intel(R) Xeon(R) CPU X3220 @ 2.40GHz
model name &n ......
http://hugege.com/2009/06/24/linux-ssh/
Linux SSHÃüÁî´óÈ«
rm
-rf mydir /* ɾ³ýmydirĿ¼ */
cd mydir /* ½øÈëmydirĿ¼ */
cd – /*
»ØÉÏÒ»¼¶Ä¿Â¼ */
cd ~ /* »Ø¸ùĿ¼ */
mv tools tool /* °ÑtoolsĿ¼¸ÄÃûΪtool */
ln -s tool bac
/*
¸øtoolĿ¼´´½¨ÃûΪbacµÄ·ûºÅÁ´½Ó,×îÊìϤµÄÓ¦¸Ã¾ÍÊÇFTP ......