Dave's Brain

Browse - Computer Tips - How can I fix an error from mysqldump saying it can not write to /tmp/MY(random-name) (Error 2) ?

Date: 2012apr23
Product: mysql
OS: Linux
Distro: RedHat/Fedora/CentOS

Q.   How can I fix an error from mysqldump saying it can not write to /tmp/MY(random-name) (Error 2) ?
I am not even outputting to there!

A.   On my Fedora box I fixed this problem by adding a line
to /etc/my.cnf:

[mysqld] ... tmpdir=/var/tmp <-- added this
And restarting mysqld:
systemctl restart mysqld.service

Add a comment

Sign in to add a comment
Copyright © 2008-2017, dave - Code samples on Dave's Brain is licensed under the Creative Commons Attribution 2.5 License. However other material, including English text has all rights reserved.