locked
Wincache.php indicates 100% memory usage but nothing cached RRS feed

  • Question

  • User-134510173 posted

    So after my production site runs for a while and I look at the statistics with the wincache.php file, it will indicate the opcode and file cache are using 100% of the memory however no files in either cache.  As soon as I recycle the app pool, the statistics immediately return to normal.  I've currently set the application pool to automatically recycle every 60 minutes as a safety precaution.

    My Wincache Settings

    wincache.chkinterval 60
    wincache.enablecli 0
    wincache.fcachesize 50
    wincache.fcenabled 1
    wincache.fcndetect 1
    wincache.filecount 4096
    wincache.ignorelist factory.php|index.php|filesystem.php
    wincache.internedsize 4
    wincache.maxfilesize 256
    wincache.ocachesize 200
    wincache.ocenabled 1
    wincache.reroute_enabled 0
    wincache.scachesize 8
    wincache.srwlocks 1
    wincache.ttlmax 1200
    wincache.ucachesize 8
    wincache.ucenabled 1

    My Server Environment

    WinCache version 1.3.7.4
    PHP version 5.6.8
    PHPRC C:\Program Files (x86)\PHP\v5.6.8\
    Server software Microsoft-IIS/8.5
    Operating System Windows NT 6.2
    Processor information Intel64 Family 6 Model 62 Stepping 4, GenuineIntel
    Number of processors 8
    PHP session handler wincache
    Application Pool ID Vectors Live
    Site ID 4
    FastCGI impersonation enabled

    Tuesday, May 5, 2015 2:44 PM

All replies

  • User409000176 posted

    Since you're on PHP 5.6, I would highly suggest using the Zend Opcache as your opcode cache.

    As for running your file cache out of memory: The maximum size of the WinCache file cache is 255MB.  If you get into a state where the file cache is reporting all memory in use, but no files actually cached, that's most likely memory corruption in WinCache's cross process shared memory segment for the file cache.  Restarting your site is the only recourse.

    If you feel helpful, please capture a full heap dump of php-cgi.exe when you get into that situation, and contact me.  I'd like to examine the cache memory to see how it got into that situation.

    Thx!

        --E.

    Monday, May 11, 2015 2:09 PM
  • User-134510173 posted

    I have a dump for you, but where/how do I upload it.  The wincache stats at the time are below,  Basically, nothing in cache and all memory is in use.

    I will also switch to Zend as suggested - thankyou

    Cache uptime 9 minutes 54 seconds
    Cached files 0
    Hits 0
    Misses 0
    Total memory 200 MB
    Available memory 506.74 kB
    Memory overhead 6.73 MB
    Number of functions 0
    Number of classes 0

    File Cache Overview
    Cache uptime 9 minutes 54 seconds
    Cached files 0
    Total files size 0 B
    Hits 0
    Misses 0
    Total memory 50 MB
    Available memory 5.82 kB
    Memory overhead 299.44 kB

    Tuesday, May 12, 2015 12:17 PM