Navigation:  Deprecated > OptimumCache >


Previous pageReturn to chapter overviewNext page





64bit CloudLinux 6.x or higher

ext4 filesystem

kernel lve1.2.55 or later.




# yum install optimumcache


OptimumCache must be provided with list of directories to expect duplicate files be in:


# occtl --recursive --mark-dir /home


# occtl --recursive --mark-dir /home2 (for cPanel)


# occtl --recursive --mark-dir /var/www (for Plesk)


OptimumCache is going to index these directories. Thus system load during this period (from hours to days) might be as twice as high. See 'Marking directories' [].


Allocating Disk Space for OptimumCache:


By default OptimumCache will attempt to setup 5GB ploop (high efficiency loopback disk) to be used for the cache in  /var/share/optimumcache/optimumcache.image


That ploop will be mounted to: /var/cache/optimumcache


The ploop image will be located at /var/share/optimumcache/optimumcache.image


Allocating OptimumCache disk space for ploop on a fast drives (like SSD) will provide additional performance improvement as more duplicated files would be loaded from fast disks into memory.


Moving ploop image to another location:


# occtl --move-ploop /path/to/new/image/file [new size[KMGT]]


/path/to/new/image/file must be file path + file name, not a directory name.



# occtl --move-ploop /var/ssh/optimumcache.image


If ‘new size’ is not mentioned, then value from /etc/sysconfig/optimumcache is used. If /etc/sysconfig/optimumcache does not mention anything regarding ploop image size, then default 5GB is used.


Enabling and disabling ploop:


To turn on ploop:


# occtl --init-ploop


To disable ploop:


# occtl --disable-ploop


If ploop image has been mounted in /etc/fstab for OpimumCache-0.1-21 and earlier, you may consider removing this fstab entry in OpimumCache 0.2+. That is because since 0.2+ ploop is mounted automatically at service start.


If you prefer leave that fstab mount point as is, you may see some warnings when you decide to move ploop later via ‘occtl --move-ploop’.


Resizing ploop:


To resize ploop:


# occtl --resize-ploop [new size[KMGT]]


A common reason for resizing ploop is reacting to OptimumCache syslog message like “OptimumCache recommends cache storage size to be at least … GB”


Deleting ploop:


# occtl --delete-ploop


For the case when this action cannot be completed due to “Unable unmount ploop” issue, there is a workaround in “Troubleshooting” section.


Q. I created/resized/moved/deleted ploop. Do I need to rerun the initial mark process?

А. Not needed.