A.5 Cache Management Commands

Use the commands in this section to manage the cache for NSS volumes on Linux.

A.5.1 Cache Command

nss /MinBufferCacheSize=value

Sets the specified minimum number of NSS buffer cache entries, where value is the number of 4-KB buffers to assign for NSS.

Default: 30000 for NSS on Linux

Range: 10000 for NSS on Linux to the amount of memory in KB divided by 4 KB (the block size). For a 32-bit machine, the maximum setting is 250000 buffers.

A.5.2 High Memory Cache Commands

nss /HighMemoryCacheType=[private | linux | none]

Set the type of use of User memory in 32-bit OES Linux as none, linux, or private. On 64-bit OES Linux, NSS does not use User memory at all.

Cache Type Options
private

Set up a separate user-mode cache in memory outside of the Linux cache. This is the default for 32-bit machines. By default, NSS takes 20 percent of the total high memory. You can modify this setting with the nss /PrivateCacheSizeInBlocks=value command.

However, If the number of Private Cache blocks is less than twice the NSS Cache blocks, then the default high memory cache type is linux. If the high memory is less than twice the NSS Cache blocks, then the default high memory cache type is none.

Private Cache is best used for dedicated file-servers. The Private Cache increases the performance of NSS, but reduces the amount of memory available to other file systems and tasks.

linux

Integrate caching into the regular Linux caches. This is the default for 32-bit machines where the number of Private Cache blocks is less than twice the NSS Cache blocks.

This can be a problem on a dual purpose file-server and application-server system, because memory-hungry applications can cause the file-system cache to purge completely.

none

Use the same algorithm as the initial release of OES 1 Linux, which is to try and cache everything in Kernel-mode memory. This is the only option on 64-bit OES Linux. This is the default for 32-bit machines if the high memory is less than twice the NSS Cache blocks.

nss /PrivateCacheSizeInBlocks=value

Sets the number of metadata blocks to cache for a 32-bit OES Linux machine where you have set the HighMemoryCacheType=private.

By default, NSS takes 20% of all high memory to use for the Private Cache. We recommend against giving NSS 100 percent of the high memory. The actual percentage you should allot depends on your deployment scenario. For example:

  • Which features of NSS are enabled--salvage, compression, and so on.

  • Use of really long filenames

  • Use of extended attributes

Default: 20 percent of all high memory blocks

Range: 0 blocks to the number of blocks available in high memory (total available high memory divided by 4KB)

A.5.3 ID Cache Commands

Use the following command at the nsscon prompt in order to synchronize the cache of eDirectory IDs that is maintained for controlling access to NSS volumes.

nss /IDCacheResetInterval=value

Set the number of seconds between invalidation of the ID cache.

Default: 90000

Range: 0 to 200000000

ResetIDCache

Reset the various eDirectory ID caches.

If you Linux-enable a user who has been logged into the system before being Linux-enabled, ensure to execute the resetidcache command from the NSS Console (nsscon) utility. This allows proper reporting of ownership because it resets the mapping of user identities in the ID cache and forces it to update with the Linux UID for the user.

If you LUM disable the user, ensure to execute the resetidcache command from the NSS Console (nsscon) utility. Run this command after 30 minutes, because NCP server clears its cache periodically at the interval of 30 minutes. This allows proper reporting of ownership because it resets the mapping of user identities in the ID cache.

nss /IDCacheSize=value

Sets the maximum number of entries for NSS GUID to ID and ID to GUID cache.

For example, nss /IDCacheSize = 256000

Default: 16384

Range: 16384 to 524288

A.5.4 Cache Monitoring Commands

CacheStats

Shows the caching statistics for buffers.

ResetStats

Resets caching and file statistics.

A.5.5 UnplugAlways Command for the Read Queue

nss /(no)UnplugAlways

When enabled, this option allows NSS to unplug the device queue after queuing each read. This improves performance significantly on certain workloads, such as Linux copy (cp) command.

NOTE:In OES 2 SP1 Linux, the UnplugAlways default setting is on (enabled). OES 2 SP2 Linux onwards, the UnplugAlways default setting is off (disabled).

For OES 2 Linux, the UnplugAlways default setting is off (disabled). The OES 2 Linux version of this option is available as patch Novell Storage Services (NSS) and Novell Cluster Services (NCS) 20080806 (oes2-novell-nss-5503) for 32-bit and 64-bit architectures. The patch is available on the Novell Downloads Web site.

Examples

Enable UnplugAlways by entering the following at the nsscon prompt as the root user:

nss /UnplugAlways

Disable UnplugAlways by entering the following at the nsscon prompt as the root user:

nss /NoUnplugAlways