Pay attention to these issues when Linux mysql dump ensures program crash

Source: Internet
Author: User

For Linux mysql dump, pay attention to the following issues to ensure Coredump is generated when the program crashes:


1. For Linux mysql dump, ensure that the directory where Coredump is stored exists and the process has write permission on the directory. The directory that stores Coredump is the current directory of the process, which is generally the directory where the command was issued to start the process. However, if the script is started, the script may modify the current directory, and the current directory of the process will be different from the directory where the script was originally executed. In this case, you can view the target of the "/proc/<process pid>/cwd" symbolic link to determine the real current directory address of the process. You can also view the processes started by the system service in this way.


Ii. Linux mysql dump if the program calls seteuid ()/setegid () to change the valid users or groups of processes, the system will not generate Coredump for these processes by default. Many service programs call seteuid (), such as MySQL. No matter which user you use to run mysqld_safe to start MySQL, the effective user of mysqld is always the msyql user. If you run A program with user A, but the user who sees the program in ps is B, then these processes call seteuid. To allow these processes to generate core dump, change the content of the/proc/sys/fs/suid_dumpable file to 1. The default value is 0 ).

Iii. Linux mysql dump is generally known as setting a large enough Core file size limit. The Core file size generated when the program crashes is the memory size occupied by the program running. However, when a program crashes, the behavior cannot be estimated as usual. For example, errors such as buffer overflow may cause the stack to be destroyed. Therefore, the value of a variable is often changed to a mess, then the program uses this size to apply for memory, which may cause the program to occupy more memory than usual. Therefore, no matter how little memory is occupied during normal running of the program, make sure to generate the Core file or set the size limit to unlimited.


From
Http://easwy.com/blog/archives/customize-filename-of-core-dump/
Http://www.unix-center.net/bbs/viewthread.php? Tid = 12164
Detailed source reference: http://www.itqun.net/content-detail/76459_2.html

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.