vRozenSch00n
Active Member
@wlanboy & everybody in this thread, I need your suggestion. This is my /etc/sysconfig/varnish setting:
The backend uses Apache + xcache (Kloxo)
When I check with for example: curl -I http://mywebsite.com
The first attempt always shows: X-Cache: MISS
Is that normal?
Is it OK?VARNISH_RUN_USER=varnish
VARNISH_RUN_GROUP=varnish
# Maximum number of open files (for ulimit -n)
NFILES=131072
# Locked shared memory (for ulimit -l)
MEMLOCK=82000
# Maximum number of threads (for ulimit -u)
NPROCS="unlimited"
# Maximum size of corefile (for ulimit -c). Default in Fedora is 0
# DAEMON_COREFILE_LIMIT="unlimited"
RELOAD_VCL=1
# # Should probably change this
VARNISH_VCL_CONF=/etc/varnish/default.vcl
# # Not setting VARNISH_LISTEN_ADDRESS makes Varnish listen on all IPs on this box (Both IPv4 and IPv6 if available). Set manually to override this.
# VARNISH_LISTEN_ADDRESS=
VARNISH_LISTEN_PORT=80
# # Telnet admin interface listen address and port
VARNISH_ADMIN_LISTEN_ADDRESS=localhost
VARNISH_ADMIN_LISTEN_PORT=6082
# # Shared secret file for admin interface
VARNISH_SECRET_FILE=/etc/varnish/secret
# # The minimum number of worker threads to start
VARNISH_MIN_THREADS=1
# # The Maximum number of worker threads to start
VARNISH_MAX_THREADS=1000
# # Idle timeout for worker threads
VARNISH_THREAD_TIMEOUT=120
# Best option is malloc if you can. malloc will make use of swap space smartly if you have it and need it.
VARNISH_STORAGE_TYPE=malloc
#VARNISH_STORAGE_TYPE=file
VARNISH_STORAGE_FILE=/var/lib/varnish/varnish_storage.bin
# # Cache file size: in bytes, optionally using k / M / G / T suffix, in percentage of available disk space using the % suffix.
VARNISH_STORAGE_SIZE=384M
VARNISH_STORAGE="${VARNISH_STORAGE_TYPE},${VARNISH_STORAGE_SIZE}"
#VARNISH_STORAGE="${VARNISH_STORAGE_TYPE},${VARNISH_STORAGE_FILE},${VARNISH_STORAGE_SIZE}"
# # Default TTL used when the backend does not specify one
VARNISH_TTL=120
VARNISH_POOL_DELAY=2
VARNISH_POOL_CPU=2
#<800 / Number of CPU cores>
VARNISH_POOL_MIN=400
VARNISH_POOL_MAX=4000
VARNISH_SESSION_LINGER=50
VARNISH_SESS_WORKSPACE=262144
# # DAEMON_OPTS is used by the init script. If you add or remove options, make
# # sure you update this section, too.
DAEMON_OPTS="-a ${VARNISH_LISTEN_ADDRESS}:${VARNISH_LISTEN_PORT} \
-f ${VARNISH_VCL_CONF} \
-T ${VARNISH_ADMIN_LISTEN_ADDRESS}:${VARNISH_ADMIN_LISTEN_PORT} \
-t ${VARNISH_TTL} \
-w ${VARNISH_MIN_THREADS},${VARNISH_MAX_THREADS},${VARNISH_THREAD_TIMEOUT} \
-u ${VARNISH_RUN_USER} -g ${VARNISH_RUN_GROUP} \
-S ${VARNISH_SECRET_FILE} \
-p thread_pool_add_delay=${VARNISH_POOL_DELAY} \
-p thread_pools=${VARNISH_POOL_CPU} \
-p thread_pool_min=${VARNISH_POOL_MIN} \
-p thread_pool_max=${VARNISH_POOL_MAX} \
-p session_linger=${VARNISH_SESSION_LINGER} \
-p sess_workspace=${VARNISH_SESS_WORKSPACE} \
-s ${VARNISH_STORAGE}"
The backend uses Apache + xcache (Kloxo)
When I check with for example: curl -I http://mywebsite.com
The first attempt always shows: X-Cache: MISS
Is that normal?