Re: send help ( chroot php fpm refuse to exec/popen/procopen... on 7.0 )
On Tue, Oct 26, 2021 at 11:13 AM Stuart Henderson wrote: > On 2021-10-26, Sven F. wrote: > > exec ('/usr/sbin/ksh -c "echo a"', $output, $retval); > > echo ''; > > echo "Returned with status $retval and output:\n"; > .. > > Returned with status 127 and output: > .. > > You need /bin/sh in the chroot for this to work. > > "The exit status of the shell is 127 if the command file specified on > the command line could not be opened" > > I've just added some more text to php's pkg-readme files about this > > Thanks all, Am i supposed to put femail here ? ; For Unix only. You may supply arguments as well (default: "sendmail -t -i"). ; http://php.net/sendmail-path sendmail_path = /bin/femail -t -i # cat /usr/local/share/doc/pkg-readmes/femail-chroot $OpenBSD: README-chroot,v 1.3 2018/09/04 12:46:15 espie Exp $ Yes, now i see it :-/ +--- | Running femail-chroot on OpenBSD +--- [..] If you're using femail with PHP inside a chroot jail, be aware that PHP's built-in "mail" function uses popen(), which requires /bin/sh Y'all great. -- -- - Knowing is not enough; we must apply. Willing is not enough; we must do
Re: What’s new in OpenNSD 7.0 NYC*Bug meeting
> On Oct 26, 2021, at 13:49, harrywea...@tutanota.com wrote: > > > > 26 Oct 2021, 18:19 by cho...@jtan.com: > >> harrywea...@tutanota.com writes: >>> A few among the myriad: >>> https://www.tomsguide.com/news/zoom-security-privacy-woes >>> https://jonathanhays.me/2020/04/04/zoom-insecurity/ >>> https://www.reddit.com/r/technology/comments/ftkb69/zooms_security_and_privacy_problems_are/ >>> But, perhaps you're comfortable with that. >>> We're all different.Cheers! >> Internet service provider doesn't know how to internet. News at 11. >> They're not insecure (except by accident), they're incompetent. >> Just like everyone else. Also the company seems to be more ham-fisted >> in its approach to public relations than Zuckerbook. >> If your response to incompetence on the internet is to flee somewhere >> with competence* and thus ignore its hidden mistakes, then may I >> interest you in this fine bridge? >> Use whatever it is to your heart's content. Adverts are unhelpful. >> The question was "do you want to join our zoom conference" not "what >> should we use for internet conferencing". > If you're using zoom, no I'm not, thank you. > As I said, whatever floats your boat. > I'll stick to open source. > `Incompetencies' are discovered and amended, not hidden. > That's it for me. > Nothing productive, I can see, in this conversation.Cheers! > > Harry. While I am far from zoom proponent, it is an often used tool for such video *bug meetings. In fact thfr@ have a fantastic talk: Gaming on OpenBSD: Pearls, Pitfalls, Paranoia, NYC*BUG: 03/03/2021 I am comforted to notice Jitsi was spared completely in the discussion above. We have used Jitsi in previous meeting and I found it an easy solution. I will look into the Jami solution for future meetings. Thank you for the suggestion Harry. To get back to the question at hand, is there anyone here who would be interested in giving a “What’s new in OpenBSD 7.0” talk? Perhaps there is a better mailing list to make my request? Link for thfr@ talk page. https://www.nycbug.org/index?action=view=10681
Re: Re: Re: What’s new in OpenNSD 7.0 NYC*Bug meeting
26 Oct 2021, 18:19 by cho...@jtan.com: > harrywea...@tutanota.com writes: > >> >> >> A few among the myriad: >> >> https://www.tomsguide.com/news/zoom-security-privacy-woes >> >> https://jonathanhays.me/2020/04/04/zoom-insecurity/ >> >> https://www.reddit.com/r/technology/comments/ftkb69/zooms_security_and_privacy_problems_are/ >> >> But, perhaps you're comfortable with that. >> We're all different.Cheers! >> > > Internet service provider doesn't know how to internet. News at 11. > > They're not insecure (except by accident), they're incompetent. > Just like everyone else. Also the company seems to be more ham-fisted > in its approach to public relations than Zuckerbook. > > If your response to incompetence on the internet is to flee somewhere > with competence* and thus ignore its hidden mistakes, then may I > interest you in this fine bridge? > > Use whatever it is to your heart's content. Adverts are unhelpful. > The question was "do you want to join our zoom conference" not "what > should we use for internet conferencing". > If you're using zoom, no I'm not, thank you. As I said, whatever floats your boat. I'll stick to open source. `Incompetencies' are discovered and amended, not hidden. That's it for me. Nothing productive, I can see, in this conversation.Cheers! Harry.
Re: Using OpenBSD as an L2TP client with A ISP
On 2021-10-26, Maurice McCarthy wrote: > tunnelbroker.net If you want access to part but not all of the v6 internet, that's a possibility. But it doesn't help with getting access to the existing v4 and v6 address ranges (with working geolocation and working with iplayer etc) from an a l2tp connection..
Re: Using OpenBSD as an L2TP client with A ISP
tunnelbroker.net
Re: Samsung SSD X5 with OpenBSD - possible ?
On Mon, Oct 25, 2021 at 07:11:15PM +, Laura Smith wrote: > > ‐‐‐ Original Message ‐‐‐ > > On Monday, October 25th, 2021 at 19:15, Stefan Sperling > wrote: > > > On Mon, Oct 25, 2021 at 05:45:22PM +, Laura Smith wrote: > > > > > I'm struggling a bit as to what I need to do next here. > > > > > > Any time in the past I've connected a USB stick etc. to OpenBSD, > > > everything happened automagically in terms of recognition and assigning a > > > /dev/sd. > > > > > > However this time, its different. This is the only line that appears in > > > dmesg when I plug it in: > > > > > > ugen0 at uhub0 port 4 "SAMSUNG ELECTRONICS CO., LTD Portable SSD X5" rev > > > 2.01/4.45 addr 2 > > > > > > sysctl hw.disknames remains unchanged > > > > > > Any ideas ? > > > > I would guess that no driver is attaching because this drive requires > > > > Thunderbolt 3 rather than USB 3 (both use a USB-C type connector). > > Makes sense, thanks ! Could you send a full dmesg with the device connected, and also try rebooting the machine with it still connected? -Bryan.
Re: Using OpenBSD as an L2TP client with A ISP
* Stuart Henderson [2021-10-26 11:35:06]: > On 2021-10-26, Matt Dainty wrote: > > I'm currently using OpenBSD with an Andrews & Arnold vDSL connection so I > > have > > a pppoe(4) interface, etc. and this works for IPv4 & IPv6. > > > > The problem is because of the rubbish rural Openreach infrastructure here in > > the UK I only get a stable 3.5 Mb/s, however another ISP (Voneus) has been > > installing fibre in the area and can offer a 100+ Mb/s connection, but it > > looks > > like their network is all sorts of CGNAT and they don't seem to offer IPv6 > > addresses. > > > > So I figured I'll just use the A L2TP relay service and use this new fast > > connection to tunnel all of my traffic between the two ISPs and maintain the > > IPv4 & IPv6 addesses that A have assigned to me on my vDSL connection. > > > > Has anyone done this with OpenBSD? I understand xl2tpd is in ports but does > > This (aaisp l2tp) is exactly why I wrote the port for xl2tpd, though in > my case it was only for emergency use while a line was down. > > > everything work through the tunnel, including IPv6? I saw mention about 8-9 > > years ago that the pppd(8) that xl2tpd uses doesn't do IPv6. Is that still > > the > > case? > > Yes that's still the case about pppd(8) and IPv6. Unfortunately pppd(8) > upstream removed most OS support somewhere after the version we > currently have so updating it is decidedly non-trivial (I think there > might have been a few versions between ours, last real update in '98, > and the last one with BSD support, but it's quite far from what > upstream has now). NetBSD looks like it has an IPv6-aware ppp(4) and pppd(8) but I haven't peeked at the source at all, that's just from the man pages, I was still at the stage of figuring out if this was even viable. > AFAIK the only ppp code in OpenBSD that supports IPv6 inside PPP is pppoe(4). I taught pppoe(4) about RFC 4638 which I've relied on since, but that was 9+ years ago so I've lost my familiarity with that code. I'll have a look at the sources and do some research. Cheers Matt
Re: Using OpenBSD as an L2TP client with A ISP
On 2021-10-26, Matt Dainty wrote: > I'm currently using OpenBSD with an Andrews & Arnold vDSL connection so I have > a pppoe(4) interface, etc. and this works for IPv4 & IPv6. > > The problem is because of the rubbish rural Openreach infrastructure here in > the UK I only get a stable 3.5 Mb/s, however another ISP (Voneus) has been > installing fibre in the area and can offer a 100+ Mb/s connection, but it > looks > like their network is all sorts of CGNAT and they don't seem to offer IPv6 > addresses. > > So I figured I'll just use the A L2TP relay service and use this new fast > connection to tunnel all of my traffic between the two ISPs and maintain the > IPv4 & IPv6 addesses that A have assigned to me on my vDSL connection. > > Has anyone done this with OpenBSD? I understand xl2tpd is in ports but does This (aaisp l2tp) is exactly why I wrote the port for xl2tpd, though in my case it was only for emergency use while a line was down. > everything work through the tunnel, including IPv6? I saw mention about 8-9 > years ago that the pppd(8) that xl2tpd uses doesn't do IPv6. Is that still the > case? Yes that's still the case about pppd(8) and IPv6. Unfortunately pppd(8) upstream removed most OS support somewhere after the version we currently have so updating it is decidedly non-trivial (I think there might have been a few versions between ours, last real update in '98, and the last one with BSD support, but it's quite far from what upstream has now). You might think of looking at npppd(8) but it won't help, at least without further work: firstly it doesn't support client-side only server-side, and secondly its v6 support is limited to tunnel endpoints, it doesn't do ipv6 inside ppp. AFAIK the only ppp code in OpenBSD that supports IPv6 inside PPP is pppoe(4). (Pragmatically the easiest/cheapest way to handle l2tp-client is probably via a mikrotik box - setup is pretty straightforward, the main gotcha is you're likely to need the "/ip firewall mangle" equivalent of "scrub max-mss")
Re: send help ( chroot php fpm refuse to exec/popen/procopen... on 7.0 )
Am 26.10.21 09:18 schrieb Sven F.: > }{ello, > > I updated a device and use php fpm on openbsd 7.0 > everything works fine after putting a resolv file in the chroot > but i can't send email from the chroot > > I hope I didn't see something obvious. > > to troubleshoot i drop the ksh inside the chroot > > /var/www/usr/sbin/ksh: > (...) I am not entirely sure what to answer here because I don't know what your question is, but maybe it helps to copy /bin/sh to ${CHROOT}/bin/sh
Re: send help ( chroot php fpm refuse to exec/popen/procopen... on 7.0 )
On 2021-10-26, Sven F. wrote: > exec ('/usr/sbin/ksh -c "echo a"', $output, $retval); > echo ''; > echo "Returned with status $retval and output:\n"; .. > Returned with status 127 and output: .. You need /bin/sh in the chroot for this to work. "The exit status of the shell is 127 if the command file specified on the command line could not be opened" I've just added some more text to php's pkg-readme files about this
Re: send help ( chroot php fpm refuse to exec/popen/procopen... on 7.0 )
> On Oct 26, 2021, at 9:22 AM, Sven F. wrote: > > }{ello, > > I updated a device and use php fpm on openbsd 7.0 > everything works fine after putting a resolv file in the chroot > but i can't send email from the chroot > > I hope I didn't see something obvious. > > to troubleshoot i drop the ksh inside the chroot > > /var/www/usr/sbin/ksh: >StartEnd Type Open Ref GrpRef Name >0e4fc4d74000 0e4fc4e1a000 dlib 10 0 > /var/www/usr/sbin/ksh > > and wrote a stupid php > > $output=null; > $retval=null; > # exec('/usr/sbin/sendmail -h 2>&1', $output, $retval); > exec ('/usr/sbin/ksh -c "echo a"', $output, $retval); > echo ''; > echo "Returned with status $retval and output:\n"; > echo ''; > $rc = sprintf('%o', fileperms('/usr/sbin/sendmail')); > echo $rc; > echo ''; > $rc = sprintf('ffoo: %o', fileperms('/usr/sbin/ffoo')); > echo $rc; > echo ''; > print_r(array('o' => $output,'perm' => $rc, 'r' => $retval)); > > which output : > > Returned with status 127 and output: > 100555 > ffoo: 100644 > Array ( [o] => Array ( ) [perm] => ffoo: 100644 [r] => 127 ) > Does /bin/sh exist in the chroot? It’s needed by exec.
Re: Using OpenBSD as an L2TP client with A ISP
> On Oct 26, 2021, at 9:31 AM, Matt Dainty wrote: > > I'm currently using OpenBSD with an Andrews & Arnold vDSL connection so I > have > a pppoe(4) interface, etc. and this works for IPv4 & IPv6. > > The problem is because of the rubbish rural Openreach infrastructure here in > the UK I only get a stable 3.5 Mb/s, however another ISP (Voneus) has been > installing fibre in the area and can offer a 100+ Mb/s connection, but it > looks > like their network is all sorts of CGNAT and they don't seem to offer IPv6 > addresses. > > So I figured I'll just use the A L2TP relay service and use this new fast > connection to tunnel all of my traffic between the two ISPs and maintain the > IPv4 & IPv6 addesses that A have assigned to me on my vDSL connection. > > Has anyone done this with OpenBSD? I understand xl2tpd is in ports but does > everything work through the tunnel, including IPv6? I saw mention about 8-9 > years ago that the pppd(8) that xl2tpd uses doesn't do IPv6. Is that still the > case? > > Thanks > > Matt > Not the solution you asked about, but getting an IPv6 block from a tunnel broker is free and fast.
Using OpenBSD as an L2TP client with A ISP
I'm currently using OpenBSD with an Andrews & Arnold vDSL connection so I have a pppoe(4) interface, etc. and this works for IPv4 & IPv6. The problem is because of the rubbish rural Openreach infrastructure here in the UK I only get a stable 3.5 Mb/s, however another ISP (Voneus) has been installing fibre in the area and can offer a 100+ Mb/s connection, but it looks like their network is all sorts of CGNAT and they don't seem to offer IPv6 addresses. So I figured I'll just use the A L2TP relay service and use this new fast connection to tunnel all of my traffic between the two ISPs and maintain the IPv4 & IPv6 addesses that A have assigned to me on my vDSL connection. Has anyone done this with OpenBSD? I understand xl2tpd is in ports but does everything work through the tunnel, including IPv6? I saw mention about 8-9 years ago that the pppd(8) that xl2tpd uses doesn't do IPv6. Is that still the case? Thanks Matt
send help ( chroot php fpm refuse to exec/popen/procopen... on 7.0 )
}{ello, I updated a device and use php fpm on openbsd 7.0 everything works fine after putting a resolv file in the chroot but i can't send email from the chroot I hope I didn't see something obvious. to troubleshoot i drop the ksh inside the chroot /var/www/usr/sbin/ksh: StartEnd Type Open Ref GrpRef Name 0e4fc4d74000 0e4fc4e1a000 dlib 10 0 /var/www/usr/sbin/ksh and wrote a stupid php &1', $output, $retval); exec ('/usr/sbin/ksh -c "echo a"', $output, $retval); echo ''; echo "Returned with status $retval and output:\n"; echo ''; $rc = sprintf('%o', fileperms('/usr/sbin/sendmail')); echo $rc; echo ''; $rc = sprintf('ffoo: %o', fileperms('/usr/sbin/ffoo')); echo $rc; echo ''; print_r(array('o' => $output,'perm' => $rc, 'r' => $retval)); which output : Returned with status 127 and output: 100555 ffoo: 100644 Array ( [o] => Array ( ) [perm] => ffoo: 100644 [r] => 127 ) which constantly returns 127 and no output ( also tried popen and other methods , just use exec as a 'simpler' version. Also used the ksh to double check ENV chroot -u user /var/www /usr/sbin/ksh -c 'echo $USER' and tested sendmail inside chroot with the chroot command. After pondering the existence of the universe, i ktrace the php - fpm process ktrace -d -t cpxX -p 32152 and it's not really clear, i cannot see a vfork in there, usr/local got the wxallowed - -- - (( I 80% sur the chrooted sendmail was delivered with a pkg_add )) # uname -a OpenBSD portals2.citypassenger.com 7.0 GENERIC.MP#232 amd64 # pkg_info argon2-20190702 C implementation of Argon2 - password hashing function bzip2-1.0.8p0 block-sorting file compressor, unencumbered curl-7.79.0 transfer files with FTP, HTTP, HTTPS, etc. femail-1.0p1simple SMTP client femail-chroot-1.0p3 simple SMTP client for chrooted web servers gd-2.3.2library for dynamic creation of images gettext-runtime-0.21p1 GNU gettext runtime libraries and programs giflib-5.1.6tools and library routines for working with GIF images intel-firmware-20210608v0 microcode update binaries for Intel CPUs jpeg-2.1.1v0SIMD-accelerated JPEG codec replacement of libjpeg libiconv-1.16p0 character set conversion library libsodium-1.0.18p1 library for network communications and cryptography libwebp-1.2.1 Google WebP image format conversion tool libxml-2.9.12 XML parsing library lz4-1.9.3p0 fast BSD-licensed data compression lzo2-2.10p2 portable speedy lossless data compression library mariadb-client-10.6.4v1 multithreaded SQL database (client) mariadb-server-10.6.4p2v1 multithreaded SQL database (server) nghttp2-1.44.0 library for HTTP/2 nginx-1.20.1p0 robust and small HTTP server and mail proxy server oniguruma-6.9.7.1 regular expressions library p5-Clone-0.45 recursively copy Perl datatypes p5-DBD-MariaDB-1.21p3 MariaDB and MySQL driver for the Perl5 Database Interface p5-DBI-1.643the standard database interface module for Perl p5-FreezeThaw-0.5001p0 module for converting structures to strings and back p5-MLDBM-2.05p0 store multi-level hash structure in single-level tied hash p5-Math-Base-Convert-0.11p0 very fast base to base conversion p5-Module-Runtime-0.016p0 runtime module handling p5-Net-Daemon-0.48p1 extension for portable daemons p5-Params-Util-1.07p2 utility to make parameter checking easier p5-PlRPC-0.2020p0 module for writing rpc servers and clients p5-SQL-Statement-1.414 SQL parsing and processing engine pcre-8.44 perl-compatible regular expression library pcre2-10.36 perl-compatible regular expression library, version 2 php-7.4.24 server-side HTML-embedded scripting language php-bz2-7.4.24 bzip2 compression extensions for php php-curl-7.4.24 curl URL library extensions for php php-gd-7.4.24 image manipulation extensions for php php-mysqli-7.4.24 mysql database access extensions for php png-1.6.37 library for manipulating PNG images quirks-4.53 exceptions to pkg_add rules snappy-1.1.8fast compression/decompression library sshguard-2.4.2 protect against brute force attacks on sshd and others tiff-4.3.0 tools and library routines for working with TIFF images vmm-firmware-1.14.0 firmware binary images for vmm(4) driver xz-5.2.5LZMA compression and decompression tools zstd-1.5.0 zstandard fast real-time compression algorithm # mount /dev/sd0a on / type ffs (local) /dev/sd0g on /home type ffs (local, nodev, nosuid) /dev/sd0d on /tmp type ffs (local, nodev, nosuid) /dev/sd0e on /usr type ffs (local, nodev) /dev/sd0f on /usr/local type ffs (local, nodev, wxallowed) /dev/sd0h on /var type ffs (local, nodev, nosuid) # ls -l /var/www/usr/sbin total 1920 -rw-r--r-- 1 root daemon 0 Oct 26 14:37 ffoo -r-xr-xr-x 1 root daemon 613080 Oct 25 20:42 ksh -r-xr-xr-x 1 root daemon 313176 Oct 23 00:31 sendmail # kdump 20747
Re: Re: Re: What’s new in OpenNSD 7.0 NYC*Bug meeting
harrywea...@tutanota.com writes: > > > A few among the myriad: > > https://www.tomsguide.com/news/zoom-security-privacy-woes > > https://jonathanhays.me/2020/04/04/zoom-insecurity/ > > https://www.reddit.com/r/technology/comments/ftkb69/zooms_security_and_privacy_problems_are/ > > But, perhaps you're comfortable with that. > We're all different.Cheers! Internet service provider doesn't know how to internet. News at 11. They're not insecure (except by accident), they're incompetent. Just like everyone else. Also the company seems to be more ham-fisted in its approach to public relations than Zuckerbook. If your response to incompetence on the internet is to flee somewhere with competence* and thus ignore its hidden mistakes, then may I interest you in this fine bridge? Use whatever it is to your heart's content. Adverts are unhelpful. The question was "do you want to join our zoom conference" not "what should we use for internet conferencing". Matthew [*] I don't know which thing you promoted but whatever it is, its security flaws haven't been found yet. Just like zoom's weren't until the entire world descended upon it en masse.
Re: Re: What’s new in OpenNSD 7.0 NYC*Bug meeting
26 Oct 2021, 17:13 by cho...@jtan.com: > harrywea...@tutanota.com writes: > >> >> >> >> I wouldn't trust Zoom any further than I'd trust Skype. >> Cheers! >> > > Wouldn't trust it to do what? It already doesn't work on OpenBSD > (does the browser version work though? Never tried) so it's being > kept away from your crown jewels in the sort of tightly locked-down > enclave that linux needs to keep its guts inside itself anyway, so > what's the risk? > A few among the myriad: https://www.tomsguide.com/news/zoom-security-privacy-woes https://jonathanhays.me/2020/04/04/zoom-insecurity/ https://www.reddit.com/r/technology/comments/ftkb69/zooms_security_and_privacy_problems_are/ But, perhaps you're comfortable with that. We're all different.Cheers! Harry.
Re: Re: What’s new in OpenNSD 7.0 NYC*Bug meeting
harrywea...@tutanota.com writes: > > > > I wouldn't trust Zoom any further than I'd trust Skype. > Cheers! Wouldn't trust it to do what? It already doesn't work on OpenBSD (does the browser version work though? Never tried) so it's being kept away from your crown jewels in the sort of tightly locked-down enclave that linux needs to keep its guts inside itself anyway, so what's the risk? Matthew
Re: cannot boot from SSD
Thanks for the details; I overwrote the mbr using dd of=/dev/rsd0c if=/usr/mdec/mbr bs=512 count=1 and then used fdisk to reinstall the OpenBSD partition to the values I used before - and now the system can boot from the ssd. Thank you very much for the help! -- Address is valid for this mailing list only, please do not reply to it direcly, but to the list.
futex(2) not working in inherited mmap'd anon memory
Hello, When I do mmap(MAP_ANONYMOUS | MAP_SHARED) and then fork(), it seems that futex(2) wakeups are not delivered between child and parent in that memory. It does work as expected if I instead use shmget(IPC_PRIVATE). Below is a standalone test program. I tested it with the four OSes mentioned, and the two shmem types depending on that #if, and all worked as expected except the OpenBSD/mmap case, which hangs. Is it a bug? $ uname -a OpenBSD openbsd6.localdomain 6.9 GENERIC.MP#473 amd64 Thanks, === 8< === #include #include #include #include #include #include #include #include #include #include #include #if defined(__linux__) #include #include #elif defined(__OpenBSD__) #include #include #elif defined(__FreeBSD__) #include #include #elif defined(__APPLE__) #define UL_COMPARE_AND_WAIT_SHARED 3 #define ULF_WAKE_ALL 0x0100 extern int __ulock_wait(uint32_t operation, void *addr, uint64_t value, uint32_t timeout); extern int __ulock_wake(uint32_t operation, void *addr, uint64_t wake_value); #endif static int my_futex_wait_u32(void *fut, uint32_t value, struct timespec *timeout) { #if defined(__linux__) if (syscall(SYS_futex, fut, FUTEX_WAIT, value, timeout, 0, 0) == 0) return 0; #elif defined(__OpenBSD__) if ((errno = futex(fut, FUTEX_WAIT, (int) value, timeout, NULL)) == 0) return 0; if (errno == ECANCELED) errno = EINTR; #elif defined(__FreeBSD__) if (_umtx_op(fut, UMTX_OP_WAIT_UINT, value, 0, timeout) == 0) return 0; #elif defined (__APPLE__) if (__ulock_wait(UL_COMPARE_AND_WAIT_SHARED, (void *) fut, value, timeout ? timeout->tv_sec * 100 + timeout->tv_nsec / 1000 : 0) > = 0) return 0; #else errno = ENOSYS; #endif return -1; } static int my_futex_wake(void *fut, int nwaiters) { #if defined(__linux__) if (syscall(SYS_futex, fut, FUTEX_WAKE, nwaiters, NULL, 0, 0) >= 0) return 0; #elif defined(__OpenBSD__) if (futex(fut, FUTEX_WAKE, nwaiters, NULL, NULL) >= 0) return 0; #elif defined(__FreeBSD__) if (_umtx_op(fut, UMTX_OP_WAKE, nwaiters, 0, 0) == 0) return 0; #elif defined (__APPLE__) if (__ulock_wake(UL_COMPARE_AND_WAIT_SHARED | (nwaiters > 1 ? ULF_WAKE_ALL : 0), (void *) fut, 0) >= 0) return 0; if (errno == ENOENT) return 0; #else errno = ENOSYS; #endif return -1; } int main(int argc, char *argv[]) { pid_t pid; uint32_t *memory; int status; #if 1 memory = mmap(NULL, sizeof(uint32_t), PROT_READ | PROT_WRITE, MAP_ANONYMOUS | MAP_SHARED, -1, 0); if (memory == MAP_FAILED) { perror("mmap"); return EXIT_FAILURE; } #else int shm_id; shm_id = shmget(IPC_PRIVATE, sizeof(uint32_t), IPC_CREAT | 0666); if (shm_id < 0) { perror("shmget"); return EXIT_FAILURE; } memory = shmat(shm_id, NULL, 0); if ((intptr_t) memory == -1) { perror("shmat"); return EXIT_FAILURE; } #endif *memory = 42; pid = fork(); if (pid == -1) { perror("fork"); return EXIT_FAILURE; } else if (pid > 0) { printf("hello from parent, will wait for futex...\n"); if (my_futex_wait_u32(memory, 42, NULL) < 0) { perror("futex_wait"); wait(); return EXIT_FAILURE; } wait(); return EXIT_SUCCESS; } else { printf("hello from child, will wake futex...\n"); sleep(1); if (my_futex_wake(memory, INT_MAX) < 0) { perror("futex_wake"); return EXIT_FAILURE; } return EXIT_SUCCESS; } }
Re: cannot boot from SSD
On Tue, Oct 26, 2021 at 07:20:41AM -0300, Crystal Kolipe wrote: > manually type 'boot sd0a:/bsd' That should be hd0a:/bsd
Re: cannot boot from SSD
On Tue, Oct 26, 2021 at 08:15:48AM +0100, Claus Assmann wrote: > On Mon, Oct 25, 2021, Crystal Kolipe wrote: > > > Can you provide the output of the atactl identify command for this unit? > > Thanks for the reply; below is the output from atactl identify, > fdisk, and disklabel. The disk can be mounted without a problem > and -- based on a brief look -- has the installed content. > Is there some simple way to check that the boot loader is installed > on the disk (besides trying to read some sectors using od or something > similar?) > > # atactl sd0 identify > Model: KINGSTON SA400S37240G, Rev: S1Z40102, Serial #: 50026B7380B702FF You seem to have a different firmware revision to any of our drives, which might be relevant, however... > $ fdisk sd0 > Disk: sd0 geometry: 29185/255/63 [468862128 Sectors] > Offset: 0 Signature: 0xAA55 > Starting Ending LBA Info: > #: id C H S - C H S [ start:size ] > --- > 0: BF 0 1 2 - 14592 254 63 [ 64: 234436481 ] Solaris > > 1: 00 0 0 0 - 0 0 0 [ 0: 0 ] unused > > 2: 00 0 0 0 - 0 0 0 [ 0: 0 ] unused > > *3: A6 14593 0 1 - 29184 254 63 [ 234436545: 234420480 ] OpenBSD > Seeing that you have Solaris installed on the same disk, I'm now wondering if you have some non-standard MBR code that is causing the problem. As your Solaris partition is first on the disk, I'm assuming that you installed OpenBSD afterwards. I'm also assuming that you didn't manually use the 'update' command from within OpenBSD fdisk to overwrite the MBR boot code, (just the boot code and not the partition data). The OpenBSD MBR code, I.E. what would be loaded from the first sector on the SSD at boot, is responsible for displaying the 'Using drive X, partition Y' message. If you are not seeing this, then the OpenBSD MBR code is not running. Of course, the Solaris MBR code should also correctly parse the partition table, see that partition 3 is flagged as active and pass control to the OpenBSD PBR contained in it, at which point you would see 'Loading', but that is not happening. If you boot into the OpenBSD bootloader from another device, such as a USB flash drive with the OpenBSD installation media on it, and manually type 'boot sd0a:/bsd', or whatever device the BIOS sees the SSD as, you should find that your newly installed system boots. If you want to write the OpenBSD MBR code to the SSD, you can do that using the 'update' command within fdisk. This will probably allow you to boot OpenBSD from the SSD. However, you will have overwritten the Solaris MBR, which may or may not cause you issues booting Solaris. You could back up the existing MBR first with a command such as: # dd if=/dev/sd0c of=$HOME/old_mbr bs=512 count=1 If you want to check that the OpenBSD MBR code is installed on the disk, the output of the following two commands should match: # dd if=/usr/mdec bs=446 count=1 | hexdump -C # dd if=/dev/sd0c bs=446 count=1 | hexdump -C
Re: Exoscale VPS panic on boot, 10-25 snapshot
On 21/10/26 08:28, Hrvoje Popovski wrote: > > could you try lastes snapshot with sysupgrade? i had same problem on > Dell r620 and latest snapshot fix that panic .. Thank you for the prompt response. Now I'm having no issue with that kernel panic, perhaps I was just unlucky in when I chose to upgrade. What a relief. :) -- https://amissing.link
Re: Thinkpad X1 Carbon Gen 7 WiFi connection issue
On Tue, Oct 26, 2021 at 9:31 AM Sardor Muminov wrote: > I’ve tried with Arch Linux bootable USB image. > Below is the trimmed dmesg output containing "iwlwifi". > > [ 10.780644] iwlwifi :00:14.3: Direct firmware load for > iwlwifi-QuZ-a0-jf-b0-64.ucode failed with error -2 > [ 11.208185] iwlwifi :00:14.3: api flags index 2 larger than > supported by driver > [ 11.208200] iwlwifi :00:14.3: TLV_FW_FSEQ_VERSION: FSEQ Version: > 89.3.35.37 > [ 11.208394] iwlwifi :00:14.3: loaded firmware version 63.c04f3485.0 > QuZ-a0-jf-b0-63.ucode op_mode iwlmvm > [ 11.600912] iwlwifi :00:14.3: Detected Intel(R) Wireless-AC 9560 > 160MHz, REV=0x354 > [ 11.727984] iwlwifi :00:14.3: Detected RF JF, rfid=0x105110 > [ 11.801329] iwlwifi :00:14.3: base HW address: 50:e0:85:74:ca:f2 Hi all, if it helps, this is the firmware version loaded on my X1 Carbon Gen7 running Arch: Oct 25 08:01:20 x1c7 kernel: iwlwifi :00:14.3: loaded firmware version 46.6b541b68.0 9000-pu-b0-jf-b0-46.ucode op_mode iwlmvm Oct 25 08:01:20 x1c7 kernel: iwlwifi :00:14.3: Detected Intel(R) Wireless-AC 9560 160MHz, REV=0x318 Oct 25 08:01:20 x1c7 kernel: iwlwifi :00:14.3: base HW address: 90:78:41:99:c6:9f -f
Re: Thinkpad X1 Carbon Gen 7 WiFi connection issue
Hi Stefan, I’ve tried with Arch Linux bootable USB image. Below is the trimmed dmesg output containing "iwlwifi". [ 10.780644] iwlwifi :00:14.3: Direct firmware load for iwlwifi-QuZ-a0-jf-b0-64.ucode failed with error -2 [ 11.208185] iwlwifi :00:14.3: api flags index 2 larger than supported by driver [ 11.208200] iwlwifi :00:14.3: TLV_FW_FSEQ_VERSION: FSEQ Version: 89.3.35.37 [ 11.208394] iwlwifi :00:14.3: loaded firmware version 63.c04f3485.0 QuZ-a0-jf-b0-63.ucode op_mode iwlmvm [ 11.600912] iwlwifi :00:14.3: Detected Intel(R) Wireless-AC 9560 160MHz, REV=0x354 [ 11.727984] iwlwifi :00:14.3: Detected RF JF, rfid=0x105110 [ 11.801329] iwlwifi :00:14.3: base HW address: 50:e0:85:74:ca:f2 For your convenience, you find full dmesg[1] and lspci[2] output from these links. 1. https://0bin.net/paste/eYczF21o#kR0a9A1-kvX3RDKItcMYzsAxUfxzKVsc44oWD+axvsE 2. https://0bin.net/paste/5dUHu16e#DFnVFOvRoyfuEGCEN6z8woMm4QCuP+-7FKR1oj7pWKx Feel free to contact me if you have any questions, Sardor On Mon, Oct 25, 2021 at 5:44 PM Stefan Sperling wrote: > On Mon, Oct 25, 2021 at 03:57:53PM +0900, Sardor Muminov wrote: > > Hello developers, > > > > I own one of the Thinkpad X1 Carbon Gen 7 series laptops. > > I have installed OpenBSD 7.0 and couldn't get the wireless connection to > > work. > > > > Below is a link to the dmesg[1] and pcidump[2] output. > > > > 1. > > > https://0bin.net/paste/pNBrVw-L#7eWENjA8U41mikVDnCgUsJensq+mWbRzpOuEtLD8usQ > > 2. > > > https://0bin.net/paste/BCS7i7tw#-T5l1bFgNh3Q6eOb6R5sSOi57bEpFralPd5v/Hv1vdF > > > > I have checked Joshua's blog post, but it seems I have a newer version of > > the WiFi chipset (Intel Wi-Fi 6 AX201). > > > > Is there any possibility for me to get this issue resolved? > > > > Thanks in advance, > > Sardor > > > > Can you please boot linux on this machine and tell me which firmware file > the linux iwlwifi driver is loading? In theory it is possible to figure > it out by reading the linux driver. In practice Intel's device matching > code is complicated to follow because they have workarounds layered on > top of more workarounds. The best I could do is make a blind guess, and > such guessing could needlessy waste some of your time and my time. > Thanks. >
Re: cannot boot from SSD
On Mon, Oct 25, 2021, Crystal Kolipe wrote: > Can you provide the output of the atactl identify command for this unit? Thanks for the reply; below is the output from atactl identify, fdisk, and disklabel. The disk can be mounted without a problem and -- based on a brief look -- has the installed content. Is there some simple way to check that the boot loader is installed on the disk (besides trying to read some sectors using od or something similar?) # atactl sd0 identify Model: KINGSTON SA400S37240G, Rev: S1Z40102, Serial #: 50026B7380B702FF Device type: ATA, fixed Cylinders: 16383, heads: 16, sec/track: 63, total sectors: 468862128 Device capabilities: ATA standby timer values IORDY operation IORDY disabling Device supports the following standards: ATA-3 ATA-4 ATA-5 ATA-6 ATA-7 ATA-8 ATA-9 ATA-10 Master password revision code 0xfffe Device supports the following command sets: NOP command READ BUFFER command WRITE BUFFER command Host Protected Area feature set Read look-ahead Write cache Power Management feature set Security Mode feature set SMART feature set Flush Cache Ext command Flush Cache command 48bit address feature set Advanced Power Management feature set DOWNLOAD MICROCODE command Device has enabled the following command sets/features: NOP command READ BUFFER command WRITE BUFFER command Host Protected Area feature set Read look-ahead Write cache Power Management feature set SMART feature set Flush Cache Ext command Flush Cache command 48bit address feature set DOWNLOAD MICROCODE command $ fdisk sd0 Disk: sd0 geometry: 29185/255/63 [468862128 Sectors] Offset: 0 Signature: 0xAA55 Starting Ending LBA Info: #: id C H S - C H S [ start:size ] --- 0: BF 0 1 2 - 14592 254 63 [ 64: 234436481 ] Solaris 1: 00 0 0 0 - 0 0 0 [ 0: 0 ] unused 2: 00 0 0 0 - 0 0 0 [ 0: 0 ] unused *3: A6 14593 0 1 - 29184 254 63 [ 234436545: 234420480 ] OpenBSD $ disklabel sd0 # /dev/rsd0c: type: SCSI disk: SCSI disk label: KINGSTON SA400S3 duid: 2c155e5bcc7344d0 flags: bytes/sector: 512 sectors/track: 63 tracks/cylinder: 255 sectors/cylinder: 16065 cylinders: 29185 total sectors: 468862128 boundstart: 234436545 boundend: 468857025 drivedata: 0 16 partitions: #size offset fstype [fsize bsize cpg] a: 2097151234436545 4.2BSD 2048 16384 12960 b: 17267584236533696swap c:4688621280 unused d: 8388608253801280 4.2BSD 2048 16384 12960 e: 27767872262189888 4.2BSD 2048 16384 12960 f: 12582912289957760 4.2BSD 2048 16384 12960 g: 2097152302540672 4.2BSD 2048 16384 12960 h: 33947968304637824 4.2BSD 2048 16384 12960 i:234436481 64 unknown j: 4194304338585792 4.2BSD 2048 16384 12960 k: 12582912342780096 4.2BSD 2048 16384 12960 l:113494016355363008 4.2BSD 2048 16384 12960 -- Address is valid for this mailing list only, please do not reply to it direcly, but to the list.
Re: Exoscale VPS panic on boot, 10-25 snapshot
On 26.10.2021. 1:16, Ashlen wrote: > Here is as much information as I could get. After upgrading to a > snapshot earlier today (October 25th), the Exoscale VPS panics on boot. > I use this VPS to self-host synapse (a Matrix homeserver, for > messaging). > > I can't copy and paste from the web console that Exoscale provides so I > had to transcribe all of it by hand, I hope it's all accurate. In > particular, the correct number of spaces between fields in `ps` output > is unknown to me, but everything else should be OK I think. I tried to > get a traceback for cpu1 as well, but the console hangs when I issue > `machine ddbcpu 1` so only the traceback for cpu0 was available to me. > > Booting /bsd.sp instead of /bsd.mp or scaling the VPS down to one core > appears to make no difference, the panic happens regardless. > > Any suggestions to get my VPS back up and running would be much > appreciated, I feel pretty lost with what to do next. Thanks. > could you try lastes snapshot with sysupgrade? i had same problem on Dell r620 and latest snapshot fix that panic ..