Neohapsis is currently accepting applications for employment. For more information, please visit our website www.neohapsis.com or email email@example.com
From: John List (johnlistgulfbridge.net)
Date: Sun Nov 08 2009 - 09:17:39 CST
Sebastiaan van Erk wrote:
> Hi all,
> I just recently upgraded to Ubuntu 9.10, but now I'm having all sorts
> of temp file problems. For example, when I try to delete a row and
> violate a contraint I get:
> ERROR 1451 (23000): Cannot delete or update a parent row: a foreign
> key constraint fails (temp file operation failed)
> Instead of telling me which constraint is violated, it tells me the
> temp file creation failed. I have no reason why it failed, I don't see
> any error messages in the log.
> To solve this problem I tried to make a tmpfs partition (I thought,
> maybe somehow my using ext4 might be a problem):
> mkdir /tmpfs
> mount -t tmpfs -o size=1g tmpfs /tmpfs
> mkdir /tmpfs/mysql
> chown mysql:mysql
> and changed the tmpdir in the mysql config to /tmpfs/mysql
> But then mysql fails on startup:
> /usr/sbin/mysqld: Can't create/write to file '/tmpfs/mysql/ibGgjPv7'
> (Errcode: 13)
> 091108 10:12:46 InnoDB: Error: unable to create temporary file;
> errno: 13
> 091108 10:12:46 [ERROR] Plugin 'InnoDB' init function returned error.
> 091108 10:12:46 [ERROR] Plugin 'InnoDB' registration as a STORAGE
> ENGINE failed.
> I checked error code 13, which is permission denied, but I don't
> understand this, because if I change tmpdir to /tmp/mysql it does
> work, and I have:
> $ ls -ld /tmp/mysql
> drwxr-xr-x 2 mysql mysql 4096 2009-11-08 10:14 /tmp/mysql
> $ ls -ld /tmpfs/mysql
> drwxr-xr-x 2 mysql mysql 40 2009-11-08 10:12 /tmpfs/mysql
> So I don't see the difference....
> Has anyone encountered similar problems, or know what's going on here?
> Best regards,
This might just be a typo, but the chown statement you gave us didn't
have a target and so would not have affected the relevant directories:
mount -t tmpfs -o size=1g tmpfs /tmpfs
Probably should be:
chown -R mysql:mysql /tmpfs/mysql
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql