Solved

OS paging / swapping

Posted on 2002-03-08
3
420 Views
Last Modified: 2013-12-27
Hi..i;m new to solaris.
i need some clarification on
OS paging / swapping .

1) what it is.
2) how it could affect solaris server
3) how to monitor/control it.


 tq.
0
Comment
Question by:maliksl4141
  • 2
3 Comments
 
LVL 5

Accepted Solution

by:
Nisus091197 earned 10 total points
ID: 6851032
Hi,

This is a brief introduction ...

1.

Paging / swapping are related to memory usage.  When a process is created the OS reserves a certain amount of swap space in case the process needs to be written to the swap file/partition if the physical memory runs short.

Paging is part of the normal process of reading in code from programs etc.

2.

If a system is swapping processes out of memory a lot then this is indicative of a shortage in physical memory.  The performance of the system can be drastically effected as accessing swapped processes is around 1000 times slower than from physical memory.  Disk I/O is very slow compared with RAM.

A system that is doing a lot of swapping often appears idle as the CPU is waiting for the process to be reloaded into memory.  Closer examination will reveal that a number of processes are blocked while they await their turn.

3.

Under Solaris, we use 'vmstat' to monitor physical and virtual memory (i.e. swap space).

If you suspect a system of swapping a lot, then run:

vmstat 5

and let it run for several minutes.

The numbers in the middle columns should ideally be 0 but 200-300 is not uncommon on busy database servers.

Have a look at the vmstat man page for more detailed info on this very handy tool.

The best way to improve the situation is to add more RAM and/or reduce the load on the server.  Some processes like database servers and BroadVision instances can take up a lot of memory.

The 'ps' command can tell you how much memory a process is using (see the RES column).

Swap space is modified using the 'swap' command.  'swap -a' can add a new swap file temporarily, 'swap -l' will list the swap devices.

Hope this helps,

Regards, Nisus
http://www.omnimodo.com
0
 

Author Comment

by:maliksl4141
ID: 6851979
thanks for introducing me to 'vmstat'
0
 
LVL 5

Expert Comment

by:Nisus091197
ID: 6852027
my pleasure.

When you get time check out iostat and netstat.  These are very useful also.
0

Featured Post

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Linux :how to provide sudo access to the user 13 96
NTP Server in VMware 5 210
Linux: disable vim auto-comment 7 116
Retreiving column names in Windows but not in Unix 11 42
When you do backups in the Solaris Operating System, the file system must be inactive. Otherwise, the output may be inconsistent. A file system is inactive when it's unmounted or it's write-locked by the operating system. Although the fssnap utility…
Every server (virtual or physical) needs a console: and the console can be provided through hardware directly connected, software for remote connections, local connections, through a KVM, etc. This document explains the different types of consol…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
In a previous video, we went over how to export a DynamoDB table into Amazon S3.  In this video, we show how to load the export from S3 into a DynamoDB table.

813 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now