[Bug 219251] [Panic] [VIMAGE] [pf] panic when creating/destroying multiple vnet jails

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Sun Jul 9 17:56:48 UTC 2017


https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=219251

--- Comment #2 from commit-hook at freebsd.org ---
A commit references this bug:

Author: kp
Date: Sun Jul  9 17:56:39 UTC 2017
New revision: 320848
URL: https://svnweb.freebsd.org/changeset/base/320848

Log:
  pf: Fix vnet purging

  pf_purge_thread() breaks up the work of iterating all states (in
  pf_purge_expired_states()) and tracks progress in the idx variable.

  If multiple vnets exist this results in pf_purge_thread() only calling
  pf_purge_expired_states() for part of the states (the first part of the
  first vnet, second part of the second vnet and so on).
  Combined with the mark-and-sweep approach to cleaning up old rules (in
  V_pf_unlinked_rules) that resulted in pf freeing rules that were still
  referenced by states. This in turn caused panics when pf_state_expires()
  encounters that state and attempts to access the rule.

  We need to track the progress per vnet, not globally, so idx is moved
  into a per-vnet V_pf_purge_idx.

  PR:           219251
  Sponsored by: Hackathon Essen 2017

Changes:
  head/sys/netpfil/pf/pf.c

-- 
You are receiving this mail because:
You are the assignee for the bug.


More information about the freebsd-net mailing list