-
_xor
crest: Heh, funny you mention that. I'm literally working on some code right now for my nomad plugin.
-
polyex
what will it do xor?
-
crest
_xor: which plugin is that?
-
_xor
crest: I wanted to originally use OCI to package and distribute jail images, but OCI isn't very ZFS friendly (yet). It expects tarballed layers with whiteouts.
-
crest
did you write the jail task driver or the pot one?
-
polyex
crest btw which firewall works best with fbsd bhyve and jails? pf or ipfw?
-
_xor
crest: Neither, both of those are written in Go. Mine is written in Rust.
-
crest
-
VimDiesel
Title: xc/ocitar at main · michael-yuji/xc · GitHub
-
crest
is that you?
-
_xor
Also, from what I saw, those drivers didn't support netgraph.
-
_xor
Nope, but I did recently see that project. In fact, the one and only issue on the repo is from me heh.
-
polyex
why isnt oci zfs friendly?
-
_xor
-
_xor
That's me.
-
VimDiesel
Title: Questions · Issue #1 · michael-yuji/xc · GitHub
-
VimDiesel
1 – [aha] [scsi] Toshiba MK156FB scsi drive does not work with 2.0 kernel
bugs.freebsd.org/bugzilla/show_bug.cgi?id=1
-
crest
depends on your definition of zfs friendly
-
_xor
OCI is fairly Linux-centric (though has generic mechanisms like annotations) and expects tarballs for its layers.
-
_xor
Would have to figure out how to specify a base image + incremental snapshots to apply, though that shouldn't be too terribly difficult.
-
polyex
"in fact ipfw seems to be a better choice than pf for a lot of the things I'm interested to do"
-
polyex
wow just what i was thinking about
-
polyex
i've been a pf user and it's fine but i wondered if ipfw is better now that i'm getting deeper into fbsd
-
» RhodiumToad prefers ipfw
-
_xor
How come?
-
» _xor hasn't used ipfw since early 2000s
-
crest
imo ipfw is better suited to automation and its more expressive tables can vastly reduce the number of rules
-
crest
but pf has the more human friendly syntax and pfsync in its favour
-
_xor
What are the trade-offs?
-
_xor
ah
-
crest
and ipfw tends to scale better to higher core counts
-
RhodiumToad
I've always heavily used the tables, which is probably why I prefer it
-
_xor
HashiCorp just went BSL for a lot of their projects. Doesn't impact that much...yet, but it might dim the outlook a bit :/
-
RhodiumToad
BSL?
-
_xor
Really? Because it's userland?
-
_xor
RhodiumToad: Business Source License
-
crest
i like to think of PF as a ready to use firewall and IPFW as firewall construction kit
-
_xor
-
VimDiesel
Title: HashiCorp Switches to BSL License | Hacker News
-
_xor
Whatever happened to ipf?
-
crest
_xor: died over a decade ago, but nobody buried the corpse
-
_xor
lol
-
» RhodiumToad uses WITHOUT_IPFILTER and WITHOUT_PF on builds
-
» _xor is convinced to check out ipfw again
-
crest
why? they're kernel modules. keeping the modules doesn't hurt
-
RhodiumToad
those options remove the userland programs etc.
-
_xor
Man, that was annoying.
-
» _xor just got his package delivered
-
_xor
Ordered a bundle of CAT6 + RJ45 ends. Turns out, the CAT6 I got is 23 gauge while the RJ45 heads were 24+ gauge only. Had to order new RJ45 ends for 23 gauge.
-
» _xor was mounting and wiring up his PoE security camera when he found this factoid out
-
polyex
ya i really wanna see pkgbase and other ways to cut down fbsd to only what's needed
-
polyex
i might try ipfw too
-
_xor
pkgbase will do that. It does for me. You can thank meena.
-
polyex
crest what does ipfw do better for automation?
-
polyex
ty meena!!
-
crest
you can put the structure into the ruleset and later populate the tables
-
RhodiumToad
I've done a fair bit of stuff where ips are automatically added and removed from tables
-
crest
to express almost all things you want to automate
-
polyex
pf has tables like that too no? and anchors i think they're called?
-
RhodiumToad
much easier to manage those than mess directly with the ruleset
-
crest
pf tables are just sets of ip addresses
-
polyex
ya
-
polyex
these are more?
-
crest
ipfw tables can match more fields in the packet (protocol, port, etc.) and map them to values
-
crest
with up to one value per type per entry
-
crest
e.g. a rule number and an interface
-
_xor
That's one of my biggest gripes with pf, handling dynamic management of rules.
-
crest
what pf does have are (nested) anchors
-
_xor
Yeah, I use those with nomad (kind of).
-
polyex
does ipfw have something comparable to nested anchors?
-
crest
and you can feed it the rules for anchors from a pipe
-
crest
polyex: often times it doesn't need them to accomplish the same
-
crest
and if your do need something there are sets of rules
-
crest
(iirc up to 31 sets)
-
_xor
I run nomad as an unprivileged user and so my driver needs to add a mapping for ports <1024 (assuming it's running on the host and not within a jail).
-
polyex
ah ok. just wanted to make sure i could SWITCH to ipfw, not start having to use ipfw AND pf
-
_xor
I do that with nested anchors + rdr rules.
-
crest
_xor: there is a mac module to allow this
-
crest
mac_portacl
-
polyex
is there anything pf can do that ipfw can't do and do well?
-
crest
you also have change the low port range for it to take effect
-
crest
but if you want to you set it to stop at e.g. port 22
-
» _xor is reading mac_portalacl(4)
-
_xor
mac_portacl(4) I mean
-
_xor
Well, I mean I'd rather not have any of that at all and just let it just use random unprivileged ports within a specific range.
-
_xor
But for a narrow set of services that I'm still using nomad to deploy, I need to be able to bind those to privileged ports (e.g. Traefik for tcp/80 + tcp/443, etc).
-
_xor
I mean I guess I could also set it up with ng_nat, but all of that is a hassle.
-
crest
why go through netgraph?!?
-
_xor
Because I'm using it currently for my jails?
-
RhodiumToad
ipfw can do local port mappings without nat
-
_xor
Lol, on a side note, I just noticed this while looking at CAD packages in ports...
-
_xor
"The BRL-CAD source code repository is the oldest known public version-controlled codebase in the world that's still under active development, dating back to 1983-12-16 00:10:31 UTC."
-
RhodiumToad
if they mean that they still have a repo going back that far, they could well be right
-
polyex
is there anything pf can do that ipfw can't do and do well?
-
SpaceBass
New to Pouderie... after some tinkering and learning, I built a dedicated box (VM) and gave it a lot of resources... but it doesnt seem to be using them, I get slow builds and low resource utilization
-
SpaceBass
Any tips on optimizing a box for pouderirie?
-
SpaceBass
(I speak French and for the life of me I can't spell that word)
-
rtprio
haha
-
rtprio
sorry, can't answer that question
-
SpaceBass
(The spelling or the optimization? Haha)
-
RhodiumToad
what settings have you changed from defaults?
-
RhodiumToad
and how much RAM do you have?
-
RhodiumToad
and how many CPUs?
-
SpaceBass
RhodiumToad, I didn't change much, just the required stuff, ZFS pool
-
RhodiumToad
it's worth noting that poudriere can often be very disk-bound, unless you use tmpfs for everything, which requires a shedload of ram
-
SpaceBass
12 CPU cores, 24gb
-
RhodiumToad
have you looked at what is going on during a build?
-
RhodiumToad
specifically disk i/o bottlenecks as well as cpu or memory
-
SpaceBass
I'll check disk IO now
-
SpaceBass
Unrelated, does 14.0 not have a pam.d/auth or pam.d/account?
-
rtprio
SpaceBass: mine doesn't
-
SpaceBass
Thanks for checking - just wanted to make sure
-
SpaceBass
Next challenge... install python 11
-
SpaceBass
3.11
-
rtprio
there's a package (or port) for that
-
SpaceBass
Yeah installed it... but 3.9 was default and now I have to get it all sorted
-
SpaceBass
Trying to get certbot to work in 14.0-CURRENT and it wants 3.9... but it needs a newer version (3.10 +) of cryptotography
-
rtprio
even if you install 3.11 first?
-
nerozero
Hello there
-
nerozero
I'm replacing disk in a raid pool, it starts very quickly but now the system response very slowly
-
RhodiumToad
zfs?
-
nerozero
Forget to notice ZFS 2way mirror
-
nerozero
yes
-
nerozero
211G resilvered, 63.99% done, 01:39:04 to go
-
nerozero
the progress is about 1% in 15-20 minutes
-
nerozero
What will happen if I restart machine during resilver / replace
-
nerozero
the strange thing is that the new drive ( seagate barracuda ) is slow to response for smartctl queries
-
RhodiumToad
it should pick up where it left off
-
nerozero
gstat ops is almost 0
-
RhodiumToad
is it an SMR drive?
-
nerozero
queue - 2 .. 16 ...
-
nerozero
SMR?
-
RhodiumToad
shingled magnetic recording
-
RhodiumToad
gives a significant increase in storage density at the expense of having the write performance go completely to shit on a regular basis
-
nerozero
Seagate BarraCuda 3.5 (SMR)
-
nerozero
smr...
-
nerozero
yeh
-
RhodiumToad
basically, large portions of the disk area can be written only in large sequential blocks
-
RhodiumToad
so writes accumulate on temporary areas of the disk and then have to be rewritten to the shingled zones, which takes a long time
-
nerozero
So the only option is to wait resilver to complete
-
RhodiumToad
yup
-
nerozero
:(
-
polyex
if i script bsdinstall, what does bsdinstall do with that script to make a bootable OS? and can we just do whatever bsdinstall does and make images that can be preconfigured then directly booted and run? like skipping any manual install or setup
-
nerozero
RhodiumToad, thank you for quick reply
-
nerozero
polyex, create partition, write bootcode
-
» RhodiumToad has a bunch of smr drives for bulk mostly-read-only storage, so is very familiar with the write slowdowns
-
nerozero
RhodiumToad, unfortunately this is a first experience to me
-
RhodiumToad
polyex: sure, making a bootable system without bsdinstall isn't hard, especially if you know the disk setup in advance
-
nerozero
never had SMR drive
-
polyex
what's the basic process like?
-
RhodiumToad
starting from a fresh disk: gpart create, gpart add (possibly several times), gpart bootcode
-
nerozero
gpart destroy -F /dev/disk # cleanup entire disk
-
RhodiumToad
then newfs or zpool init
-
nerozero
^
-
RhodiumToad
if it's EFI, then preparing the ESP is a few more steps if you don't want to do the hackjob that's used for bootable images
-
RhodiumToad
(newfs_msdos and a few file copies, nothing too tricky)
-
RhodiumToad
then installing the OS can be done by unpacking the distribution txz files, or by make installworld distribution installkernel from a source tree
-
RhodiumToad
then set up whatever config files you need
-
RhodiumToad
(if not using zfs, remember to create /etc/fstab, that's the one that usually bites me when I do manual image creation)
-
nerozero
RhodiumToad, fstab is required anyway, swap partition things
-
nerozero
polyex, do not forget to create extra swap partition at least 16GB or better 2xRAM
-
polyex
hmm i wonder how to automate all of that
-
RhodiumToad
well, that's a large part of bsdinstall's job :-)
-
RhodiumToad
but otherwise it's just a matter of scripting
-
nerozero
polyex, here is my old script
-
nerozero
-
VimDiesel
Title: dpaste/4JQe (Bash)
-
nerozero
this will partition the disk for you
-
nerozero
it is very old, dont remember what I did back then
-
RhodiumToad
that looks like it supports both EFI and legacy boot, usually not needed these days
-
RhodiumToad
(though sometimes is)
-
meena
polyex: you know you can script bsdinstall, right?
-
nerozero
yes, but I did this script basically to restore ZFS images back to the system
-
polyex
ya
-
nerozero
universal is good :)
-
nerozero
say you name script: "partitiondisk.sh", you can create config file like: "partitiondisk.cfg" in the same location
-
nerozero
here is the sample of the config:
bsd.to/2GNP
-
VimDiesel
Title: dpaste/2GNP (Bash)
-
nerozero
polyex, the installation things is quite easy, just download and extract files into root directory of newly created partition
-
nerozero
-
nerozero
base.txz, kernel.txz, lib32.txz, src.txz
-
nerozero
src is optional, but I do like to have them, need to compile something time to tile
-
polyex
prep disk, extract files, copy in config files, boot?
-
nerozero
yep
-
nerozero
that easy
-
nerozero
I love BSD approach - all the configs are text, all the logs a re text
-
polyex
any way to bundle all of that up, even the disk prep stuff, so you can do it all in like 1 step?
-
nerozero
exactly
-
RhodiumToad
yes, that's literally bsdinstall :-)
-
nerozero
^^^
-
nerozero
bsdinstall doing BEADM things, which I do not like
-
nerozero
RhodiumToad, Thank you so much! You saved me a day. ANd a hard talk with a sales manager in a shop
-
» nerozero AFK
-
SpaceBass
Im struggling a lot with pam.d and winbind auth... log says user is successfully authenticated and then pam_winbind(sshd): PAM_ESTABLISH_CRED not implemented
-
rtprio
cd
-
polyex
what does BEADM things mean?
-
parv
Before "beadm" was the precursor of "bectl". So I would say the way that command works or is used to create boot environment
-
parv
s/Before//
-
polyex
oh and nerozero said bsdinstall does beadm stuff, so it needs to be updated to use bectl?
-
megaTherion
bectl is the successor to beadm
-
parv
Cannot say what nerozero actually meant
-
megaTherion
(oh parv said that already, sorry)
-
polyex
ty!
-
alfonso
polyex: vermadem is the author of BEADM, he is active on twitterX and on his blog
-
parv
... on Mastodon: vermaden⊙bc
-
meena
how do i get local_unbound to listen on the private network IP, as well as localhost?
-
rtprio
it would no longer be local_ if it listed on the network ip
-
meena
I want jails on the host to use it, but they can't reach it without that
-
SpaceBass
I have a remote machine connected via VPN. Iperf3 between the client and NFS server is about ~250Mbps. But copying (rsync) files to the NFS mount is less than 1Mbps... any tips on troubleshooting?
-
RhodiumToad
meena: "interface: ..." in the config?
-
meena
RhodiumToad: *nod*
-
RhodiumToad
SpaceBass: what's the latency?
-
SpaceBass
Ill check in a second... other issue (affecting me currently) is that tab complete locks up the system for a good 90 seconds
-
SpaceBass
180ms
-
RhodiumToad
that's not at all good for nfs
-
SpaceBass
Would that cause painfully slow write speeds though?
-
meena
SpaceBass: 90 s or 180 ms?
-
RhodiumToad
depends... which protocol and transport?
-
SpaceBass
188.959 ms
-
SpaceBass
It's v4 (assume UDP?... )
-
RhodiumToad
tab complete may well be doing a whole lot of stat() calls, each of which will take a round-trip
-
RhodiumToad
v4 is tcp only iirc
-
SpaceBass
Ah, it is tcp
-
SpaceBass
FWIW I'm trying to tab complete in ~ not in /mnt/foo/bar
-
RhodiumToad
oh
-
RhodiumToad
~ is on local disk?
-
SpaceBass
Tab complete could be unrelated but it started being an issue when I started using this mount
-
SpaceBass
Yeah ~ is local (SSD in fact)
-
RhodiumToad
any symlinks involved?
-
SpaceBass
Not yet :) ... rsync /foo/bar /mnt/server/share/foo/bar
-
RhodiumToad
tab complete in which shell?
-
RhodiumToad
might be instructive to ktrace the shell while trying a tab complete and see what's slow
-
SpaceBass
zsh
-
SpaceBass
Setting aside the tab issue for now... it's the painfully slow writes that are killing me... is this a place to use something like nfs cache? Or cachets?
-
SpaceBass
S/cachets/cachefs
-
parv
There are various time-outs (see "zshall(1)"); gave up before finding one that would clearly apply to completion
-
parv
s/clear/obvious/
-
RhodiumToad
SpaceBass: is this rsync with or without --whole-file and if without, does the file already exist?
-
RhodiumToad
SpaceBass: and is the callback path enabled and does the server do delegations?
-
SpaceBass
Without --whole-file, new files (dont exist yet)
-
SpaceBass
Im unfamiliar with the concept of a callback path... server is FreeBSD too FWIW
-
RhodiumToad
is nfscbd_enable="YES" set in rc.conf / is nfscbd running
-
RhodiumToad
is the filesystem on the server also accessed locally on the server, or only via nfsv4 clients?
-
SpaceBass
RhodiumToad, its only via nfsv4 clients
-
RhodiumToad
is vfs.nfsd.issue_delegations set
-
RhodiumToad
(on the server)
-
RhodiumToad
(however "Unfortunately, at this time, client use of delegations is limited, so performance gains may not be observed.")
-
RhodiumToad
if you look at the rsync writing process in top while this is going on, what wait channel is it usually showing?
-
SpaceBass
Let me check
-
SpaceBass
Wait
-
SpaceBass
Oops... uwait
-
RhodiumToad
probably not the right process or thread
-
RhodiumToad
uwait is waiting on a umutex, which generally means contention on some thread lock
-
RhodiumToad
maybe try top -CSH
-
RhodiumToad
ir 0CSHz
-
RhodiumToad
*or -CSHz
-
» RhodiumToad should probably get out of the habit of specifying -C, it makes no difference on SCHED_ULE, only on SCHED_4BSD
-
SpaceBass
Checking