When the server starts, the primary and secondary caches are empty. When Advanced Server processes a client request, the server reads the required data from disk and stores a copy in each cache. You can improve server performance by warming (or pre-loading) the data into the memory cache before a client asks for it.There are two advantages to warming the cache. Advanced Server will find data in the cache the first time it is requested by a client application, instead of waiting for it to be read from disk. Also, manually warming the cache with the data that your applications are most likely to need saves time by avoiding future random disk reads. If you don't warm the cache at startup, Advanced Server performance may not reach full speed until the client applications happen to load commonly used data into the cache.
• Use the edb_icache_warm utility to warm the caches from the command line.
• Use the edb_icache_warm() function from within edb-psql.
• Use the edb_icache_warm() function via scripts to warm the cache.While it is not necessary to re-warm the cache after making changes to an existing cache configuration, re-warming the cache can improve performance by bringing the new configuration of cache servers up-to-date.184.108.40.206 The edb_icache_warm() FunctionThe edb_icache_warm() function comes in two variations; the first variation warms not only the table, but any indexes associated with the table. If you use the second variation, you must make additional calls to warm any associated indexes.The first form of the edb_icache_warm() function warms the given table and any associated indexes into the cache. The signature is:You may specify table_name as a table name, OID, or regclass value.When you call the first form of edb_icache_warm(), Advanced Server reads each page in the given table, compresses the page (if configured to do so), and then sends the compressed data to an Infinite Cache server. edb_icache_warm() also reads, compresses, and caches each page in each index defined for the given table.The second form of the edb_icache_warm() function warms the pages that contain the specified range of bytes into the cache. The signature of the second form is:You must make subsequent calls to specify indexes separately when using this form of the edb_icache_warm() function.The edb_icache_warm() function is typically called by a utility program (such as the edb_icache_warm utility) to spread the warming process among multiple processes that operate in parallel.You can use the edb_icache_warm command-line utility to load the cache servers with specified tables, allowing fast access to relevant data from the cache.The syntax for edb_icache_warm is:# edb_icache_warm –d database –t tablenameThe only required parameter is tablename. tablename can be specified with or without the -t option. All other parameters are optional; if omitted, default values are inferred from Advanced Server environment variables.The options for edb_icache_warm are:
The name of the host running Advanced Server. Include this parameter if you are running Advanced Server on a remote host.