-
ShinyCyril
the wabt port appears to be missing a crucial library, but "pkg provides" insists that it should be there. How can I debug this mismatch?
bsd.to/q0fs
-
VimDiesel
Title: dpaste/q0fs (Plain Text)
-
_xor
Why isn't /usr/local/var/{log,run,db} more common?
-
_xor
I almost always see /var/... being used, which is fine, but I'm updating my skeleton (template) port and am contemplating using /usr/local/var/... instead.
-
_xor
With zfs boot environments I see that usually only parts of the /var tree are included, which implies that upgrading base might not carry over some of those files.
-
» _xor feels like he's missing something that makes /usr/local/var/... not recommended
-
_xor
Hmm, "A handful of ports create /usr/local/var and should probably be fixed."
-
laidback_01
hey, I have two machines - one uses 10.123.109.57, the other uses 10.123.109.58 and my intent is to have a VIP of 10.123.109.60 using ucarp. I have ucarp working, all it behave as expected.
-
laidback_01
Now, my point for this is to use HAProxy. so in the config, I'm setting the bind to bind 10.123.109.60:1234 for every whatever port. and that's for the listen. that works. Now, for the outbound, I am seeing attempts at connection on the native address.
-
laidback_01
how do I get the machine to use the virtual ip for outbound connections rather than the native IP? this seems like something I should be able to do and I'm positive this is some kind of routing or similar in FreeBSD ... so that's why I'm asking here not on #haproxy
-
laidback_01
virtual IP is created as an Alias on the same nic as the native IP. so the question could be boiled down to "How do I default outbound traffic to the Alias IP instead of the native IP?"
-
meena
laidback_01: thru routing, usually
-
meena
docs.freebsd.org/en/books/handbook/advanced-networking/#carp nothing here mentions needing to do anything special with routing
-
VimDiesel
Title: Chapter 33. Advanced Networking | FreeBSD Documentation Portal
-
nacelle
usually the software generating the packets needs to know to bind to the other IP, its not something done at the OS layer traditionally
-
hjf_
can jails access serial ports or raw USB devices?
-
hjf_
i'm guessing yes by just setting up the right permissions for the /dev file no?
-
hjf_
i'm thinking of buying a USB zigbee dongle for Homeassistant which I have running inside a jail, idk if this dongle is a device in /dev/usb or if it acts like /dev/ttyS
-
meka
hjf_: you can set up /etc/devfs.rules to unhide devices inside the jail and configure jail to use that ruleset
-
meka
-
VimDiesel
Title: reggae/devfs.rules at master · cbsd/reggae · GitHub
-
hjf_
meka: great thanks.. that's what i was guessing. awesome
-
meka
hjf_: depending how you run your jails, maybe you'd like to use runtime for devfs:
github.com/freebsd/poudriere/blob/m…src/share/poudriere/common.sh#L2006
-
VimDiesel
Title: poudriere/common.sh at master · freebsd/poudriere · GitHub
-
vkarlsen
Portlint fun:
bsd.to/sXWm
-
VimDiesel
Title: dpaste/sXWm (Bash)
-
bsdbandit
good morning
-
bsdbandit
im trying to switch my default version of java from openjdk 8 to openjdk 19 does anyone remember the tool to do that ?
-
bsdbandit
im having a brain fart this morning
-
V_PauAmma_V
bsdbandit, java/javavmwrapper maybe?
-
CrtxReavr
Judicious symlink use?
-
laidback_01
meena, nacelle thanks for the information. I'll see what I can do with haproxy to convince it to use the alias address instead.
-
meena
laidback_01: you just tell it, explicitly, which addresses to listen on.
-
laidback_01
listen is great. works fine. it's the outbound connections that are the problem.
-
meena
weird, why wouldn't it use the listen addresses to respond to a request coming in on them?
-
sjk
Hi! When I run "iocage list" I get this message: "Please set a mountpoint on zroot/iocage/templates"
-
sjk
zfs get mountpoint zroot/iocage/templates tells me its mountpoint is /zroot/iocage/templates, though
-
sjk
templates/ is empty though, I might have accidentally removed its contents
-
sjk
hrm, just remounting it fixed it
-
sjk
*shrug*
-
PredatorONormies
that moment when you fix some problem by restarting the device -_- (not FreeBSD dw)
-
PredatorONormies
shitty device
-
PredatorONormies
hmmm should've used #freebsd-social
-
meena
sjk: iocage has fallen out of support and hasn't received any Bugfixes in at least a year
-
sjk
meena: really? what's all the rage nowadays?
-
lilufo
as a linux user, where would be a good place to get started with FreeBSD?
-
lilufo
I'm interested in learning my way around it
-
sjk
lilufo: i think the handbook on freebsd.org is pretty good
-
lilufo
thanks, I'll give a read through
-
meena
sjk: pot, or cbsd, or, if you don't have many jails, you could just manage them manually with jails.confs, or, if you're adventurous, you can go for podman
-
PredatorONormies
lilufo, FreeBSD's guide, I guess.
-
PredatorONormies
FreeBSD is pretty straight-forward, compared to OpenBSD, I think?
-
lilufo
sjk before I dive into a physical install on my PC, is a virtual machine a good way to practice and check things out?
-
PredatorONormies
Well.. if you're familiar with OpenZFS, that is
-
PredatorONormies
You can install Arch on OpenZFS
-
PredatorONormies
try with FDE and you'll probably cry from pain
-
PredatorONormies
FreeBSD makes it ultra-easy
-
lilufo
oh nice
-
lilufo
it's a good starting point among the BSD's?
-
PredatorONormies
I guess so.. it's friendly enough to me
-
PredatorONormies
But compared to you - I might be too elite
-
PredatorONormies
idk
-
PredatorONormies
shit that is easy to me might not be to some
-
PredatorONormies
for me*
-
lilufo
ah
-
PredatorONormies
I prefer OpenBSD for desktop if you can, but if you can't FreeBSD is good, too, and FreeBSD is, in my opinion, better for storage server stuff
-
PredatorONormies
if for nothing else - at least for dynamic partition sizes and stuff trough OpenZFS
-
meena
PredatorONormies: if you call yourself elite, I'm imagining you're at most 14.
-
PredatorONormies
I'm 9, actually
-
PredatorONormies
It would be extremely dope if I were only 14, and knew about FreeBSD, OpenBSD, some of their pros and cons, etc.
-
PredatorONormies
Imagine that
-
PredatorONormies
It would work in my favor
-
PredatorONormies
somwhat
-
» meena is 38 and has about 22 years of Unix experience and knows nothing, really
-
PredatorONormies
Is that sarcasm?
-
PredatorONormies
I always say - age doesn't matter - one could learn a whole life-time of one's knowledge in just 1 year if they try hard enough.. it SERIOUSLY depends on how fast you learned your knowledge - and how much interested you were in it
-
PredatorONormies
I remember almost nothing from school
-
PredatorONormies
But shit that I learn - I often-times like it, and thus - it's much more easier to remember
-
PredatorONormies
people who hate learning (probably a big part because of FORCED schooling) - won't know shit even if you gave them 200 years of time
-
debdrup
There's probably many channels for that conversation, but #FreeBSD ain't it.
-
sjk
Agreed
-
PredatorONormies
neutral
-
PredatorONormies
you win
-
sjk
Sigh. All of a sudden ezjail went extinct and I had to switch to iocage. Now it's time to switch again. bah!
-
sjk
Looking into pot now
-
sjk
(The software)
-
» debdrup just uses the tools in FreeBSDs base systems, as he doesn't need to orchestrate thousands of jails.
-
debdrup
And with jail.conf.d, orchestrating thousands of jails with base utilities is doable.
-
sjk
hmm
-
sjk
I have seven jails.
-
debdrup
That's easily doable.
-
sjk
I do enjoy pretending I am administering a huuuuge bunch of servers though
-
sjk
But if you can do a whole bunch of jails with just the regular tools
-
sjk
maybe I could do that too :)
-
debdrup
youtube.com/watch?v=S3u8OtjfGFE is, until Someone™ get around to redoing the handbook, the best source of information on how to do jails with tools in base.
-
VimDiesel
Title: 20 Years of FreeBSD Jails (2019) - YouTube
-
sjk
debdrup: yeah, he wrote a book about jails too
-
debdrup
Yea, but I can't remember if the book c overs _everything_
-
sjk
is VNET recommended nowadays?
-
sjk
ah, Lucas' got a section on vnet :)
-
debdrup
There's no reason not to use vnet.
-
spork_css
Highly recommend the book, especially paired with the two zfs books.
-
sjk
spork_css: yeah, I read the zfs ones and just started reading the jail book
-
debdrup
I think mwl stated that in order to write the jails book, he needed to write all the other freebsd mastery books.
-
pertho
what's everyone's fave jail manager? doing it by hand? iocage? bastille? ezjail?
-
pertho
I quite like the bastille thin jails
-
laidback_01
yeah, I use bastille. used ezjail, iocage, and bastille, and I swear something else, but I can't recall. Only done it the by-hand way a couple times. Been wanting to try out CBSD, but so far, the opportunity hasn't presented itself. Bastille is the most useful to me at this point.
-
pertho
yeah I used bastille for a juniper pulse connect vpn that takes over the default route.. got it set up for a VNET jail.. works a treat
-
pertho
and doesn't muck with the routing table of the host system
-
mason
Just occurred to me today, if I can't get Azerothcore or Trinitycore to compile on FreeBSD, maybe I can build out a Debian jail per a somewhat recent BSD Now.
-
meena
-
VimDiesel
Title: Howto: Setting up Jails
-
mason
That sounds cool as well.
-
pertho
mason: WoW :D
-
mason
pertho: Yar. It ought to compile on FreeBSD but honestly the errors the code generates are a bit opaque to me. I'm not a C++ fan any more and I get easily confused. :P
-
mason
-
VimDiesel
Title: Dennis Ritchie - Write in C - YouTube
-
pertho
mason: I tried to fix the devel/adb port in OpenBSD but it's a C++ mess and I got lost trying to look at what to fix.. I think FreeBSD's port is newer but I couldn't translate it over.. so gave up
-
pertho
I think adb changed all its namespaces.. noticed in FreeBSD it's devel/android-tools-adb
-
rtprio
i need to move some bhyve things to jails
-
mason
Surprised it's not Java.
-
mason
Yeah, heavyweight -> lightweight is a win.
-
pertho
Java... *shiver*
-
mason
I'm trying to ditch all my VMs.
-
cracauer
Can't find that port in head ports.
-
cracauer
Oh it's inside androidd-tools.
-
pertho
freebsd bhyve VMs... under.. freebsd?
-
pertho
mason: so is azerothcore a way to host your own WoW server?
-
meena
why use big resources when little resources do trick.
-
mason
pertho: Yes. Specializes in WotLK.
-
mason
So, client 3.3.5a
-
rtprio
at the time i had more linux hosts
-
polyex
i'm trying to set up a new external flash drive for fbsd so i start with 'dd if=/dev/zero of=/dev/da0 bs=1M' and it starts but then soon after says "dd: /dev/da0: Input/output error". what's that mean?
-
vkarlsen
Maybe it's busted. But why do you zero it with dd?
-
polyex
just to wipe anything that's currently on it
-
polyex
it's a brand new drive but i guess it could be a DoA?
-
polyex
anything else i could try?
-
vkarlsen
Why not just create a filesystem on the thing?
-
polyex
well i gotta run gpart create -s GPT da0 first no? it's currently MBR/ntfs
-
V_PauAmma_V
You didn't specify a limit, so it keeps trying until you get to the end of the source. /dev/zero doesn't *have* an end.
-
V_PauAmma_V
s/trying/copying/
-
rtprio
but it shouldn't input output error
-
rtprio
polyex: zpool create elements /dev/da0; zpool initialize elements;
-
V_PauAmma_V
Why not? It tried writing past the end of the target.
-
rtprio
V_PauAmma_V: ok, perhaps. if he was very patient
-
polyex
wait so what did i do wrong?
-
polyex
i used that dd line in the past and it worked
-
V_PauAmma_V
Without count= ?
-
polyex
ya i'm pretty sure
-
rtprio
polyex: you didn't do anything wrong; it did the trick and blasted the front part of the disk. now make a filesystem
-
polyex
so the input/output error can be ignored?
-
V_PauAmma_V
Hold on. Let me try on one I know works and can be recovered.
-
polyex
tyvm
-
polyex
just tried to run gpart create -s GPT da0 and it said geom da0 file exists
-
polyex
i think i need the dd to work first before i can run that
-
rtprio
or you could use commands to remove the old paritions
-
polyex
well i just tried gpart destroy -F /dev/da0 and it said input/output error but i guess it worked? gpart show shows a raw disk now
-
V_PauAmma_V
Now *that* is worrying.
-
V_PauAmma_V
(At 7 MB/S, 32GB is gonna take a while.)
-
polyex
just did newfs /dev/da0p1 it said newfs: wtfs: 512 bytes at sector 454354353: input/output error
-
V_PauAmma_V
Sounds like you got a dud. Or one that's lying about its size, as I'm told happens.
-
polyex
hmmm i'll try another. i ordered 2
-
rtprio
... yeah; a fried of mine got a 1tb usb stick for $30; it was more like 32gb with some sector magic
-
epony
might have had an mp3 player embedded in there too ;-)
-
polyex
this is a samsung t7 shouldn't that be good? or does conterfeit junk get dumped onto amazon?
-
debdrup
SSDs shouldn't get zeroed like that.
-
polyex
they shouldn't?
-
polyex
why not?
-
debdrup
No. Short answer: They have a limited number of times they can be written to.
-
debdrup
There are other reasons that can depend on the firmware, but that's the most important on.
-
polyex
but it's just once to clear it, so that's only 1 write no?
-
debdrup
What was on the disk before, and what are you going to be using it for?
-
polyex
new drive
-
polyex
gonna use it for freebsd-ufs fs
-
polyex
just to put files on and stuff
-
debdrup
Oh, so you're doing a burn-in?
-
polyex
well whenever i get a new flash mem stick or drive i like to zero it then put gpt and fbsd-ufs on it
-
polyex
this workflow worked on flash mem sticks before, this samsun t7 is my first external
-
debdrup
Do you have any errors from CAM in the system log?
-
polyex
would that be in dmesg or?
-
debdrup
It'll be in /var/log/messages
-
polyex
grep for CAM or?
-
polyex
ya lots...
-
polyex
cam status: ccb request completed with an error
-
debdrup
tail -n 500 /var/log/messages | nc termbin.com 9999
-
polyex
tons of those
-
debdrup
Yeah, that's probably a DOA drive.
-
debdrup
File an RMA with the seller or the manufacturer, depending on juristriction.
-
polyex
is my command list termbin.com/xgmo7 right for future reference? it's to take a new flash stick or ssd, wipe it, and put generic gpt/freebsd-ufs on it
-
debdrup
Termbin is just a pastebin that's accessible by sending the data to it via netcat.
-
polyex
no i know that. go to that url
-
debdrup
I don't see anything obviously wrong with that.
-
polyex
ty!
-
debdrup
I'd recommend using 2M for the blocksize because it's a factor of 4 but isn't evenly divisible with 4.
-
polyex
2MB up to 1TB capacity, then 4MB for >1TB capacity?
-
debdrup
Nope, 2MB for basically anything that doesn't _require_ a certain number of bits.
-
polyex
number of bits = block size in this context?
-
debdrup
Some 520B sector disks will complain if you try to write anything but 520 bytes to them, but those are rare (and can usually be formatted to use 512B with sg_format).
-
debdrup
No, blocksize means the kernel will send requests of that size to the disk, and it's up to the disk cache+firmware to decide how it gets written. 2MB happens to be a medium value between the native sector size of the drive and whatever the size of the cache is, as they usually top out at ~256MB.
-
polyex
where does "number of bits" come from then?
-
debdrup
Too small and it'll take forever to write, too big and can cause issues with the disks firmware and cache filling up too quickly.
-
debdrup
What do you mean number of bits?
-
polyex
"Nope, 2MB for basically anything that doesn't _require_ a certain number of bits."
-
polyex
basically i wanna know how i can know when something requires a certain number of bits, to know when to use a different block size than 2MB
-
debdrup
Oh, I explained that already, but you didn't catch it I suppose - see the thing about 520B.
-
polyex
ah
-
debdrup
Do you use enterprise SAS drives meant for enclosures made by the same manufacturer? (Ie. EMC drives for EMC enclosures in the past, nowadays Dell drives for Dell enclosures)?
-
debdrup
If not, then you don't need to worry about it.
-
polyex
ok so 2MB blocks on all external drives no matter the size or type (except the weird 520 byte stuff) got it ty
-
polyex
ahh
-
debdrup
2MB blocksize for all drives.
-
polyex
k i'll try that
-
debdrup
..unless they're special enterprise drives.
-
polyex
btw the 2 new samsung t7s don't show up for gpart show now
-
polyex
even when i change the usb port or whatever
-
debdrup
Yeah, they're dead. :D
-
polyex
wtf
-
debdrup
That's why doing a burn-in test is good (though dd isn't the best tool, you ideally want something that can read and verify what it's written).
-
V_PauAmma_V
By "not evenly divisible by 4", do you mean "not a power of 4"?
-
debdrup
V_PauAmma_V: that's entirely possible. :3
-
V_PauAmma_V
</math major>
-
» debdrup is not good at maths.
-
debdrup
For a good burn-in test, creating a temporary pool directly on the drive then doing zpool-initialize is pretty much the best way I've found.
-
cracauer
My cstream dd-like tool has reproducible random generated output. So you can first write it to disk and then `cstream -i- | diff /dev/da0 -`
-
cracauer
Verifying that all bytes are the same.
-
debdrup
Shouldn't that be procedurally generated instead of reproducibly random?
-
cracauer
Err, yes. It just uses random with a constant init.
-
cracauer
And it's ascii.
-
V_PauAmma_V
I'm good at math that makes sense to me. When I was in 3rd-grade-equivalent, I had trouble with long division because I couldn't understand what that apparently pointless procedure had to do with figuring out how many of my 37 slices of pizza each of 17 people would get, with how many left over. It lasted until someone explained not how, but *why* it worked.
-
V_PauAmma_V
</tangent>
-
polyex
k i just plugged both drives into a mac and they both showed up just fine. reformatted them both just fine
-
cracauer
What was the geom commandline to display the mapping between /dev/label entries and the original /dev/ entry?
-
polyex
gonna try rebooting or smth i guess
-
debdrup
cracauer: geom -t
-
cracauer
thank you.
-
debdrup
No worries.
-
cracauer
I have to say that I find the Linux way of using symlinks to be very convenient for the labels.
-
cracauer
I guess it costs some indirections through the filesystem on access, though.
-
polyex
the drive shows up in gpart show after a reboot. running dd now with 2M bs. it's running however there were some CAM errors dumped into /var/log/messages
-
debdrup
polyex: if you get _any_ CAM errors on a brand new drive, it's almost never a good idea to try and use it. Just RMA it.
-
polyex
oh really?
-
debdrup
Especially if you're using a filesystem without checksums.
-
polyex
i wonder if samsung is putting their defective stuff on amazon
-
debdrup
UFS on FreeBSD is at least better off than other Unix-likes, because FreeBSDs lack of block devices mean that the filesystem can correlate I/O errors to filesystem operations, but even with checksums like in ZFS you're still not gonna enjoy using a defective drive.
-
debdrup
polyex: even if they were, it's pointless to speculate on it. All production lines, no matter how good, have a failure rate - otherwise, production lines can't be profitable.
-
polyex
after dd finishes i'll run it again on same drive but from a motherboard usb port instead of pc case usb port. unlikely but maybe the pc case usb port is defective?
-
polyex
oh
-
debdrup
Even if Samsung is one of the more reputable manufacturers with certain of their product lines, they still have errors sometimes.
-
polyex
well i got 3 of these drives so i'll try all of them. if they all generate CAM errors i'll be really suspicious
-
polyex
might even become angry
-
debdrup
I'm not familiar with that particular line of their product, but own several Samsunug SSDs in other products.
-
debdrup
As for external disks, what I do is use one of these:
akasa.co.uk/update.php?tpl=product/…oduct.detail.tpl&model=AK-ENU3M2-05 combined with an M.2 drive.
-
VimDiesel
Title: Portable M.2 SATA / NVMe SSD to USB 3.2 Gen 2 Aluminium Enclosure | Akasa Thermal Solution
-
meena
we had logic in traffic server for figuring out the native block size of drives, when using it in raw mode
-
meena
I wonder if that's still in
-
cracauer
Nice enclosure.
-
debdrup
They're fantastic.
-
nomia
can u use regular nvme or only sata?
-
debdrup
That's the advantage of it, you can do both.
-
nomia
(: sweet
-
debdrup
And switching between them is entirely toolless (though a little fiddly)
-
cracauer
What kind of throughput are you getting with those?
-
debdrup
I don't have any USB 3.N Gen2 ports, so haven't been able to test, but Anandtech tested a previous version:
anandtech.com/show/16954/akasa-m2-s…ng-spare-drives-a-new-lease-of-life - though I will say that to reach the highest speeds promised, you'll probably need to cool both the SSD and the controller chip on the drive.
-
VimDiesel
Title: Akasa M.2 SSD Enclosures Reviewed: Giving Spare Drives a New Lease of Life
-
debdrup
I'd say the main advantage of them, though, is to be able to get a reputable M.2 drive from a manufacturer you're comfortable with, instead of some NoName branded flash that's almost assuredly bought because it was discarded by someone else.
-
debdrup
I do recall seeing over 1GBps though, so that's ~fast enough for me~
-
debdrup
Wait, over 500MBps.
-
V_PauAmma_V
Well, I was wrong about dd reporting end of of as an IO error. "dd: /dev/da0: end of device"
-
polyex
k the dd finished, but it says the primary gpt table is corrupt or invalid
-
polyex
debdrup btw if i use 2M for dd bs, should i also use 2M for gpart add -l DISK -t freebsd-ufs -a 1M da0?
-
polyex
or are they 2 different unrelated things i think?
-
cracauer
Might be critical.
-
polyex
k rerunning the dd command on same drive but connected to motherboard usb port. tailing /var/log/messages for CAM errors
-
polyex
in the meantime i'm checking out that akasa enclosure. looking niiiice debdrup
-
cracauer
Costs a pretty penny, though.
-
cracauer
Cheapest I can find in the US is $81 on Amazon.
-
polyex
dd still running but NO CAM errors yet
-
polyex
anyone ever see CAM errors when drive is connected to PC case usb port but not motherboard usb port?
-
polyex
still no CAM errors
-
polyex
gotta be almost done
-
polyex
ok dd finished and not 1 CAM error when drive is plugged into mobo
-
polyex
case usb port must have something wonky
-
cracauer
USB cabling has always been a weak point.
-
polyex
hmm but drive not showing up in gpart show wtf
-
polyex
ah there it is
-
polyex
after i gpart create -s GPT da0 it's there
-
cracauer
This stupid Dell laptop refuses to turn on after I put in a better wifi card :-/
-
phryk
I assume there's some device file I can read to get raw PCM audio from mic or other audio channels. Anyone happen to know which one i'm looking for?