Page MenuHomeFreeBSD

tcp_hostcache: ensure expire and prune values stay consistent with each other
Needs ReviewPublic

Authored by rscheff on Thu, Jul 23, 7:09 PM.

Details

Summary
While getting more information around PR296474 it was found that existing
configurations can end up with unexpectedly long pruning intervals, which
defy an explict short expire timeout of the hostcache entries.

When configuring the expire timeout to something short, make sure that the
prune time runs at least at that interval. Similarly, when adjusting the
prune interval up, ensure the expire timeout reflect that expected minimum
time also.

MFC after 3 days alongside D58360

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 75057
Build 71940: arc lint + arc unit

Event Timeline

pouria added inline comments.
sys/netinet/tcp_hostcache.c
184

Can we use UINT here?

636
638–639

Maybe use u_int?

  • also restart the callout so the next pruning will occur at the expected time