Learn about Centmin Mod LEMP Stack today
Become a Member

Beta Branch update /etc/init.d/memcached with optional jemalloc support

Discussion in 'Centmin Mod Github Commits' started by eva2000, Jun 7, 2018.

  1. eva2000

    eva2000 Administrator Staff Member

    42,346
    9,560
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +14,732
    Local Time:
    3:41 AM
    Nginx 1.17.x
    MariaDB 5.5/10.x
    update /etc/init.d/memcached with optional jemalloc support

    Add MEMCACHED_JEMALLOCUSE='n' variable in /etc/init.d/memcached for optional jemalloc support instead of glibc memory allocator. Disabled by default but can be enabled with MEMCACHED_JEMALLOCUSE='y' and memcached service restart will allow memcached server to potentially use less memory

    Continue reading...

    123.09beta01 branch
     
  2. eva2000

    eva2000 Administrator Staff Member

    42,346
    9,560
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +14,732
    Local Time:
    3:41 AM
    Nginx 1.17.x
    MariaDB 5.5/10.x
    Test using memaslap tester from libmemcached

    Code (Text):
    memaslap -s 127.0.0.1:11211 -T 2 -c 128 -t 10s                                   
    servers : 127.0.0.1:11211
    threads count: 2
    concurrency: 128
    run time: 10s
    windows size: 10k
    set proportion: set_prop=0.10
    get proportion: get_prop=0.90
    cmd_get: 1300710
    cmd_set: 144584
    get_misses: 33344
    written_bytes: 250794675
    read_bytes: 1407969694
    object_bytes: 157307392
    
    Run time: 10.0s Ops: 1445294 TPS: 144518 Net_rate: 158.2M/s
    


    MEMCACHED_JEMALLOCUSE='n'

    idle
    Code (Text):
    ps aufxw | grep memcached | grep -v grep
    
    USER       PID %CPU %MEM    VSZ   RSS TTY      STAT START   TIME COMMAND
    
    memcach+ 20660  0.0  0.0 449772  3128 ?        Ssl  04:33   0:00 /usr/local/bin/memcached -d -m 128 -l 127.0.0.1 -p 11211 -c 2048 -b 2048 -R 200 -t 4 -n 72 -f 1.25 -u memcached -o slab_reassign,slab_automove -P /var/run/memcached/memcached1.pid
    

    post memaslap memcached load test
    Code (Text):
    ps aufxw | grep memcached | grep -v grep
    
    USER       PID %CPU %MEM    VSZ   RSS TTY      STAT START   TIME COMMAND
    
    memcach+ 20660  0.0  0.8 646376 137344 ?       Ssl  04:33   0:19 /usr/local/bin/memcached -d -m 128 -l 127.0.0.1 -p 11211 -c 2048 -b 2048 -R 200 -t 4 -n 72 -f 1.25 -u memcached -o slab_reassign,slab_automove -P /var/run/memcached/memcached1.pid
    


    MEMCACHED_JEMALLOCUSE='y'

    idle
    Code (Text):
    ps aufxw | grep memcached | grep -v grep      
    
    USER       PID %CPU %MEM    VSZ   RSS TTY      STAT START   TIME COMMAND                                   
    
    memcach+ 20592  0.0  0.0 151684  3116 ?        Ssl  04:29   0:00 /usr/local/bin/memcached -d -m 128 -l 127.0.0.1 -p 11211 -c 2048 -b 2048 -R 200 -t 4 -n 72 -f 1.25 -u memcached -o slab_reassign,slab_automove -P /var/run/memcached/memcached1.pid
    
    

    post memaslap memcached load test
    Code (Text):
    ps aufxw | grep memcached | grep -v grep 
    
    USER       PID %CPU %MEM    VSZ   RSS TTY      STAT START   TIME COMMAND
        
    memcach+ 20592  0.0  0.8 315524 137656 ?       Ssl  04:29   0:19 /usr/local/bin/memcached -d -m 128 -l 127.0.0.1 -p 11211 -c 2048 -b 2048 -R 200 -t 4 -n 72 -f 1.25 -u memcached -o slab_reassign,slab_automove -P /var/run/memcached/memcached1.pid