home *** CD-ROM | disk | FTP | other *** search
/ Mega Top 1 / os2_top1.zip / os2_top1 / INFO / FAQS / OS2FAX1 / OSOTSWAP.FAX < prev    next >
Encoding:
Text File  |  1994-12-20  |  10.8 KB  |  263 lines

  1. OSOTSWAP - MEMORY AND SWAPPER INFORMATION
  2. 11/09/94
  3.  
  4. ================================================================
  5.              MEMORY AND SWAPPER INFORMATION
  6. ================================================================
  7.  
  8.  
  9. MEMORY
  10. ----------------------------------------------------------------
  11.   OS/2 runs on 4MB.  Depending on the application mix,
  12.   and the desired performance, memory requirement needs
  13.   vary.  Generally, the system should have enough memory to
  14.   avoid excessive amount of swapping activity.
  15.  
  16.   Question:  What are the symptoms of poor performance
  17.              caused by insufficient amount of memory ?
  18.   A. Excessive amount of hard disk activity caused by constant
  19.      swapper activity.  In extreme cases, the disk light may be
  20.      constantly active even if system is not being actively used.
  21.   B. Performance degradation - It takes an excessive amount of
  22.      time to do anything.  In extreme cases, it might take
  23.      several minutes for the task list to be displayed after
  24.      pressing Ctrl+Esc.  Solution:  Adding additional memory
  25.      alleviates the above symptoms.
  26.  
  27.  
  28. SWAPPER
  29. -----------------------------------------------------------------
  30.  
  31.   Question:  How much disk space should be allowed for swapper
  32.              file growth ?
  33.   A. It depends on the number of applications, the kind of
  34.      applications running and the amount of memory in the system.
  35.      Symptoms:  If getting SWAPPER FULL (if COMMIT=OFF) or LOW
  36.      MEMORY (if COMMIT=ON) messages, then you are not allowing
  37.      enough free disk space for swapper growth. Performance
  38.      drops tremendously, because of increased swapper activity,
  39.      and in extreme cases, the system may halt or trap.
  40.  
  41.      If you are monitoring swapper file size, you learn the size
  42.      of the typical swapper file size under normal system usage.
  43.  
  44.  
  45.  
  46. MEMORY ALLOCATIONS
  47. ----------------------------------------------------------------
  48.   When an application requests memory, the system gives the
  49.   application, regardless of the amount request, 4k blocks of
  50.   memory.  (4096 bytes) out of a 64k segment.  Example:  if the
  51.   process requests 5100 bytes, the system will allocate 64k
  52.   segment of which 8192 bytes can be used for this process.  If
  53.   applications have a large number of small memory allocation
  54.   requests, memory being used by this process may not be what
  55.   is expected.
  56.  
  57.  
  58. MEMORY ALLOCATION LIMITS
  59. ----------------------------------------------------------------
  60.   As documented in the programming guide volume 1 (S10G-6261-00)
  61.   and the Redbook Volume 1 (GG24-3730-00), it is theoretically
  62.   possible to allocate 512MB (Virtual address space).  This, of
  63.   course is based on the systems available ram and disk space.
  64.   This 512MB area is divided into 3 parts:
  65.  
  66.  
  67. ---------------    512 MB
  68. |             |
  69. | A (64MB)    |    Reserved
  70. |             |
  71. ---------------    448 MB
  72. |             |
  73. | B (64MB)    |    Shared Virtual address space
  74. |             |
  75. - - - - - - - -    384 MB
  76. |             |
  77. |             |
  78. |             |
  79. |             |
  80. |             |
  81. | C           |    Private and shared virtual
  82. |             |    address space
  83. |             |
  84. |             |
  85. |             |
  86. |             |
  87. ---------------    0 MB
  88.  
  89.   Section A is reserved for future enhancements to the operating
  90.   system and can be used by changing the PROTECT option in
  91.   MEMMAN statement located in the CONFIG.SYS to NOPROTECT.
  92.   Section A would then be used by section B.  Section B is
  93.   allocated at bootup time for shared memory and can grow into
  94.   section C.  Section C is used by private and shared memory and
  95.   the more shared memory is allocated, the less private address
  96.   space will be available.  Please refer to the Redbook or the
  97.   programming guide Volume 1 for further information.
  98.  
  99.  
  100.  
  101. SWAPPER GROWS AND WILL NOT SHRINK.
  102. ----------------------------------------------------------------
  103.   The swapper file will grow when an application is started and
  104.   there isn't enough available RAM to run.  The swapper file
  105.   attempts to shrink back to its original size after application
  106.   is ended.  More than likely the size of the swapper file
  107.   remains bigger.
  108.  
  109.   Swapper file shrinkage begins approximately 30 seconds
  110.   after there is no system activity, assuming no process with
  111.   higher priority is running.
  112.  
  113.   SWAPPATH's second parameter, in CONFIG.SYS, defines the minimum
  114.   size of the swapper file.  The swapper file does not shrink to
  115.   a size smaller than the swap file size specified by SWAPPATH's
  116.   second parameter.
  117.   NOTE:  The first parameter in the SWAPPATH statement specifies
  118.          the minimum amount of free space in KB that can remain
  119.          on the partition where the SWAPPER.DAT file is located
  120.          before a warning notifies you that the swapper file has
  121.          increased to a size that leaves less than this amount
  122.          on the disk.
  123.  
  124.  
  125. SOME UTILITIES FOR ANALYZING MEMORY AND SWAPPER ACTIVITY
  126. ----------------------------------------------------------------
  127.   THESEUS2 which comes as part of the SPM/2 product, sold by
  128.   IBM, shows amount of used and free swapper space and has
  129.   many other additional functions for analyzing memory and
  130.   swapper usage.
  131.  
  132.   OS20MEMU, can be downloaded from the IBM PCC BBS at
  133.   919-517-0001 shows the amount of swapper in use.  The
  134.   difference between that number and the size of SWAPPER.DAT is
  135.   the free swapper space.
  136.  
  137.   DINFO, can be downloaded for free from IBM PC BBS,
  138.   monitors swapper size and remaining disk space.
  139.  
  140.   NOTE: OS/2 determines the optimum initial swapper size
  141.         according to the amount of memory in system.  This value
  142.         can be overridden by the changing the second SWAPPATH
  143.         parameter in CONFIG.SYS
  144.  
  145. SIZE OF SWAPPER FILE IS TOO BIG
  146. ----------------------------------------------------------------
  147.   An application is probably using up a lot of memory.  Using a
  148.   utility program like OS20MENU can help determine which program
  149.   is using an excessive amount of memory.
  150.  
  151.   There remains the issue where the SWAPPER.DAT grows to a large
  152.   value (usually greater that 20MGS), as a result of a large
  153.   resource allocating application which when terminated does not
  154.   free up all of the memory it requested.  This is termed as a
  155.   "memory leak" originating from application.  The manufacturer
  156.   of the application should be contacted for assistance.
  157.  
  158.   If getting SWAPPER FULL (if COMMIT=OFF) or LOW MEMORY
  159.   (if COMMIT=ON) messages, then you are not allowing enough free
  160.   disk space to allow for swapper growth.  Performance drops
  161.   tremendously due to increased swapper activity, and in
  162.   extreme cases, the system may halt or trap.
  163.  
  164.   If you are monitoring swapper file size, you will get a feel
  165.   for the size of the typical swapper file size under normal
  166.   system usage.
  167.  
  168. SYS0008 ERROR MESSAGE when running memory intensive applications
  169. ----------------------------------------------------------------
  170.   This may be caused by having swapper file in a partition with
  171.   a large amount of free disk space.  This is a known problem
  172.   that has been fixed and will be incorporated in ServicePak for
  173.   OS/2 2.1 or the next version of OS/2.  As a work around, place
  174.   swapper file on a partition with less than 100MB of free space.
  175.  
  176. SYS1477 THE PARTITION CONTAINING SWAPPER.DAT IS FULL
  177. ----------------------------------------------------------------
  178.   A potential problem may occur because all OS/2 processes
  179.   continue running after receiving a SYS1477 "Out of Swapper"
  180.   warning message.  The possibility of a system crash exists if
  181.   these processes continue allocating memory.
  182.  
  183.   The SYS1477 Swapper File Full message is just a warning
  184.   message to informs you that it needs more disk space in order
  185.   for the swapper file to grow.  However, it is not designed to
  186.   allow usage of the system under low disk space conditions in
  187.   the swapper partition without running the risk of causing a
  188.   system failure.
  189.  
  190.   You should understand that while the SYS1477 message is being
  191.   displayed, all processes continue running.  If any one of the
  192.   processes continues allocating memory while the SYS1477
  193.   message is displayed, and you do not respond to it quickly
  194.   enough, this may cause OS/2 to run out of memory and halt the
  195.   system with an Internal Processing Error (IPE).  In very fast
  196.   machines, or if the system is very busy.  It is possible for an
  197.   application to consume the remaining memory and cause an IPE
  198.   before SYS1477 message has time to come up.
  199.  
  200.  
  201. SUGGESTIONS TO MINIMIZE THE CHANCES OF PROBLEMS:
  202. ----------------------------------------------------------------
  203. 1.  Provide enough disk space to allow for swapper growth.
  204.  
  205. 2.  Larger "minfree" parameter so that the SYS1477 warning
  206.     message is displayed earlier.
  207.  
  208. 3.  Usage of the "COMMIT" parameter.  This prevents an
  209.     application from running unless there is enough memory
  210.     and swapper resources for the application to run.  You
  211.     should understand that the "COMMIT" parameter allocates
  212.     memory and swapper resources when REQUESTED by the
  213.     application.  If this parameter is not used, resources are
  214.     allocated as NEEDED by the application to run.
  215.  
  216.     EXAMPLE: If an application allocates 16MB of memory but
  217.              does not use the memory, then if "COMMIT" is
  218.              specified it will require a total of 16MB of memory
  219.              and swapper resources for application to run.  If
  220.              "COMMIT" is not used, it may only require 200k of
  221.              memory and swapper resources to run application.
  222.  
  223.  
  224. MEMORY AND SWAPPER UTILITIES
  225. ----------------------------------------------------------------
  226.  
  227.        From IBM PC BBS (free) DINFO - Monitor swapper file and
  228.        remaining disk space.  OS20MEMU - Memory allocation tool.
  229.  
  230.        Utilities from the BBS are provided "as is".  There is no
  231.        customer support provided for these utilities.
  232.  
  233.        Can be ordered from IBM (1-800-426-2255) SPM/2 - Contains
  234.        Theseus2.  More sophisticated than OS20MEMU for analyzing
  235.        memory and swapper.
  236.  
  237.  
  238. ADDITIONAL INFORMATION
  239. ----------------------
  240.  
  241.        You can download utilities, address questions to IBM or
  242.        other OS/2 users from the following BBS or data services.
  243.  
  244.        IBM PC BBS (free) - (919) 517-0001
  245.  
  246.        TalkLink OS/2 BBS - 1-800-547-1283 for information and
  247.        application.
  248.  
  249.        Prodigy - Call Prodigy for information
  250.  
  251.        CompuServe - Call CompuServe for information.
  252.  
  253.        * Refer to the OS/2 Command Reference for additional
  254.        information.
  255.  
  256.  
  257. ----------------------------------------------------------------
  258. IBM disclaims all warranties, whether express or implied,
  259. including without limitation, warranties of fitness and
  260. merchantability with respect to the information in this document.
  261. By furnishing this document, IBM grants no licenses to any
  262. related patents or copyrights.
  263.