OSEC

Neohapsis is currently accepting applications for employment. For more information, please visit our website www.neohapsis.com or email hr@neohapsis.com
Re: mysqldump: Got error: 1: Can't create/write to file 'dumpdir/tablename.txt' (Errcode: 13) when executing 'SELECT INTO OUTFILE'

From: Mike Spreitzer (mspreitzus.ibm.com)
Date: Fri Feb 22 2008 - 18:13:42 CST


I am running MySQL 5.0.51a-community on RedHat Enterprise Linux 4. Here
is a further typescript showing the failure:

[rootxd026 /]# mysqldump -u root -p --skip-opt --quick --tab=/dump1 wyky
red1_p2
Enter password:
mysqldump: Got error: 1: Can't create/write to file '/dump1/red1_p2.txt'
(Errcode: 13) when executing 'SELECT INTO OUTFILE'
[rootxd026 /]# ls -ld /dump1
drwxrwxrwx 2 mysql mysql 4096 Feb 22 19:11 /dump1
[rootxd026 /]# ls -l /dump1
total 16
-rw-r--r-- 1 mysql mysql 29 Feb 22 18:38 foo.bar
-rw-r--r-- 1 root root 742 Feb 22 19:11 red1_p2.sql
[rootxd026 /]#

Thanks,
Mike

Jed Reynolds <listsbitratchet.com>
02/22/08 07:04 PM
Please respond to
listsbitratchet.com

To
Mike Spreitzer/Watson/IBMIBMUS
cc
mysql list <mysqllists.mysql.com>
Subject
Re: mysqldump: Got error: 1: Can't create/write to file
'dumpdir/tablename.txt' (Errcode: 13) when executing 'SELECT INTO OUTFILE'

Mike Spreitzer wrote:
> So I am trying to use mysqldump --tab for the first time. I am running
> into the same problem everybody does on their first try --- Errcode: 13.
I
> have set the permissions on the target directory to be completely
liberal
> --- anybody can do anything with it --- and I still get Errcode: 13. I
> can even write into that directory when logged in as mysql (UID 100, GID

> 100, and yes that is what the mysqld process is running as). What's
going
> wrong here?
>

SELinux enabled?

What's the syntax of the command you're using?

Jed