Project

General

Profile

Bug #25169

No /dev/bpf in iocage managed jail

Added by Patrick M. Hausen about 3 years ago. Updated about 3 years ago.

Status:
Closed: Behaves correctly
Priority:
No priority
Assignee:
Brandon Schneider
Category:
Middleware
Target version:
Seen in:
Severity:
New
Reason for Closing:
Reason for Blocked:
Needs QA:
Yes
Needs Doc:
Yes
Needs Merging:
Yes
Needs Automation:
No
Support Suite Ticket:
n/a
Hardware Configuration:
ChangeLog Required:
No

Description

Hello,

trying to create an iocage managed jail to run a local DHCP server. Isc-dhcpd needs bpf(4) to work.

To reproduce:

root@freenas-pmh:~ # iocage activate zfs
root@freenas-pmh:~ # iocage create -r 11.0-RELEASE
[...]
e40d14c3-43b0-40cc-a05a-9f95d441b180 (2017-07-17@17:40:24:691730) successfully created!
root@freenas-pmh:~ # iocage set vnet=on e40d14c3
root@freenas-pmh:~ # iocage set bpf=on e40d14c3
root@freenas-pmh:~ # iocage set dhcp=off e40d14c3
root@freenas-pmh:~ # iocage set ip4_addr="vnet0|217.29.46.107/27" e40d14c3
root@freenas-pmh:~ # iocage set defaultrouter="217.29.46.97" e40d14c3
root@freenas-pmh:~ # iocage start e40d14c3
root@freenas-pmh:~ # iocage csonsole e40d14c3

root@e40d14c3-43b0-40cc-a05a-9f95d441b180:~ # ifconfig    # vnet0 is there, alright
root@e40d14c3-43b0-40cc-a05a-9f95d441b180:~ # ping 217.29.46.97    # working
root@e40d14c3-43b0-40cc-a05a-9f95d441b180:~ # ls -l /dev/bpf*
ls: No match.

Kind regards,
Patrick

History

#1 Updated by Dru Lavigne about 3 years ago

  • Assignee changed from Release Council to Brandon Schneider
  • Private changed from No to Yes

#2 Updated by Brandon Schneider about 3 years ago

  • Status changed from Unscreened to Closed: Behaves correctly

The new iocage port does not have DHCP support yet, this won't be a feature in 0.9.9, but may land in 1.0. In the meantime I suggest creating your own devfs ruleset and setting that on the jail.

#3 Updated by Patrick M. Hausen about 3 years ago

Brandon, thanks. But you mean "bpf support", not "DHCP support", right? I'm not trying to configure the jail with DHCP but to run a DHCP server inside the jail - which requires bpf.

Thanks for clarifying.
Patrick

#4 Updated by Brandon Schneider about 3 years ago

Patrick,

Yeah as far as iocage is concerned it's the same thing. A devfs ruleset will be all you need to unmask the bpf device and by setting the property on the jail you will be able to use it inside. As I said, there isn't any short term plans for this inside iocage itself. There eventually will be.

Using DHCP or running a DHCP server will both require bpf, so that's why the property was originally called dhcp. I'll likely branch them off this time, for finer granularity. But just do what I said above and you'll be golden :)

#5 Updated by Dru Lavigne about 3 years ago

  • File deleted (debug-freenas-pmh-20170717201202.tgz)

#6 Updated by Dru Lavigne about 3 years ago

  • Target version set to N/A
  • Private changed from Yes to No

Also available in: Atom PDF