-
Notifications
You must be signed in to change notification settings - Fork 137
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[BUG] bastille rc script should require SERVERS #698
Comments
Hmm, in fact, I think that I see all devices from /dev in /usr/local/bastille/jails/minio/root/dev as well.
|
Okay, if I replace the rule in ruleset 1 with
then it seems to fix the problem. Looks like it's a regression in FreeBSD? |
Well, that change should not make any difference, what made the difference was re-applying the ruleset. So, I circled back to the original rc script problem: bastille is started before rc.d/devfs is run, so bastille does not see the rulesets.
|
/me too - I've seen this behaviour when rebooting a bastille host. In view of the statement in the bastille docs https://docs.bastillebsd.org/en/stable/chapters/jail-config.html
this does seem to be a real issue. I'm wondering if it would also be possible to add a warning to jail startup if the jail.conf specifies a devfs ruleset that can't be found? |
@cedwards, could you please take a look at this? |
JFYI, as a workaround, on FreeBSD I created #!/bin/sh
#
# PROVIDE: _bastille
# REQUIRE: jail
# BEFORE: bastille securelevel
# KEYWORD: shutdown and it moved start of bastille after |
That's a very nice trick. Thank you. |
Thank you @avg-I for the finding and detailed information. I'm not sure if making it require Now, I can see
which way is preferable? cc @cedwards Mine is to require |
[FIX] bastille rc script to require jail closes #698
Thank you! |
I confirm this also helps when using |
On one of my systems I noticed that (host) syslogd stopped logging any kernel messages.
I see them at console but they do not get into any logs files (including /var/log/messages).
My syslogd configuration is pretty standard, so that was a big puzzle for me.
Long story short, it turns out that (host) syslogd fails to open /dev/klog:
Unfortunately, syslogd is pretty quiet about that, so it took a while to notice it.
The reason for
EBUSY
is that bastille gets started before syslogd, it starts some jails and apparently one of jailed syslogd-s grabs /dev/klog:However, having said that, I am not sure why /dev/klog is not hidden in the jail.
I checked that /usr/local/bastille/jails/minio/jail.conf has the default jail ruleset:
Maybe that's because the device entry is created with
MAKEDEV_ETERNAL
flag.I see that all devices created with that flag appear in jails, even though they are not "unhidden" in any devfs rules, e.g. /dev/geom.ctl.
Bastille has been installed from the FreeBSD package repo (quarterly):
0.10.20231125
13.3-RELEASE-p2
13.3-RELEASE-p2
13.3-RELEASE-p2
The text was updated successfully, but these errors were encountered: