On Sun, Dec 20, 2020 at 06:27:33AM +0000, James Cook wrote: > On Sat, Dec 19, 2020 at 07:33:42AM +0000, James Cook wrote: > > > Suggestions are welcome. In the meantime I am slowly trying to debug > > > this myself, mostly as a learning exercise. I've successfully built my > > > own bsd.rd (using the instructions on the release(8) man page) with the > > > intention of adding some debug output to narrow down where it's > > > getting stuck, but I don't know my way around the kernel code. > > > > Minor progress: I have determined that the kernel gets at least as far > > as exec-ing the init process (more precisely, calling sys_execve in > > init_main.c). > > I found out init gets stuck calling sleep(2) in setctty in > sbin/init/init.c. (Details below on how I determined that.) > > Any idea what could cause a call to sleep to just hang indefinitely?
A couple more observations: - I let the laptop sit for a long time in the "hung" state. Eventually, after at least an hour (but less than 2) I got the "Welcome to the OpenBSD/amd64 6.8 installation program." prompt. I was able to start a shell, and tried the command "sleep 1". It's four minutes since I typed "sleep 1", and it still hasn't returned. - With the bsd.mp kernel, sleep times are distorted, but apparently not as badly. For example, "sleep 10" at the shell pauses for about 42 seconds (I measured it twice). A C program calling sleep(2) (the input is the number 2) pauses for significantly more than 2 seconds (maybe 8-10?). -- James