FOXHUNT ONLINE

THE PLACE FOR ZORRO ONLINE

Varnish cheat sheet

Intro

How to see caching stats etc.

Varnish

  • show hitratio rate

    varnishstat

    Hitrate ratio: 10 100 1000 Hitrate avg: 0.3373 0.3012 0.3400

This Means the last 10 seconds we have a hitrate of 33.73% and the last 100 seconds only 30.12%...

Tmux cheat sheet

Intro

I am trying to use tmux more than screen, but a cheat sheet could be usefull.

Quick and dirty tmux

  • detach from window

    ctrl-b d

  • list sessions

    tmux ls

  • connect to session

    tmux at -t

  • create session

    tmux new -s "session_name" "co...

Bash locking

Intro

Once in a while i want to start a bash script and make sure it one at a time. So searching for solution for creating a lock file in bash, you want to have a solution that doesn't create a race condition.

Explanation

Start defining which lockfile you want to use

export...

Bash debugging

Introduction

Once in a while i need to debug a bash script that i wrote, but i need to search how to get the line number of debug to a file, so easier for me to put it in mij blog, maybe it will help somebody else also.

Howto

Enable debugging

set -x

Add line numbers

...