LinuxQuestions.org
Share your knowledge at the LQ Wiki.
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 01-14-2004, 04:20 AM   #1
MarkBurke
LQ Newbie
 
Registered: Nov 2003
Location: Orange County, CA, USA
Distribution: aix, rhel, ubuntu
Posts: 24

Rep: Reputation: 0
flux capacitor, why swap is not being used


Am a newbie. Help! a question I've been working on, I trying to figure out why swap is not being used on the Mandrake 9.2 machine below.

(A popular database software is reporting that shared memory cannot be created, because 330meg of memory cannot be allocated.)

Have run ls / -lR and let the memory fill up, eventually got to the result of the free command below.

uname -a reports the following

Linux cxhome 2.4.22-21mdkcustom #1 Mon Jan 5 21:12:02 PST 2004 i686 unknown unknown GNU/Linux

Other command out is as follows:


[root@cxhome dbserver]# swapon /dev/hda5
[root@cxhome dbserver]# swapon -s
Filename Type Size Used Priority
/dev/ide/host0/bus0/target0/lun0/part5 partition 130748 0 1
[root@cxhome dbserver]# ls / -lR > /dev/null 2>&1 &
[root@cxhome dbserver]# free
total used free shared buffers cached
Mem: 515136 510112 5024 0 80092 160940
-/+ buffers/cache: 269080 246056
Swap: 130748 0 130748
[root@cxhome dbserver]# cat /etc/fstab
/dev/hda1 / ext3 defaults 1 1
none /mnt/cdrom supermount dev=/dev/scd0,fs=udf:iso9660,ro,--,iocharset=iso8859-1 0 0
none /mnt/floppy supermount dev=/dev/fd0,fs=ext2:vfat,--,umask=0,iocharset=iso8859-1,codepage=850,sync 0 0
/dev/sda1 /mnt/win_c2 vfat noauto,umask=0,iocharset=iso8859-1,codepage=850 0 0
none /proc proc defaults 0 0
/dev/hda5 swap swap defaults 0 0
[root@cxhome dbserver]#
 
Old 01-14-2004, 11:41 AM   #2
jailbait
LQ Guru
 
Registered: Feb 2003
Location: Blue Ridge Mountain
Distribution: Linux Mint 17, Debian 8
Posts: 7,863

Rep: Reputation: 311Reputation: 311Reputation: 311Reputation: 311
"A popular database software is reporting that shared memory cannot be created, because 330meg of memory cannot be allocated."

I am not sure but I think that you need to make your swap partition larger. I think that both memory and swap are full and your applicaion still needs more memory.

___________________________________
Be prepared. Create a LifeBoat CD.
http://users.rcn.com/srstites/LifeBo...home.page.html

Steve Stites
 
Old 01-17-2004, 03:45 PM   #3
MarkBurke
LQ Newbie
 
Registered: Nov 2003
Location: Orange County, CA, USA
Distribution: aix, rhel, ubuntu
Posts: 24

Original Poster
Rep: Reputation: 0
I've considered putting more swap. Actually the total swap currently is a combination of my original swap (2xmem) and an additional file of swap (1gig)

The system guard program shows that swap is never being used during the time of the install, or the boot of the database software. The "free" command posted in the original command shows that the swap used at that time is zero. swap is continually zero, and is zero presently on the same computer.

I think zero swap is normal usually, until heavy memory usage, in that swap would only be used if determined if needed (i.e. more efficient regular memory is all full.) However during the error message, I see that swap is not used significantly, but I get the error message below (the one I'm trying to determine why it occurred and is block the db server from starting) during the database startup (in the log file):
os_create_region: can't allocate 37445632 bytes

The current normal memory used before the install, plus the number above, is greater than the regular memory. But no swap was attempted. During the time of the error message, swap was zero.

I've read up on swapon (man), and the swapon -s currently states the following:


Filename Type Size Used Priority
/dev/ide/host0/bus0/target0/lun0/part5 partition 130748 0 -1
/dev/ide/host0/bus0/target0/lun0/part3 partition 8032492 0 -2


I'm not sure why Priority is -1 and -2.

Mostly, just wondering why the error message os_create_region occurred, if I have plenty of swap. same result on the db startup.
 
Old 01-17-2004, 03:46 PM   #4
MarkBurke
LQ Newbie
 
Registered: Nov 2003
Location: Orange County, CA, USA
Distribution: aix, rhel, ubuntu
Posts: 24

Original Poster
Rep: Reputation: 0
The free command in the original note

Mem: 515136 510112 5024 0 80092 160940
-/+ buffers/cache: 269080 246056
Swap: 130748 0 130748

Since mem is 510 meg of 515 meg, wouldn't the computer start swapping about that time? All I saw was it bumping up against the 515meg limit, and then freeing up about 5 meg, and approaching the limit again. kept doing this.
 
Old 01-17-2004, 04:08 PM   #5
jailbait
LQ Guru
 
Registered: Feb 2003
Location: Blue Ridge Mountain
Distribution: Linux Mint 17, Debian 8
Posts: 7,863

Rep: Reputation: 311Reputation: 311Reputation: 311Reputation: 311
" All I saw was it bumping up against the 515meg limit, and then freeing up about 5 meg, and approaching the limit again. kept doing this."

Yes. I think that your computer is acing like it is looking for more memory and it cannot find it in either RAM or swap.

"However during the error message, I see that swap is not used significantly"

Maybe the error occurs because even though you have set up a lot of swap space there is some logic error to where only a small portion of your swap space is being used. Are you sure that the swap file is being recognized as being part of swap space? I don't know whether the kernel swap logic can accomodate a mixture of partition swap space and file swap space. Also file swap is slower than partition swapping. I suggest that you rearrange things so that you have a large swap partition and no swap file. That may solve the problem either by fixing the swap logic or speeding up swap.

___________________________________
Be prepared. Create a LifeBoat CD.
http://users.rcn.com/srstites/LifeBo...home.page.html

Steve Stites
 
  


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
Many flux, flux console, flux appearance, etc... questions. kornerr Linux - General 10 08-06-2005 01:16 PM
"Singing capacitor" with ACPI, Pentium M and Kernel 2.6 coldsalmon Linux - Hardware 0 04-22-2005 03:23 AM
What is Flux Box ElementNine Linux - General 4 01-27-2004 10:03 PM
pek vs. flux ? synaptical Linux - Software 2 09-13-2003 02:35 PM
replacing capacitor on trinitron p/s C++freak Linux - Hardware 4 05-13-2003 02:10 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 07:09 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