Bug 257330 - net-mgmt/lldpd: Fails to run in some configurations: CRIT/privsep] unable to create chroot directory: Operation not permitted
Summary: net-mgmt/lldpd: Fails to run in some configurations: CRIT/privsep] unable to ...
Status: Open
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Some People
Assignee: freebsd-ports-bugs (Nobody)
Keywords: needs-qa
Depends on:
Reported: 2021-07-22 10:59 UTC by Volodymyr Kostyrko
Modified: 2021-07-29 09:28 UTC (History)
1 user (show)

See Also:
bugzilla: maintainer-feedback? (freebsd)
koobs: merge-quarterly?


Note You need to log in before you can comment on or make changes to this bug.
Description Volodymyr Kostyrko 2021-07-22 10:59:47 UTC

On some configurations lldpd attempts to create files in chroot. As on BSDs /var/empty is locked for modifications this is not allowed, so I get:

2021-07-22T13:24:21 [CRIT/privsep] unable to create chroot directory: Operation not permitted

The /var/empty exists and is not writable. Using /var/run/lldpd as a chroot works.

Thanks in advance.
Comment 1 Kubilay Kocak freebsd_committer freebsd_triage 2021-07-29 02:20:05 UTC

  - Does the port fail to run in the/with the default configuration?
  - What is the minimum configuration required to reproduce the issue?
Comment 2 Volodymyr Kostyrko 2021-07-29 09:28:20 UTC
Well, there are some good questions...

I have two installations on two distinct hosts. And the first works perfectly fine:

FreeBSD limbo.b1t.name 12.2-STABLE FreeBSD 12.2-STABLE r370131 MIN  amd64

if_re (driver from ports

The second doesn't:

DragonFly probe2 6.1-DEVELOPMENT DragonFly v6.1.0.385.g101bb-DEVELOPMENT #5: Wed Jul 28 23:16:28 EEST 2021     arcade@probe2:/usr/obj/usr/src/sys/DMIN  x86_64

ath0: AR9220

In both cases default configuration was used, works on first host after install+onestart, doesn't work on second one in same way. All defaults.

This might be triggered with something about WiFi or something about DragonFly. I'll try to install FreeBSD on the same host and recheck.

I created a ticket just because:
1. Change originated from FreeBSD ports, not DPorts.
2. It looks illogical to use /var/empty for chroot, as you can't even get /dev in there.

But yeah, it's a fair question, I'll try to retest on FreeBSD.