00:50:45 be-back 00:52:11 i just install FreeBSD 13.2 on virt-manager with bios. i would like how activate framebuffer dkms or kms for have full screen and litle font view on my VM. thank 05:54:33 though I have found nothing documented- theres gonna be a way too boot an encrypted zfs root, right? 05:55:38 load the kernel from EFI or other unencrypted 'boot'partition perhaps? 05:56:52 why are we stuck with this ancient zfs efi driver based on grub from like 2004? 05:58:40 huh? 05:58:49 theres no one in the whole world who can build EFI drivers from a recent openzfs codebase? 05:59:12 im so confused 05:59:42 you can currently boot from a partition encrypted using GELI, but not one using zfs native encryption 06:00:34 * derzahl would like to add fbsd 14 to an existing ZFSonROOT linux laptop 06:00:38 loader[.efi] already has code from the same openzfs version as the kernel 06:01:22 (but not the support for encryption) 06:01:56 hm, so then loader.efi should be able to boot the kernel and decrypt the root zpool or dataser? 06:02:01 somehow? 06:02:07 ah 06:02:12 not if the kernel is on the encrypted pool 06:02:42 can the kernel be put on the uefi partition? 06:03:12 in theory, yes (though you'd have to put the zfs module there too, plus any other modules that need loading before boot) 06:04:03 i thought there should be a way 06:04:08 it's not something the installer will do for you, but it's a setup I've experimented with in the past 06:04:12 but nothing documented? 06:04:27 i am not at all familiar with the fbsd boot process 06:05:47 I can't actually recall what I did 06:06:59 oh nice. i went with "shell" at the installer and created a zpool/BSD dataset that is encrypted and installed to that, plus a have an unencrypted ZFS boot partition with all the features off for grub to work 06:07:14 the boot process on EFI is straightforward: loader.efi is responsible for finding /boot/ (to get loader.conf, the kernel, etc.), processing loader.conf, and running the kernel 06:07:25 but im not sure how to get it to boot 06:07:38 encrypted how? 06:07:48 native zfs 06:10:23 freebsd doesnt use an initrd ,right? 06:10:49 and im guessing theres no way to build something like a linux UKI? 06:12:23 loader.efi supports doing a whole lot of things 06:13:05 I'm pretty sure I got it to boot from an image file on the ESP, but I don't have the details handy 06:13:19 where can i find a copy of the loader.efi dark magik book? 06:13:33 hm 06:14:33 image file? like an mfsroot? 06:16:45 let me see if I still have it kicking around somewhere 06:21:45 seems not 06:23:09 so loader has the concept of a vdisk, which can be any file that it can access via any of the filesystems it can read 06:23:29 and which is treated as a device in itself 06:23:41 so that can be a file on the ESP for example 06:24:38 what I was aiming for when I looked at this was to see whether it was possible to make a "rescue" filesystem on the ESP 06:48:53 hm. interesting. ill look. any links you may have woudl be helpful 07:09:22 Happy Canada Day! 07:12:06 happy birthday, leibniz 12:36:41 hi, is possible to disable ASLR for only one binary or jail? I would like to make this working: cc -fsanitize=address ... 12:41:03 pvalenta: try 'proccontrol -m aslr -s disable your-command' 12:42:31 yuripv, great, thanks! 13:22:22 pvalenta, yuripv: see also, https://man.freebsd.org/elfctl(1) 13:22:23 Title: elfctl(1) 13:25:21 maybe those two man pages need to crosslink to each other 13:34:20 the interesting is: binary compiled by cc -fsanitize=addres works but clang -fsanitize=addres does not. cc is from base, clang from ports. Clang compiler from base has probably some tweaks 13:34:57 meena, another useful tool, thanks 15:23:50 pvalenta: for probably quite sensible reasons none of which i remember, the sanitise framework is not in base 17:43:49 i am trying efibootmgr -a -c -l pathtoloader.efi -L Freebsd in chroot but it says efi variables not supported on this system. root? kldload efirt? kldload: cant load efirt: module already loaded or in kernel. 17:44:09 if already loaded why i cant add bootentry then? 17:49:00 tyler82 if you run kenv | grep efi-version what it does tell? 17:49:44 tsoome: 2.31 17:51:43 so, it may not provide the variables... you can try another thing, what does efivar command show? 17:52:19 https://pasteboard.co/PHy36TrVzHbQ.jpg 17:52:20 Title: Pasteboard - Uploaded Image 17:52:47 tsoome: efivar: no such file or directory 17:54:17 or efi-show from loader OK prompt. but it seems, there are no variables... have you checked for firmware update for this machine? 17:55:13 tsoome: yes. it was okay before i deleted the boot entry in BIOS 17:55:51 so it can be some sort of firmware bug. 17:56:00 can you re-add it from frmware? 17:56:43 i dont know how to add it? it is a chrooted system 18:00:10 do i have to bind mount sys or something?? 18:10:31 tsoome: its work now. efivar command now listing the files. i just needed mount -t devfs none /dev in chroot. 18:12:13 but efibootmgr still does not work 18:13:04 https://pasteboard.co/i0DePZs12fw7.jpg 18:13:05 Title: Pasteboard - Uploaded Image 18:23:05 meena, i have tried dereference pointer after free and error is reported so i thing sanitizer is in base: ==7049==ERROR: AddressSanitizer: heap-use-after-free on address 0x602000000070 ... 18:58:43 https://pasteboard.co/4Z4HXMYoSPV1.jpg operation not permitted. boot partition is mounted before chroot. 18:58:45 Title: Pasteboard - Uploaded Image 19:15:43 pvalenta: weird 19:16:45 tyler82: can you put that gpart call under (d)truss? 19:17:52 meena: wdym? 19:33:16 tyler82: I'm wondering why the operation failed with permission denied, and naïvely hoping (d)truss will be able to tell 19:43:47 devel/ccache-memcached just got removed. What should I replace it with? 19:47:05 Schamschula: something that has upstream support? 19:48:21 For sure! I'm just not to familiar with these packages. Just using them as part of the Poudriere infrastructure. 19:51:02 I see devel/ccache4, it conflicts with my currently installed tools but it's unclear if it works the same way. 19:51:22 Schamschula: i didn't realise that poudriere references it directly 19:51:58 let me hit up the committer who removed it, and ask them to fix up poudriere.conf, too 19:54:08 (done) 19:56:18 Schamschula: i reckon you can probably replace it with any other ccache, but don't quote me on that, because I'm not using any 19:57:09 I'll give ccache4 a try 20:09:29 Any recs on a VPS provider for very small stuff? I really like Vultr, but I want to put some eggs in other baskets. DO dropped official FreeBSD support, so not them. 20:09:56 No interest in AWS or Google. Also tried Ramnode, and... meh. 20:09:57 ovh maybe? 20:10:09 oracle cloud has arm64 free tier 20:10:25 hmmm... that's interesting. 20:10:56 I tried Google's "free" tier but somehow have ended up at $9/month. Too AWS-like anyhow. 20:10:58 i run there a 13.2-RELEASE vm 20:11:29 can't wait until we run on Hetzner's arm64 cloud. it's about half the price of their amd64 stuff 20:11:53 (and also poudriere jobs) 20:12:18 meena: hetzner left bitter taste in my mouth since they dropped freebsd support 20:12:27 although i run tens of freebsd servers there 20:13:32 otis: still hoping my project more projects to readopt FreeBSD 20:16:33 Hetzner dropped FreeBSD support? That one was on my shortlist. *removes* 20:17:31 V_PauAmma_V: for the servers. the cloud stuff still allows installing it, but it takes two steps 20:18:24 Thanks. 20:20:31 and lots of people are able to bootstrap FreeBSD on the servers, too. with mfBSD and depenguinator and stuff like that, but it sucks that we need to do extra work 20:20:42 meena: i think it is geom issue... 20:22:37 mfsBSD is awesome though 20:24:36 If Hztzner "supports" FreeBSD by making customers jump through the depenguinator hoop, there's no advantage for me in moving from Linode. 20:24:54 s/Hz/He/ 20:30:43 at least on cloud thing they give you the ISOs to mount and install stuff, but yeah, that still stinks 20:31:14 hoping by the next cloud-init release to support enough to bug them into readopting it 20:33:32 *nod* 20:34:24 on servers you can install it using mfsbsd or a usb flash drive 20:34:32 but no longer directly using installimage 20:34:48 anyway, their price-performance for bare-metal is unbeatable. 21:03:02 spork_css: you can get some free vms that run freebsd on oracle cloud 21:37:29 right. i really need to put that in as standard test 21:38:02 I created an AWS account, but the standard images don't boot on the free Tier 21:38:14 (yet, fix is already committed) 21:38:42 https://freshbsd.org/freebsd/src/commit/bcf9147144f3499976a623f92712ecd0aca71912 21:38:43 Title: FreeBSD / src / bcf9147 / EC2: Default to "uefi-preferred" boot mode - FreshBSD 21:43:44 how can i boot into the system if i have no boot entry in BIOS? i was failed to add new boot entry with efibootmgr. i have 12 partitions on my ssd only one partition is zfs. the boot partition is fat but if i write the bootcode on it i will be unable to mount it and therefore unable to create a new boot entry with efibootmgr. 21:43:45 and https://freshbsd.org/freebsd/src/commit/1178acf46604c54e2661284af17452c4db6b2f6f 21:43:46 Title: FreeBSD / src / 1178acf / EC2: Default to "uefi-preferred" boot mode - FreshBSD 21:44:36 tyler82: do you mean the efi partition is fat? 21:45:19 meena: yep. i was created with newfs_msdos /dev/ada0p12 21:46:33 the system is zfs 21:46:57 on /dev/ada0p10 21:48:40 i am able to accesd it via other freebsd installation on external ssd and chroot into it. my aim is to create a boot entry and make it bootable again. 22:13:26 why does it need to be in chroot? 22:14:51 tyler82: you boot a life system, and tell that life system's efibootmanager to do its thing 22:17:22 meena: u mean live system? shell? 22:29:27 live System, yes, from Stick, or CD-ROM 22:32:25 meena: yes. i am on it but where to mount boot partition? under /rescue/boot ? 22:32:39 read-only filesystem 22:35:07 shouldn't really matter where you mount it to, if the tools can be convinced to write anywhere other than /boot 22:35:33 usually /mnt is what we use for temporary mounting 22:36:52 meena: yeah. but giving read-only filesystem error. i can mount it only under /tmp 22:39:38 but the zfs pool how shall i mount it? mount -t zfs does not work. shall i zpool import -f -d /dev ada0p10 ? 22:45:37 gpart bootcode -p operation not permitted 22:50:02 you'd Import it, put a temporary mount point to a different location 22:52:35 you shouldn't use gpart bootcode -p on EFI systems 22:53:36 see, if my brain was working i should have said this hours ago 22:54:48 RhodiumToad: You can if you set up both in parallel. I do that most of the time. 22:55:31 if you want both legacy boot and EFI, yes. but not for EFI only 22:55:39 and not if you want EFI boot management 22:56:11 hi, i think i talked about this before but decided now i actually do want to ask about it 22:56:44 anope silently segfaults for me on 13.1-RELEASE 22:57:11 as far as i can tell it's after linking to inspircd, and it gives absolutely no indication of error 22:57:20 would appreciate some direction about how to troubleshoot 22:57:27 is there a core dump? 22:57:34 let me see 22:58:09 (the message in /var/log/messages will say "killed by signal 11 (core dumped)" if so) 23:00:16 apparently not 23:00:38 there's a message that just says "... killed by signal 11" ? 23:00:40 pid 99493 (services), jid 0, uid 65534: exited on signal 11 23:00:41 if there's no corefile, it's time to *checks https://man.freebsd.org/core(5) * `sysctl kern.corefile` 23:00:42 Title: core(5) 23:01:09 there are three main reasons why a core dump might not be created: 23:02:06 1) the process is running with the corefile limit set to 0, 2) the process is setuid or has changed its uid or gid, and 3) the process's current dir is not writable by it 23:02:45 I got all three right! my brain is still good enough 23:02:49 65534 is uid "nobody". was the program started under that user or did it switch to it itself? 23:03:00 it was started as a service 23:03:26 that doesn't answer the question, but makes it easy to verify 23:03:28 ok, then what does the service startup script look like? 23:05:30 sorry, let me find where that is 23:05:52 (running programs as "nobody" is actually a bad idea. nonprivileged services should be assigned their own unique uids.) 23:06:09 ah i got it 23:06:34 the user is indeed set to nobody 23:06:38 how? 23:07:01 I'll just pastebin the full script, one sec 23:07:13 is this anope installed from ports, or manually? 23:07:17 pkg 23:07:22 https://0x0.st/H1oP.sh 23:07:52 it's from the actual repos, not ports 23:08:04 ports, pkg, same thing 23:08:11 alright, sorry 23:08:20 the pkg repos are just the results of building the ports tree 23:09:13 ok. so it's letting rc.subr change the user for it, which shouldn't prevent a core dump. 23:09:20 kern.sugid_coredump looks like what i want 23:09:25 is it? 23:09:32 so the most likely thing is it running in a directory it can't write to 23:10:33 yeah, setting ${name}_user (anope_user in this case) causes rc.subr to use either su or chroot to set the user before running the program 23:11:13 you can set sysctl kern.corefile=/var/tmp/%N.core or something of the sort to put the core file there 23:13:29 it...doesn't appear to do that still. hmmm 23:14:59 there we go! 23:15:56 thank you for help, let's see if i can figure out what the issue is now 23:22:38 Ok, so the bt shows #0 0x00000000002db839 in ChannelInfo::WhoSends() const () as the function where SIGSEGV was received 23:22:59 #1 0x000000080135d86b in ChanServCore::OnCheckModes(Reference&) () from lib/modules/chanserv.so, and probably the rest is not that interesting 23:23:16 what are the registers and the failing instruction? 23:25:50 I'll pastebin those. Register content: https://bpa.st/JCCQK . I've never used layout asm before so I'll paste all of what I see and hope it started on the failing instruction, sorry. I think it's the top? https://bpa.st/KD2RK 23:25:51 Title: View paste JCCQK 23:27:24 ok, so this is a straightforward null pointer dereference 23:29:10 oh that 0x258(%rdi) is indirect addressing, right 23:29:17 and rdi contains 0 23:29:21 hrm ok 23:29:54 i guess I could try to build this with debug symbols and have a look how that gets there? 23:31:22 which debugger are you using? 23:31:40 i used gdb to get to this point 23:32:01 what's the output of disass ChannelInfo::WhoSends() 23:34:16 huh my bt is empty now 23:34:17 RhodiumToad: so what shall i use then? -p /boot/gptzfsboot -i 12 ada0 ? 23:34:22 let me figure that out... 23:34:42 tyler82: on an EFI system you should not be using gpart bootcode -p AT ALL 23:35:28 yeah, I'm not sure what happened because my entire bt is gone despite loading the core and the program the same way 23:35:53 exactly the same way? what did you do? 23:36:04 exited, changed directory 23:36:08 nothing else 23:36:14 using absolute paths on both 23:39:03 i'll paste the disassembly for where I currently am, anyway 23:39:42 https://bpa.st/2BD6A 23:39:43 Title: View paste 2BD6A 23:40:04 RhodiumToad: thats interesting. i was reading the man page and also searching on forum and found this. https://forums.freebsd.org/threads/update-of-the-bootcodes-for-a-gpt-scheme.80163/ The first post says. -p /boot/gptzfsboot. So what shall i use for GPT UEFI then?? 23:40:06 Title: Update of the bootcodes for a GPT scheme | The FreeBSD Forums 23:40:24 this appears to be the function you wanted, just can't see the bt anymore for reasons I don't really understand 23:40:42 oh, interesting, the directory matters 23:41:16 tyler82: the ESP is just an msdos filesystem. you don't use anything. 23:42:00 tyler82: all that matters is that there's a copy of loader.efi on the ESP and the EFI boot manager (or the EFI firmware) knows where to find it. 23:42:40 mewt: so, that looks like "this" in the function is NULL 23:43:04 mewt: (the source code is checking for that, but the compiler probably optimized that out since this isn't allowed to be null afaik) 23:43:21 RhodiumToad: i see. but i am hsving with this issue. https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=229191#c2 23:43:23 huh alright 23:43:23 Title: 229191 – efibootmgr(8) fails to create boot var when ESP is mounted using a gpt label 23:43:43 cannot translate unix loader path 23:45:09 tyler82: what exact command did you run 23:45:57 so what is the correct way to write the bootcode then? -b will do MBR. But i have GPT UEFI 23:46:51 tyler82: You don't write it per se. You copy an .efi file into the right location. 23:47:24 mewt: so looking at ChanServCore::OnCheckModes, it's doing this: 23:47:53 tyler82: maybe cp /boot/loader.efi /boot/efi/efi/boot/bootx64.efi 23:47:57 mewt: if (c->ci) ... else c->SetModes(c->ci->WhoSends(), ... 23:47:59 tyler82: https://wiki.freebsd.org/UEFI might help explain what's going on 23:48:00 Title: UEFI - FreeBSD Wiki 23:48:24 mewt: so it's explicitly calling WhoSends on a null pointer, which I don't believe is legal C++ 23:48:41 exciting! 23:49:11 mason: fuck. i see. but why everywhere mentioned this gpart bootcode -p then?? 23:49:16 mewt: the code seems to be assuming that it just works and ends up in the method with "this" NULL, but the compiler seems to be eliding that tests 23:49:27 mquin: ok. thx. 23:49:42 gpart bootcode -p is for GPT with legacy boot 23:49:51 maintainer is not in here, I guess I can try and fix it and get a patch to submit? 23:50:09 patches are welcome everywhere :) 23:50:35 hehehehe 23:50:35 "egypcio", apparently 23:58:07 mewt: which version of anope are you using? 23:59:09 Anope-2.0.12 -- build #1, compiled 00:10:09 Apr 21 2023