How does /dev/pf get created?

Gavin Spomer spomerg at cwu.EDU
Fri Jan 25 07:44:09 PST 2008


First of all, thanks! :)

>>> Tommy Pham <tommyhp2 at YAHOO.com> 01/24/08 5:17 PM >>>
Check your /etc/make.conf.  I remember that you can disable it if
NO_PF=YES is not commented out. 

   I only have 3 lines in my /etc/make.conf: a comment and 2 lines about what perl to use. Is NO_PF=YES the default if not
   specified? In that case adding NO_PF=NO and then building may work.

Also, I remember reading it somewhere
that pf requires 'device bpf' in the kernel (which you might want to
check for that too). 

   I read that somewhere too and it is indeed left uncommented.

I presume you used a copy of GENERIC kernel file
and comment out what you don't need...? 

   That is correct. I did: cp GENERIC MACHINEHOSTNAME and edited MACHINEHOSTNAME w/ vim.

If so, did you specify the
kernel file name in the /etc/make.conf or in the command line
KERNCONF=<filename>?

    I did it via the command line:
      make buildkernel KERNCONF=MACHINEHOSTNAME
      make installkernel KERNCONT=MACHINEHOSTNAME

    Shouldn't having "device pf" in MACHINEHOSTNAME file and building provide /dev/pf?

   I have such a vanilla installation of FreeBSD, it's hard for me to see where I went wrong. I seem to have all the
   components of pf except /dev/pf. I have /sbin/pfctl, /etc/pf.conf, /boot/kernel/pf.ko, /boot/kernel/pflog.ko and the
   appropriate stuff I mentioned in /etc/rc.conf and probably others as well. I just don't have /dev/pf. How does this get
   created?

Regards,
Tommy

--- Gavin Spomer <spomerg at cwu.EDU> wrote:

> I have followed the instructions in the FreeBSD Handbook for
> implementing pf, but when I run pfctl -e, I get:
> 
>    pfctl: /dev/pf: No such file or directory".


More information about the freebsd-pf mailing list