LinuxQuestions.org
Register a domain and help support LQ
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
Search this Thread
Old 11-15-2010, 04:25 PM   #1
bruxelles2010
LQ Newbie
 
Registered: Nov 2010
Posts: 8

Rep: Reputation: 0
MySQL error: Error writing file '/tmp/MYrZo6Qh' (Errcode: 28)


No, the disk is not full and there are only a few files in tmp directory, but some MySQL queries return this error:

Error writing file '/tmp/MYrZo6Qh' (Errcode: 28)

Something strange:
PHP Code:
select from table where c1='1' and c2='1' and c3='1' 
returns Error 28 but


PHP Code:
select from table where c1='1' and c2='1' and c3='0' 
works fine.

Any ideas?

Thanks.

Last edited by bruxelles2010; 11-15-2010 at 04:35 PM.
 
Old 11-15-2010, 04:32 PM   #2
paulsm4
Guru
 
Registered: Mar 2004
Distribution: SusE 8.2
Posts: 5,863
Blog Entries: 1

Rep: Reputation: Disabled
Q: Can you reproduce this, or was it just a "one time thing"?

Q: Did you do a "df" to see if ANY of your filesystems were full (or nearly full)?

Q: What's the exact SQL? Perhaps when you "obfuscated" your query, you left off something significant?

Last edited by paulsm4; 11-15-2010 at 04:34 PM.
 
Old 11-15-2010, 05:01 PM   #3
bruxelles2010
LQ Newbie
 
Registered: Nov 2010
Posts: 8

Original Poster
Rep: Reputation: 0
paulsm, thank you for your message.

This was not a one time thing. The first query works and the second not. I was using this query for years. Now the problem appeared in a new server installation. It's MySQL 5.0.51a

PHP Code:
Filesystem           1K-blocks      Used Available Use% Mounted on
/dev/md0             960392136   7477420 904129536   1% /
tmpfs                  1815680         0   1815680   0% /lib/init/rw
udev                     10240     10240         0 100
% /dev
tmpfs                  1815680         4   1815676   1
% /dev/shm
/dev/tmpMnt               9263        89      8696   2% /tmp 
 
Old 11-15-2010, 05:37 PM   #4
paulsm4
Guru
 
Registered: Mar 2004
Distribution: SusE 8.2
Posts: 5,863
Blog Entries: 1

Rep: Reputation: Disabled
Methinks I see the problem
Quote:
/dev/tmpMnt 9263 89 8696 2% /tmp
Q: Why don't you get rid of "/dev/tmpMnt" altogether, and carve "/tmp" out of your terabyte /dev/md0 drive?

But as it is now, your first "sort" that weighs in at more than 8MB will crash your query

Last edited by paulsm4; 11-15-2010 at 05:41 PM.
 
Old 11-15-2010, 05:56 PM   #5
paulsm4
Guru
 
Registered: Mar 2004
Distribution: SusE 8.2
Posts: 5,863
Blog Entries: 1

Rep: Reputation: Disabled
Q: Did moving /tmp to a larger (++100MB or, better, your TB root partition) help?

Inquiring minds want to know

Last edited by paulsm4; 11-15-2010 at 11:46 PM.
 
Old 11-16-2010, 04:57 AM   #6
bruxelles2010
LQ Newbie
 
Registered: Nov 2010
Posts: 8

Original Poster
Rep: Reputation: 0
Paulsm4, thank you for your replies.

First of all, today my server crashed 2 times.

I reinstalled AIDE and MySQL errors are gone now and df shows the following:


Quote:
Filesystem 1K-blocks Used Available Use% Mounted on
/dev/md0 960392136 8039628 903567328 1% /
tmpfs 1815680 0 1815680 0% /lib/init/rw
udev 10240 692 9548 7% /dev
tmpfs 1815680 4 1815676 1% /dev/shm
No crashes so far.
 
Old 11-17-2010, 02:16 PM   #7
paulsm4
Guru
 
Registered: Mar 2004
Distribution: SusE 8.2
Posts: 5,863
Blog Entries: 1

Rep: Reputation: Disabled
Hi -
Code:
# OLD:
Filesystem           1K-blocks      Used Available Use% Mounted on
/dev/md0             960392136   7477420 904129536   1% /
tmpfs                  1815680         0   1815680   0% /lib/init/rw
udev                     10240     10240         0 100% /dev
tmpfs                  1815680         4   1815676   1% /dev/shm
/dev/tmpMnt               9263        89      8696   2% /tmp
Code:
# NEW:
Filesystem           1K-blocks      Used Available Use% Mounted on
/dev/md0             960392136   8039628 903567328 1%   /
tmpfs                  1815680         0   1815680 0%   /lib/init/rw
udev                     10240       692      9548 7%   /dev
tmpfs                  1815680         4   1815676 1%   /dev/shm
So I'm guessing maybe you followed my suggested about moving "/tmp" someplace where it has a bit more elbow room ?

PS:
Any idea what might have been the problem with "/dev"? Perhaps something inadvertantly writing real data files (instead of simply using the links to kernel driver special files, which is pretty much all that should be in "/dev")?

Last edited by paulsm4; 11-17-2010 at 02:18 PM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
NFS Large File Copies Fail - Error writing to file: Input/output error deck- Linux - Server 7 07-27-2013 11:14 AM
Getting java.sql.SQLException: Error writing file '/tmp/MYNYq5lu' (Errcode: 28) aashil Linux - Server 3 02-02-2011 11:40 AM
Can't login, says tmp directory full but tmp file is empty! Could be linked to MySQL? bethanlowder Fedora 7 09-25-2009 07:17 AM
Error in writing to directory /tmp/OraInstall2008-04-24_11-31-56AM. ?????? Plz Help farnaw4u Linux - Software 1 04-24-2008 08:24 AM
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/tmp/mysql.so amee_stars Linux - Newbie 2 01-22-2007 02:48 AM


All times are GMT -5. The time now is 09:43 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration