[Previous]   [Next]   [Contents]   [Index]   

Using X Station Memory Effectively

This chapter explains how you can make the most effective use of your HP X station memory and how you can diagnose and solve memory-related problems.

Topics include:

Understanding How the X Station Uses Memory

HP X stations have a number of features that enhance performance by storing data in local memory rather than going over the network to get information from the host.

When your HP X station has memory available, it can store the parts of windows obscured by other windows (a feature called backing store) and, if you use local terminal emulators, it can retain the terminal emulator template so that your next terminal emulator window opens quickly. In addition, HP X stations use internal caches to store information that is used frequently. Use of these caches improves performance but requires sufficient X station memory. Performance features that require the most amount of memory include:

You can disable any of these features if you need additional memory. In the long term, you can optimize the performance of your X station by adding one or more additional memory SIMMs. Refer to Adding More Memory.

If you have very limited memory (or severely fragmented memory) your X station may not be able to start the clients you need. For example, if you request a local client when you have insufficient memory, the X station tries to reclaim memory internally. However, if it cannot retrieve enough memory, you will see a popup informing you that the local client cannot be started. (If you have disabled popup messages, check the log screen for similar messages.) The X station can automatically reclaim memory from the following areas:

If memory was freed from any of these areas, the X server tries to execute the request again. If there is enough free memory, your request will execute successfully. However, when memory is reclaimed from backing store or other caches, performance suffers slightly as clients are required to go to the host for window updates and font requests.

If the X station was unable to free sufficient memory, the local client will respond with an appropriate message. If this occurs continually and you have followed the recommendations in Optimizing Memory: Recommendations, you may wish to purchase more memory for your X station. In the interim, if you want to disable the warning popup message, you can modify the remote configuration file and disable the following variables:

For more information about these variables, refer to Remote Configuration Parameter Reference.

Making the Best Use of X Station Memory

If you want to make best use of the X station memory, there are several configuration parameters you can modify and a number of X session choices you can make. Some of these choices require that you compromise between performance, appearance, and memory usage to find the type of operation that meets your needs. Refer to:

Optimizing Memory: Recommendations

In general, you can make the best use of your X station's memory by following some or all of the following recommendations:

Modifying Backing Store

Backing Store is a configuration parameter that controls how the X station stores the parts of windows obscured by other windows. You can modify this parameter as follows:

  1. Press and hold [F12] to access the configuration screens.

  2. Select the [Server] configuration screen

  3. Click on the [Backing store] field and select a value as follows:
You can also set the backing store parameter in the remote configuration file.
Note: An application can request backing store "ALWAYS". This means that windows will remain in backing store even when not mapped.

Modifying Font and Glyph Caching

If you have limited X station memory available, you may wish to disable font and glyph caching. (First refer to Understanding Font Caching and Understanding Glyph Caching for more information about these features.)

To turn off font caching, you can either:

To turn off glyph caching:

Using Local Clients and X Station Memory Effectively

Local clients are applications (including terminal emulators or window managers) that run on the X station rather than the host computer. As you might expect, local clients can require a great deal of X station memory.

While you are free to use local clients in any way you want, if your X station only has memory for only one kind of local client, you may want to use a local window manager rather than a local terminal emulator.

Use of a local window manager:

How Much Memory Do Local Clients Need?


Note: This section applies only if you are using X11R5 clients. If you are running in an English-language environment (LANG=C), you use X11R4 clients by default.

Local clients use shared libraries. This feature reduces the amount of memory required for local clients once the first one is loaded.

Individually, local clients require memory as follows:

First xterm:
1.0 MB
Next xterm:
410 KB
First hpterm:
2.2 MB
Next hpterm:
730 KB
vt320:
2.6 MB
xflash:
2.9 MB
vuerx:
3.1 MB
dtwmlite:
3.1 MB
mwm:
2.1 MB
twm:
890 KB
xclock:
730 KB
xlock:
540 KB

The following clients are used on Sun systems only:

olwm:
575 KB
First cmdtool:
1.4 MB
Next cmdtool:
300 KB
First shelltool:
1.4 MB
Next shelltool:
300 KB
First clock:
1.4 MB
Next clock:
300 KB

Combinations of clients require substantially less than the combined totals. For example, sample scenarios including ENWARE VUE/RX include:

hpterm + vuerx:
4.1 MB
xterm + vuerx:
3.6 MB

Using Downloadable Extensions

Downloadable extensions are operating characteristics that you can build into your X server the next time you reboot your X station.

Some extensions, such as SNMP V2, may require additional X station memory. For example, when the 10 KB multibuffering extension is used, it can require up to 1 MB of X station memory in the course of updating a large window in memory before "flipping" that data to the display. If you are concerned about X station memory, you should avoid loading these extensions, or load them only as required.

To turn off any downloadable extensions that you do not use, comment out the appropriate lines in the modules.ld file (basepath/bin/modules.ld).

Using a Font Server to Save Memory

If your system has a font server, you can change your font path to use the font server rather than the standard bitmapped fonts supplied with the ENWARE software. By doing this, you can save 600 KB of X station memory over the default font path.

To configure the X station to use a font server, refer to the steps in Using Fonts from a Font Server.

Using a 4 MB X Station

If you have an X station (for example, an HP ENTRIA X terminal) that has 4 MB of memory, you may have difficulty loading some clients. You can save memory by:

Adding More Memory

Depending upon which local clients you use, you may need to add additional memory to your X station. The following memory expansion cards are available:

HP X stations have memory slots as follows:

The steps for installing memory are essentially the same for all HP X stations. The following diagram illustrates how to install additional memory in an ENVIZEX `p' series:

Interleaving Memory

If you need additional memory, you can install one or more SIMMs (memory cards). When you add two SIMMs that are the same size (e.g., two 4MB SIMMs), you can achieve slightly higher performance if you place them in the preferred slots that allow the memory to be interleaved.
Model
Preferred SIMM slots
ENVIZEX `a' & `i' series
Install two same-size SIMMs in slots 1 and 2 or in slots 3 and 4.
ENVIZEX `p' series
Install two same-size SIMMs in slots 1 and 2.
ENTRIA/Aptrex
Install two same-size SIMMs in slots 1 and 2
HP 700RX
Install two same-size SIMMs in slots 1 and 2.

Understanding the X Station Memory Statistics

To view the X station memory statistics:

  1. Press and hold [F12] to access the configuration screens.

  2. Click on [Diagnostics], then click on [Memory Statistics]. You will see a screen similar to the following:
                      Memory Statistics
Amount Installed        10240 KB
Free Pool:  current      5749 KB     Number of fragments  125
           low mark      5269 KB     Largest fragment    5602 KB
Used by backing store       0 KB     Used by font cache   220 KB
Backing store reclaimed     0 times  Cached fonts          20

Make sure the "Amount Installed" reflects the amount you believe to be installed in your X station.

In this case, 10240 KB matches the quantity installed in this X station: an 8 MB memory module combined with the 2 MB of memory on the X station's CPU board. If two 8 MB memory modules were installed but only 10240 KB of memory was reported, that would indicate that one memory module was not properly seated in its connector or was faulty.

The "Free Pool" is a collection of statistics that describes the memory actually available for use. The "current" statistic is the amount of memory theoretically available for use by the X station. However, there are some restrictions on how an application can use the memory; for example, it can't ask for a piece larger than the largest fragment. Thus, all of the memory available may not be usable at a given time.

The difference between the "current" value and the "Largest fragment" values is explained by the "Number of fragments," as explained in What Is Memory Fragmentation?

The "low mark" records the smallest amount of free memory that has been available since the X station was last switched on or the [Clear Stats] button was selected.

What Is Memory Fragmentation?

Memory fragmentation is the breaking down of the memory pool into "non-contiguous" pieces. It occurs when pieces of free memory are separated by pieces of memory that are being used by processes. Here is how it happens.

Suppose that we represent all the free memory by this line of 0s:

 0000000000000000000000000000000000000000000

Now, if you open a window that uses up memory represented by 1s and a second window represented by 2s, the following happens:

 11111111122222222222200000000000000000000000

If you close window 1, it frees up that memory:

 00000000022222222222200000000000000000000000

If you open another window, it uses up memory represented by 3s.

 33333300022222222222200000000000000000000000
       ^^^

The group of three 0s is a memory fragment that is not going to be useful unless you have an application that requires that small amount of memory or if the memory on either side also becomes free and can merge together with it.


[Previous]   [Next]   [Contents]   [Index]