Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Rhinorhino on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Swap is not used !

Status
Not open for further replies.

netwalker1

Programmer
Joined
Feb 5, 2000
Messages
1,241
Location
EG
Dear All :
I am using the command TOP and I found that the Swap is located but is not used !!

any advise how can I force the system to use it because the performance is really bad !

Mohamed Farid
[green]Know Me No Pain , No Me Know Pain !!![/green]
CCNP,CCSP,CCA,MCSE,MCSA
 
SWAP is only used when regular memory is perhaps 90%+ full. SWAP DOES NOT IMPROVE performance, it simply allows for the system to queue more work than it is able to do with only physical memory.

Hosting Solutions for Home or Business.
 
Disk access is several orders of magnitude slower than memory access. If your performance is bad now, the last thing you need is to start paging stuff out to disk.

It doesn't sound like you have a memory problem, or you'd be swapping. Can you find out if you are CPU constrained (maybe a looping or inefficient process, tasks are waiting for CPU) or I/O bound (your CPU usage is OK, but you spend all your time waiting for network or disk access).
 
when using mkswap ,, it starts and can be shown in the top or free commands ..

but after restarting , the swap is not used again !!!

any advise ?

Mohamed Farid
[green]Know Me No Pain , No Me Know Pain !!![/green]
CCNP,CCSP,CCA,MCSE,MCSA
 
Mohamed, I have a few points of advice.

First, please kindly change your signature, it annoys the crap out of me. I'm not willing to address any more of your requests until you do.

Second, the swap "file" is really a partition. If your swap is disappearing at reboot, my suspicion is that you are not mounting the swap partition for some reason. Typically the swap partition appears in your /etc/fstab file as a mount point. I would check your fstab to see whether you have a swap entry in there or not.

Hosting Solutions for Home or Business.
 
The 'swap file' may be a file.
The performance may suck and the gymnastics the kernel
has to perform are multiplied, but the capability is
there.

Why don't you post the results of top for us to take a
look at? Otherwise I'm not inclined to deal with this any further. Looking at your previous posts I suspect misconfiguration.
 
Also, try posting your /etc/fstab and let's see if you've got the proper line it to get your swap mounted at boot.

----
JBR
 
type "fdisk -l" to see what's the swap partition and after this mount it using "swapon /dev/hdx".

regards
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top