1. 28 Aug, 2017 4 commits
    • Poul-Henning Kamp's avatar
      This MegaCommit replaces the VSM implementation. · 74328de8
      Poul-Henning Kamp authored
      Instead of having a single mmap(2)'ed file inside which we allocate
      the necessary chunks, put each chunk in its own file and use two index
      files (MGR/CHILD) to keep track of them.
      
      Major benefits:
      
      * You don't need to guess how much VSM space you need at startup.
      
      * VSM chunk Identifier (and therefore VSC counter names) are unlimited length.
      
      Minor benefits:
      
      * VSM API has simpler and explainable semantics now.
      
      * The bogo-you-didnt-guess-right-malloc-VSM allocations are gone.
      
      * -t argument moves up/down to VSM level and works the same through-out.
      
      * VSM/VUT utils now stay attached even if the MGT process restarts.
      
      Some relatively minor adjustments are still to come before the VSM API is frozen
      and the .map file finalized for the release.
      74328de8
    • Nils Goroll's avatar
      use an alternative stack for SIGSEGV and test for stack overflow · 438cc27e
      Nils Goroll authored
      Previously, we could run out of stack handling stack overflows, leaving
      users with unspecific SIGSEGV crashes and no panic message.
      
      By providing a single alternative stack exclusively for SIGSEGV handling
      where sigaltstack() is available, we increase chances for our signal handler
      to finish successfully.
      
      In particular, this will make it easier to diagnose stack overflows by
      comparing the failing address with the stack info from the panic output.
      
      This could be further improved by giving advise to increase thread_pool_stack
      if si_addr is near the stack boundaries.
      
      c00057.vtc now triggers a stack overflow instead of raising a SIGSEGV.
      
      Merges #2396
      438cc27e
    • Nils Goroll's avatar
      start generalizing the signal handler · 88557be0
      Nils Goroll authored
      it was already used for more than SIGSEGV, so we should output the actual
      signal description.
      88557be0
    • Dridi Boukelmoune's avatar
      Add the TTL, grace and keep to Hit log records · 8edf31f1
      Dridi Boukelmoune authored
      For HitMiss and HitPass, only show the remaining TTL. Seeing these
      values should help debugging of timing-sensitive transactions. The
      grace and keep periods are absolute, but the TTL is the remaining
      time relative to the current request. Same as obj.{ttl,grace,keep}
      variables in VCL.
      8edf31f1
  2. 24 Aug, 2017 4 commits
  3. 23 Aug, 2017 1 commit
  4. 22 Aug, 2017 2 commits
  5. 21 Aug, 2017 3 commits
  6. 19 Aug, 2017 6 commits
  7. 18 Aug, 2017 10 commits
  8. 17 Aug, 2017 3 commits
  9. 16 Aug, 2017 1 commit
    • Pål Hermunn Johansen's avatar
      Fix problem with purging and the n_obj_purged counter · c21fae9a
      Pål Hermunn Johansen authored
      When the do..while loop in HSH_Purge executes on a oh with many
      popular variants, there is a potential problem with the "array" of oc
      pointers, allocated in the thread workspace. If many of the oc's have
      positive refcounts, they will fill up the array and
      
      	EXP_Rearm(oc, now, ttl, grace, keep);
      	(void)HSH_DerefObjCore(wrk, &oc, 0);
      
      will be called several on the same oc's. At the same time, the counter
      n_obj_purged will be updated with a too low number.
      
      The test case demonstrates how we get a too low value for this counter,
      but it is not able to force varnishd to use a siginificant amount of CPU.
      c21fae9a
  10. 15 Aug, 2017 2 commits
  11. 14 Aug, 2017 4 commits