LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Red Hat
User Name
Password
Red Hat This forum is for the discussion of Red Hat Linux.

Notices


Reply
  Search this Thread
Old 12-30-2010, 12:24 AM   #1
amit24788
LQ Newbie
 
Registered: Dec 2010
Posts: 3

Rep: Reputation: 0
Space problem


i have red hat linux server and it has mysql installed whenever i write on terminal command mysql -u root
it shows error "ERROR 2002 (HY000): can't connect to local MYSQL server through '/var/lib/mysql/mysql.sock (111) "
and another problem is that it is showing 0 byte free space istaed of freeing the space.
it may seems that both problems are dependent on each other
if anyone have idea then plz help me out.
Thanks in advance....
 
Old 12-30-2010, 12:37 AM   #2
paulsm4
LQ Guru
 
Registered: Mar 2004
Distribution: SusE 8.2
Posts: 5,863
Blog Entries: 1

Rep: Reputation: Disabled
Hi -

Quote:
ERROR 2002 (HY000): can't connect to local MYSQL server through '/var/lib/mysql/mysql.sock (111) "
Google for "mysql error 2002". You'll find lots of tips for troubleshooting this problem.

Quote:
another problem is that it is showing 0 byte free space istaed of freeing the space
What do you mean? If a disk is full, then you need to figure out what's filling it up!

Start off by running this command:
Code:
df -k
Quote:
it may seems that both problems are dependent on each other
There's no reason whatsoever to believe that.

STRONG SUGGESTION: treat these two issues as separate, and troubleshoot one at a time.
 
Old 12-30-2010, 11:44 PM   #3
amit24788
LQ Newbie
 
Registered: Dec 2010
Posts: 3

Original Poster
Rep: Reputation: 0
Thank u paul...
But i have googled for error but nowhere i got any clue by which my problem can be fixed....however mysql.sock file is present an it blinks means ever it becomes visible for a second and ever gets invisible..

nd i have also checked for the above command nd it shows

[root@localhost ~]# df -k
Filesystem 1K-blocks Used Available Use% Mounted on
/dev/mapper/VolGroup00-LogVol00
565258944 545795444 0 100% /
/dev/sda1 101086 13302 82565 14% /boot
tmpfs 8201044 0 8201044 0% /dev/shm

however after freeing lot of space more than even 20 GB its still not free. it seems to be bug
 
Old 12-31-2010, 12:27 AM   #4
paulsm4
LQ Guru
 
Registered: Mar 2004
Distribution: SusE 8.2
Posts: 5,863
Blog Entries: 1

Rep: Reputation: Disabled
Holy crap ! You've used up every byte of a 500++GB disk!
Code:
Filesystem                       1K-blocks       Used Available  Use% Mounted on
/dev/mapper/VolGroup00-LogVol00  565258944  545795444         0  100% /
/dev/sda1                           101086      13302     82565   14% /boot
tmpfs                              8201044          0   8201044    0% /dev/shm
Yes, your system is hosed. No, you're not going to be able to do ANYTHING (including run MySql) until you get it cleaned up.

SUGGESTION:
1. If at all possible, try using a graphical disk usage analyzer like KDirstat:
http://kdirstat.sourceforge.net/

2. Failing that, run "du -s" until you find the "space hog":
Code:
EXAMPLE:
  cd /
  du -sk
    <= Take the biggest directory
       "cd" down into it
       Run another "du -sk"
       <= Take the biggest directory
          "cd" down into it
           ...
Repeat until you find exactly what biiiiiggggggg files are taking up all your space.

I'm guessing they'll be in one main place.

And I'm also guessing they probably got created by accident.

'Hope that helps!
 
Old 01-03-2011, 04:24 AM   #5
amit24788
LQ Newbie
 
Registered: Dec 2010
Posts: 3

Original Poster
Rep: Reputation: 0
Actually what showing in terminal is not right,whole space is not full. I can say this because i have a script which automatically takes the backup of database. And it is executing correctly and writing backup. It means there is space..
And another thing is i have freed more than 20GB space but still same problem.
If this is a bug Of Linux....
 
Old 01-03-2011, 10:14 AM   #6
paulsm4
LQ Guru
 
Registered: Mar 2004
Distribution: SusE 8.2
Posts: 5,863
Blog Entries: 1

Rep: Reputation: Disabled
Quote:
Actually what showing in terminal is not right,whole space is not full.
No, dude! You absolutely need to get the "space available" for your root ("/") partition HIGHER than "0":
Code:
Filesystem                       1K-blocks       Used Available  Use% Mounted on
/dev/mapper/VolGroup00-LogVol00  565258944  545795444         0  100% /
 
Old 01-03-2011, 11:19 AM   #7
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,784

Rep: Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937
It is not necessarily a bug. I assume that your / partition is either ext3/4 which means that 5% of the total space is reserved for root. This space is not shown in the output of df. If the backup script is being performed by root then it will run successfully but not a process run as a regular user.

You have to free more that 25GB before df will show less then 100%. As suggested you need to find out what is taking up all the space. In addition you could lower the amount of reserved space using the tune2fs command but do not make it zero.

Last edited by michaelk; 01-03-2011 at 11:20 AM.
 
  


Reply



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
space problem zeeypeewee Linux - Server 1 03-05-2010 06:50 AM
Division of Logical Memory Space in to User Space and Kernel Space shreshtha Linux - Newbie 2 01-14-2010 09:59 AM
Space capacity problem. UltraSoul Solaris / OpenSolaris 13 04-27-2005 02:59 AM
3Gb of disk space lost! Disk space problem or mother board conflicts with HDD Mistreated Linux - Hardware 4 12-06-2004 03:58 PM
is it a space problem? tlaloc Linux - Software 1 02-20-2002 05:58 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Red Hat

All times are GMT -5. The time now is 10:41 PM.

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration