Chapter 17. Using Very Large Memory (VLM)60$ cat /etc/redhat-releaseRed Hat Enterprise Linux AS release 4 (Nahant Update 2)$ egrep "shm|tmpfs|ramfs" /proc/filesystemsnodev tmpfsnodev ramfs$This means that if you try to mount a shmfs file system in Red Hat Enterprise Linux 4 or 5, you will getthe following error message:mount: fs type shm not supported by kernelThe difference between shmfs and tmpfs is you do not need to specify the size of the file system ifyou mount a tmpfs file system.17.2. Configuring Very Large Memory (VLM)The following example shows how to use the RAM disk ramfs to allocate 8 GB of shared memoryfor the Oracle 10g database buffer cache on a 32 bit Red Hat Enterprise Linux 3, 4 or 5 systems(hugemem kernel). If this setup is performed on a server that does not have enough RAM, then Linuxwill appear to hang and the kernel will automatically start killing processes due to memory shortage(ramfs is not swappable). Furthermore, ramfs is not backed by Huge Pages and therefore the HugePages pool should not be increased for database buffers, see Chapter 6, Swap Space. In fact, if thereare too many Huge Pages allocated, then there may not be enough memory for ramfs.Since ramfs is not swappable, it is by default only usable by root. If you put too much on a ramfs filesystem, you can easily hang the system. To mount the ramfs file system and to make it usable for theOracle account, execute:# umount /dev/shm# mount -t ramfs ramfs /dev/shm# chown oracle:dba /dev/shmWhen Oracle starts it will create a file in the /dev/shm directory that corresponds to the extendedbuffer cache. Ensure to add the above lines to /etc/rc.local. If ointall is the primary group ofthe Oracle account, use chown oracle:oinstall /dev/shm instead. For security reasons youdo not want to give anyone write access to the shared memory file system. Having write access to theramfs file system allows you to allocate and pin a large chunk of memory in RAM. In fact, you can killa machine by allocating too much memory in the ramfs file system.To enable VLM, set the Oracle parameter use_indirect_data_buffers to true:use_indirect_data_buffers=trueFor 10g R1 and R2 databases it is important to convert DB_CACHE_SIZE and DB_xK_CACHE_SIZEparameters to DB_BLOCK_BUFFERS, and to remove SGA_TARGET if set. Otherwise you will get errorslike these:ORA-00385: cannot enable Very Large Memory with new buffer cache parametersHere is an example for configuring a 8 GB buffer cache for a 10g R2 database with Red HatEnterprise Linux 3, 4 or 5 hugemem kernels: