LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
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 02-12-2008, 11:31 PM   #1
procfs
Member
 
Registered: Jan 2006
Location: Sri Lanka
Posts: 608

Rep: Reputation: 34
Swap used is alwas zero (0k)


Hi

I have an IBM server and details as follows.


# free
total used free shared buffers cached
Mem: 7986948 7942344 44604 0 334704 2540748
-/+ buffers/cache: 5066892 2920056
Swap: 8385760 0 8385760

# cat /etc/redhat-release
Red Hat Enterprise Linux AS release 3 (Taroon Update 7)

# uname -a
Linux AVAMEDL2 2.4.21-40.EL #1 SMP Thu Feb 2 22:14:00 EST 2006 x86_64 x86_64 x86_64 GNU/Linux

# cat /proc/swaps
Filename Type Size Used Priority
/dev/sda12 partition 2096440 0 -1
/dev/sda11 partition 2096440 0 -2
/dev/sda9 partition 2096440 0 -3
/dev/sda10 partition 2096440 0 -4

Runs Sybase IQ

I donít see any swap is been used even though the server load go to 90% or so. To my knowledge any system should have some amount of swap (it cant be zero).

Can someone tell me what is going on?

Regards
 
Old 02-13-2008, 12:21 AM   #2
jiml8
Senior Member
 
Registered: Sep 2003
Posts: 3,171

Rep: Reputation: 115Reputation: 115
*shrug* either you have all swap disabled (swapoff -a), or you have enough RAM that swap isn't needed.

On my workstation, I usually interpret any swap usage as evidence of a memory leak in the system someplace.
 
Old 02-13-2008, 12:49 AM   #3
LinuxCrayon
Member
 
Registered: Nov 2007
Location: Georgia, USA
Distribution: FreeBSD
Posts: 274

Rep: Reputation: 31
Seems fine to me. According to your output, you still have RAM left to be used.

Disclaimer: I'm not a professional.
 
Old 02-13-2008, 02:50 AM   #4
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910
Quote:
Originally Posted by jiml8 View Post
*shrug* either you have all swap disabled (swapoff -a)
In that case he wouldn't have the line in red
in the output of free ...
Code:
# free
total used free shared buffers cached
Mem: 7986948 7942344 44604 0 334704 2540748
-/+ buffers/cache: 5066892 2920056
Swap: 8385760 0 8385760
To the OP:

Just check how much RAM your processes gobble up according
to top/ps (just a rough guesstimate), but it looks perfectly
sane to me.


Cheers,
Tink
 
Old 02-13-2008, 02:58 AM   #5
vwvr9
Member
 
Registered: Feb 2005
Distribution: OpenSuse 10.1 / Centos 4.4
Posts: 60

Rep: Reputation: 15
If you start using swap something is wrong. Linux does not work it's swap like windows. So rest assure that your machine is working optimal. I hope
 
Old 02-13-2008, 04:13 AM   #6
procfs
Member
 
Registered: Jan 2006
Location: Sri Lanka
Posts: 608

Original Poster
Rep: Reputation: 34
What I dont understand is all the servers I have worked with (Not that many) even though there is ample RAM and server load is very minimal I could see some amount of swap is been used but this is the first time I am seeing (0k) as used space.

Thank you all for the replies

Best Regards
 
Old 02-13-2008, 04:17 AM   #7
Saptech
Member
 
Registered: Nov 2000
Location: Third Stone from the Sun
Distribution: Mageia 5, Debian Stretch & Funtoo Linux
Posts: 147

Rep: Reputation: 25
It is pretty good when it's not using swap or using very little swap.
 
Old 02-13-2008, 11:21 AM   #8
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910
Quote:
Originally Posted by asankacgl View Post
What I dont understand is all the servers I have worked with (Not that many) even though there is ample RAM and server load is very minimal I could see some amount of swap is been used but this is the first time I am seeing (0k) as used space.

Thank you all for the replies

Best Regards

What was the machines uptime at the time of that "free"?



Cheers,
Tink
 
Old 02-13-2008, 11:49 PM   #9
procfs
Member
 
Registered: Jan 2006
Location: Sri Lanka
Posts: 608

Original Poster
Rep: Reputation: 34
Hi Tinkster

This server with (0k) used swap machine has been up for some time (could say 20 or more days). Considering the amount of time this server has been up I would expect some amount of swap space to be used (am I correct)
I have another server with 8G RAM and I did a reboot, even it just started I can see 300k is been used from swap.

Regards
 
Old 02-14-2008, 12:06 AM   #10
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910
Well ... as I said in 2nd last post: add up the values
that processes use up. It is quite possbile that the
machine doesn't need to page anything out at all.


Cheers,
Tink
 
Old 02-14-2008, 12:45 AM   #11
procfs
Member
 
Registered: Jan 2006
Location: Sri Lanka
Posts: 608

Original Poster
Rep: Reputation: 34
Thanks Tink
 
  


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
swap file instead of swap disk "dd" error rezwits Linux - Newbie 5 12-16-2007 12:34 AM
Need Help Increasing Swap by creating a swap file froggo Red Hat 3 06-13-2006 08:04 AM
Linux swap / solaris not appearing as swap in Ubuntu? Erik_the_Red Linux - Newbie 1 07-30-2005 12:57 PM
How to unmount actual swap and mount a new(bigger) swap space? isaac Linux - Newbie 1 06-06-2004 01:23 AM
Difference between Swap Virtrual memory and Swap Parition Nappa Slackware 4 11-27-2003 07:58 PM


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