LinuxQuestions.org
Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 03-06-2008, 02:12 PM   #1
npegus
LQ Newbie
 
Registered: Mar 2008
Posts: 7

Rep: Reputation: 0
Unhappy Out of Memory /usr/local


Ive just run out of memory on the /usr/local folder of my redhat linux install, /usr indicates there are 4.5 Gigs free but the usr/local folder only contains 80.8 megs so I am at a loss as to why usr/local also indicates there is 0 space available. I determined the space available by checking the properties of each folder. Can anyone point me in the right direction to understand how this is possible and how to reclaim the space I imagine exists but is inaccessible for some reason

Thanks.
 
Old 03-06-2008, 02:19 PM   #2
jailbait
LQ Guru
 
Registered: Feb 2003
Location: Blue Ridge Mountain
Distribution: Debian Jessie, Linux Mint 17
Posts: 7,751

Rep: Reputation: 272Reputation: 272Reputation: 272
The first thing that I would do is run fsck against the /usr partition to check the file system for errors.

----------------------
Steve Stites
 
Old 03-06-2008, 04:35 PM   #3
Brian1
LQ Guru
 
Registered: Jan 2003
Location: Seymour, Indiana
Distribution: Distribution: RHEL 5 with Pieces of this and that. Kernel 2.6.23.1, KDE 3.5.8 and KDE 4.0 beta, Plu
Posts: 5,700

Rep: Reputation: 62
What does the output from the command ' df ' show?

Brian
 
Old 03-07-2008, 10:20 AM   #4
npegus
LQ Newbie
 
Registered: Mar 2008
Posts: 7

Original Poster
Rep: Reputation: 0
re : out of memory on /usr/local

the df command result is

Filesystem 1K-blocks Used Available Use% Mounted on
/dev/sda3 1027800 812808 162784 84% /
/dev/sda1 101089 9335 86535 10% /boot
/dev/sda2 2063536 33300 1925412 2% /home
none 256764 0 256764 0% /dev/shm
/dev/sdb2 10325780 5057096 4744164 52% /usr
/dev/sdb3 4087584 4081968 0 100% /usr/local
/dev/sdb1 2055600 383228 1567952 20% /var

so again system seams to be indicating there is no space available but the properties of the local folder indicates only 80 megs are used.....?????

...not sure if i continued this thread correctly by "replying" to my post..
 
Old 03-07-2008, 10:24 AM   #5
AlucardZero
Senior Member
 
Registered: May 2006
Location: USA
Distribution: Debian
Posts: 4,808

Rep: Reputation: 604Reputation: 604Reputation: 604Reputation: 604Reputation: 604Reputation: 604
well, /usr/local certainly is full. did you run the fsck?
 
Old 03-07-2008, 10:24 AM   #6
npegus
LQ Newbie
 
Registered: Mar 2008
Posts: 7

Original Poster
Rep: Reputation: 0
I tried running that fsck command but got the following so aborted

[root@tdspace root]# fsck
fsck 1.32 (09-Nov-2002)
e2fsck 1.32 (09-Nov-2002)
/dev/sda3 is mounted.

WARNING!!! Running e2fsck on a mounted filesystem may cause
SEVERE filesystem damage.

Do you really want to continue (y/n)?
 
Old 03-07-2008, 01:09 PM   #7
jailbait
LQ Guru
 
Registered: Feb 2003
Location: Blue Ridge Mountain
Distribution: Debian Jessie, Linux Mint 17
Posts: 7,751

Rep: Reputation: 272Reputation: 272Reputation: 272
Quote:
Originally Posted by npegus View Post

WARNING!!! Running e2fsck on a mounted filesystem may cause
SEVERE filesystem damage.
Boot a live CD and run fsck from the live CD. Also is the file system ext2? If it is ext3 then you need to do:

fsck -t ext3 /dev/sda3

--------------------------
Steve Stites
 
Old 03-07-2008, 01:51 PM   #8
michaelk
Moderator
 
Registered: Aug 2002
Posts: 14,948

Rep: Reputation: 1530Reputation: 1530Reputation: 1530Reputation: 1530Reputation: 1530Reputation: 1530Reputation: 1530Reputation: 1530Reputation: 1530Reputation: 1530Reputation: 1530
Quote:
/dev/sdb2 10325780 5057096 4744164 52% /usr
/dev/sdb3 4087584 4081968 0 100% /usr/local
/usr and /usr/local are two different partitions so used/free space in /usr does not have any bearing on used/free space in /usr/local. Since /usr/local contains several subdirectories at first glance 80MB used sounds a little light but I have know way of telling what you actually have installed.

Directories in /usr/local:
bin
games
include
lib
man
sbin
share
src

Last edited by michaelk; 03-07-2008 at 01:55 PM.
 
Old 03-07-2008, 03:02 PM   #9
npegus
LQ Newbie
 
Registered: Mar 2008
Posts: 7

Original Poster
Rep: Reputation: 0
I was attempting to setup a backup which was writting to the usr/local folder before this happened I did run the backup a few times but expected it to simply overwrite the contents of the backup folder. I had since deleted the backup folder which of cours has not helped...
 
Old 03-07-2008, 04:16 PM   #10
Brian1
LQ Guru
 
Registered: Jan 2003
Location: Seymour, Indiana
Distribution: Distribution: RHEL 5 with Pieces of this and that. Kernel 2.6.23.1, KDE 3.5.8 and KDE 4.0 beta, Plu
Posts: 5,700

Rep: Reputation: 62
Lets have a better look at df output. Use the command ' df -h ' Post the output.
Next post output of ' /sbin/fdisk -l ' needs to be run as root.

Brian
 
Old 03-08-2008, 10:11 AM   #11
LasseW
Member
 
Registered: Oct 2004
Distribution: Fedora 7, OpenSuse 10.2
Posts: 108

Rep: Reputation: 15
Exactly how did you determine the space by checking the subdirectories ? Could you post the output of

cd /usr/local
du -sk *
 
Old 03-10-2008, 09:41 AM   #12
npegus
LQ Newbie
 
Registered: Mar 2008
Posts: 7

Original Poster
Rep: Reputation: 0
results of df -h and /sbin/fdisk -l

Ok I ran df -h these are the results:
[root@tdspace root]# df -h
Filesystem Size Used Avail Use% Mounted on
/dev/sda3 1004M 796M 158M 84% /
/dev/sda1 99M 9.2M 85M 10% /boot
/dev/sda2 2.0G 33M 1.9G 2% /home
none 251M 0 251M 0% /dev/shm
/dev/sdb2 9.9G 4.9G 4.6G 52% /usr
/dev/sdb1 2.0G 368M 1.6G 20% /var
/dev/cdrom 140M 140M 0 100% /mnt/cdrom
/dev/sdb3 3.9G 3.9G 0 100% /usr/local

next I ran /sbin/fdisk -l results are:
[root@tdspace root]# /sbin/fdisk -l

Disk /dev/sda: 9105 MB, 9105050112 bytes
255 heads, 63 sectors/track, 1106 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/sda1 * 1 13 104391 83 Linux
/dev/sda2 274 534 2096482+ 83 Linux
/dev/sda3 535 664 1044225 83 Linux
/dev/sda4 665 1106 3550365 5 Extended
/dev/sda5 665 794 1044193+ 82 Linux swap

Disk /dev/sdb: 18.2 GB, 18210048512 bytes
255 heads, 63 sectors/track, 2213 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/sdb1 * 1 260 2088418+ 83 Linux
/dev/sdb2 261 1566 10490445 83 Linux
/dev/sdb3 1697 2213 4152802+ 83 Linux
 
Old 03-10-2008, 10:16 AM   #13
npegus
LQ Newbie
 
Registered: Mar 2008
Posts: 7

Original Poster
Rep: Reputation: 0
Results of du -sk *

In /usr/local I ran du -sk * and got the following result:

[root@tdspace local]# du -sk *
4 bin
4 etc
4 games
4 include
4 lib
4 libexec
16 lost+found
87824 pgsql
4 sbin
52 share
4 src
4 testscript2

To check the space on the subdirectories I right clicked the folders and then checked the properties. /usr indicates "free space = 4.5 gigs" and /usr/local is 0...
 
Old 03-10-2008, 03:12 PM   #14
AlucardZero
Senior Member
 
Registered: May 2006
Location: USA
Distribution: Debian
Posts: 4,808

Rep: Reputation: 604Reputation: 604Reputation: 604Reputation: 604Reputation: 604Reputation: 604
well, looks like your PostgreSQL install has gone haywire.
 
Old 03-12-2008, 12:54 PM   #15
LasseW
Member
 
Registered: Oct 2004
Distribution: Fedora 7, OpenSuse 10.2
Posts: 108

Rep: Reputation: 15
umount /usr/local and then run fsck
 
  


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
making files available in /usr/local/bin and /usr/sbin reakinator Linux - Newbie 1 10-14-2006 06:09 PM
./configure --prefix=/usr [default: /usr/local] why??? stevesk Slackware 14 07-03-2006 07:28 AM
Starting httpd: /usr/sbin/httpd: symbol lookup error: /usr/local/lib/libaprutil-0.so. bijuhpd Linux - Newbie 1 10-30-2005 06:07 PM
/usr vs /usr/local on linuxpackages.net merchtemeagle Slackware 4 10-18-2005 04:09 PM
Installing software, /usr/lib directory and /usr/local millertime Linux - Software 2 07-10-2004 10:21 AM


All times are GMT -5. The time now is 10:46 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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration