MySQL temporary folder

Source: Internet
Author: User
Tags tmp folder

MySQL Data folder/data/mysql is located in the upper folder/data not enough disk space to cause MySQL boot failure, so clean up the/data folder in addition to the MySQL subfolder of the other useless folders. Restart discovery or failure. Check the error log. See for example the following error:
/usr/local/mysql/bin/mysqld:can ' t create/write to file '/data/tmp/ibblmeod ' (Errcode:13-permission denied)

The original is to clean up the useless folder when accidentally the MySQL configuration file specified in the Tmpdir--/data/tmp folder is also deleted, resulting in MySQL server startup some temporary files or tables can not be written to start the failure. After you rebuild the folder and give the correct permissions, restart MySQL Server and start normally.


By the way, MySQL temporary folder This number of parameters:

Command line parameter format:--tmpdir=path
Configuration file Format: Tmpdir=path

Temporary folders are used to store temporary files or temporary tables. Value can be a use of ":" (Unix) or ";" (Windows) delimited list of paths that can be used in turn to divide the load into different disks. If MySQL server is a slave role, you cannot point the folder to a folder based on the memory file system or to a folder that will be cleaned up when the host restarts, because slave requires these files to replicate the temporary table or run the load DATA infile operation. The loss of these files can cause replication to fail. This means that the slave tmpdir cannot be said to be set to the Linux system default/tmp folder. For slave to be able to use a configuration item slave_load_tmpdir to set its temporary folder, so slave can not use the common options Tmpdir set the temporary folder. There is no such limit for MySQL server for non-slave roles.

If the temporary folder does not exist or the permissions are not correct, it will not only cause MySQL server startup failure but will also cause other MySQL utility programs that may use the temporary folder to execute the exception. Very many MySQL-related programs read option values from the MySQL server configuration file, such as the full program xtrabackup, the following error is caused by the absence of a temporary folder specified in the MySQL server configuration file.

Xtrabackup_56:can ' t create/write to file '/data/tmp/ibhbumcm ' (Errcode:2-No such file or directory)
2014-07-23 16:04:42 7f1b25c607e0 InnoDB:Error:unable to create temporary file; Errno:2
Xtrabackup:innodb_init (): Error occured.
Innobackupex:error:
Innobackupex:ibbackup failed At/usr/bin/innobackupex line 389.

MySQL temporary folder

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.