Hi everybody!

Peng Yu wrote:
> Hi,
> 
> I run the following command. But I got the following error. I'm not
> sure what causes the problem. I have seen the same issue before, but
> it disappeared even I didn't take any action. Could anybody let me
> know how to fix the problem?
> 
> mysql -ugenome -hgenome-mysql.cse.ucsc.edu mm9 -A
> 
> mysql> select geneName as symbol, name as refSeq, chrom, strand,
> txStart, txEnd from refFlat group by refSeq having count(*)=1;
> ERROR 1 (HY000): Can't create/write to file
> '/var/lib/mysql/#sql_9e1_0.MYI' (Errcode: 13)
> 

"Errcode" is what mySQL writes for an "errno" value.


First, you need to find out what the error number 13 means:

  joerg@machine:~$ fgrep 13 /usr/include/asm-generic/errno-base.h
  #define EACCES          13      /* Permission denied */


Then (unless you know that already), check the "man" pages to find when
the calls would return EACCESS. In this case, the candidate calls are
"creat()" and "write()".

  man 2 write
the output doesn't mention EACCESS.

  man 2 creat
will tell you this:
  ERRORS
       EACCES The  requested  access  to  the file is not allowed, or search
              permission is denied for one of the directories  in  the  path
              prefix  of  pathname,  or the file did not exist yet and write
              access to the parent directory  is  not  allowed.   (See  also
              path_resolution(7).)


So it is a permission issue for either the file, or the directory
hierarchy leading to it. See the other replies for the specific things
to check.


Regards,
Jörg

-- 
Joerg Bruehe,  MySQL Build Team,  joerg.bru...@oracle.com
ORACLE Deutschland B.V. & Co. KG,   Komturstrasse 18a,   D-12099 Berlin
Geschaeftsfuehrer: Juergen Kunz, Marcel v.d. Molen, Alexander v.d. Ven
Amtsgericht Muenchen: HRA 95603


--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/mysql?unsub=arch...@jab.org

Reply via email to