Performance Tweaks

Email: joseph.koshy@gmail.com

This page contains a grab-bag of various performance-related tweaks for FreeBSD. Once I collect enough material I'll write up something along the lines of a proper article.

  • If your machines are on a fast, local (i.e., low-latency) network and large amounts of buffering need not indicate a high latency, try sysctl -w net.inet.tcp.inflight.enable=0 (this is now default in -current for local links).
  • Setting "sysctl -w net.inet.tcp.delayed_ack=0" speeds up Cyrus IMAP and Postfix. Link.
  • If you're using UFS and have large directories, increasing the value of the vfs.ufs.dirhash_maxmem sysctl can deliver dramatic performace improvements by allowing UFS to cache the directory in kernel memory. The default value is 2097152 (i.e., 2MB), and the vfs.ufs.dirhash_mem sysctl shows how much is currently being used.
  • If you're using 7.0-RELEASE, try running with ULE scheduler

External Links

  • performancetweaks.txt
  • Last modified: 2026/10/12 10:55
  • (external edit)