Meumeu / WiVRn

An OpenXR streaming application to a standalone headset
GNU General Public License v3.0
134 stars 22 forks source link

Unable to reconnect #78

Open galister opened 1 week ago

galister commented 1 week ago

Client shows "video stream interrupted" followed by "waiting for video stream".

thread apply all bt on the forked process:

Thread 34 (Thread 0x7ff40be006c0 (LWP 26279) "wivrn-server"):
#0  0x00007ff460cce425 in ??? () at /usr/lib64/libc.so.6
#1  0x00007ff460cd0d82 in pthread_cond_wait () at /usr/lib64/libc.so.6
#2  0x0000564d38819dd5 in os_thread_helper_wait_locked ()
#3  0x0000564d3881a776 in run_func ()
#4  0x00007ff460cd1be1 in ??? () at /usr/lib64/libc.so.6
#5  0x00007ff460d3e5dc in ??? () at /usr/lib64/libc.so.6

Thread 33 (Thread 0x7ff40b4006c0 (LWP 26266) "wivrn-server"):
#0  0x00007ff460d3ea3a in epoll_wait () at /usr/lib64/libc.so.6
#1  0x0000564d387c0d50 in client_loop ()
#2  0x0000564d387c126c in ipc_server_client_thread ()
#3  0x00007ff460cd1be1 in ??? () at /usr/lib64/libc.so.6
#4  0x00007ff460d3e5dc in ??? () at /usr/lib64/libc.so.6

Thread 32 (Thread 0x7ff4160006c0 (LWP 24212) "wivrn-server"):
#0  0x00007ff460cce425 in ??? () at /usr/lib64/libc.so.6
#1  0x00007ff460cd0d82 in pthread_cond_wait () at /usr/lib64/libc.so.6
#2  0x0000564d38819dd5 in os_thread_helper_wait_locked ()
#3  0x0000564d3881a776 in run_func ()
#4  0x00007ff460cd1be1 in ??? () at /usr/lib64/libc.so.6
#5  0x00007ff460d3e5dc in ??? () at /usr/lib64/libc.so.6

Thread 31 (Thread 0x7ff416a006c0 (LWP 24211) "wivrn-server"):
#0  0x00007ff460d3ea3a in epoll_wait () at /usr/lib64/libc.so.6
#1  0x0000564d387c0d50 in client_loop ()
#2  0x0000564d387c126c in ipc_server_client_thread ()
#3  0x00007ff460cd1be1 in ??? () at /usr/lib64/libc.so.6
#4  0x00007ff460d3e5dc in ??? () at /usr/lib64/libc.so.6

Thread 30 (Thread 0x7ff4174006c0 (LWP 24194) "wivrn-server"):
#0  0x00007ff460d3ea3a in epoll_wait () at /usr/lib64/libc.so.6
#1  0x0000564d387c0d50 in client_loop ()
#2  0x0000564d387c126c in ipc_server_client_thread ()
#3  0x00007ff460cd1be1 in ??? () at /usr/lib64/libc.so.6
#4  0x00007ff460d3e5dc in ??? () at /usr/lib64/libc.so.6

Thread 29 (Thread 0x7ff417e006c0 (LWP 24154) "wivrn-server"):
#0  0x00007ff460d3293f in poll () at /usr/lib64/libc.so.6
#1  0x00007ff462ae65d1 in avahi_simple_poll_run () at /usr/lib64/libavahi-common.so.3
#2  0x00007ff462ae67b8 in avahi_simple_poll_iterate () at /usr/lib64/libavahi-common.so.3
#3  0x0000564d38687371 in avahi_publisher::iterate(int) ()

thread apply all bt on the parent process:

Thread 1 (Thread 0x7ff45f00cf00 (LWP 5536) "wivrn-server"):
#0  0x00007ff460d32904 in poll () at /usr/lib64/libc.so.6
#1  0x0000564d3868ae47 in inner_main(int, char**) ()
#2  0x0000564d3868b4e8 in main ()
galister commented 1 week ago

Another bt on forked process:

Thread 33 (Thread 0x7f59450006c0 (LWP 28343) "wivrn-server"):
#0  0x00007f5990f0abfa in clock_nanosleep () at /usr/lib64/libc.so.6
#1  0x00007f5990f15fb7 in nanosleep () at /usr/lib64/libc.so.6
#2  0x0000559169d7b443 in os_nanosleep ()
#3  0x0000559169d7b48c in os_precise_sleeper_nanosleep ()
#4  0x0000559169d7c608 in wait_for_scheduled_free ()
#5  0x0000559169d7c8b7 in run_func ()
#6  0x00007f5990ed1be1 in ??? () at /usr/lib64/libc.so.6
#7  0x00007f5990f3e5dc in ??? () at /usr/lib64/libc.so.6

Thread 32 (Thread 0x7f593be006c0 (LWP 28328) "wivrn-server"):
#0  0x00007f5990ece425 in ??? () at /usr/lib64/libc.so.6
#1  0x00007f5990ed0d82 in pthread_cond_wait () at /usr/lib64/libc.so.6
#2  0x0000559169d7bdd5 in os_thread_helper_wait_locked ()
#3  0x0000559169d7c9c3 in wait_for_wait_thread_locked ()
#4  0x0000559169d7ca03 in wait_for_wait_thread ()
#5  0x0000559169d7d2c9 in multi_compositor_layer_begin ()
#6  0x0000559169d270f1 in xrt_comp_layer_begin ()
#7  0x0000559169d2a320 in ipc_handle_compositor_layer_sync ()
#8  0x0000559169d24bf0 in ipc_dispatch ()
#9  0x0000559169d22ffb in client_loop ()
#10 0x0000559169d2326c in ipc_server_client_thread ()
#11 0x00007f5990ed1be1 in ??? () at /usr/lib64/libc.so.6
#12 0x00007f5990f3e5dc in ??? () at /usr/lib64/libc.so.6

Thread 31 (Thread 0x7f59474006c0 (LWP 26088) "wivrn-server"):
#0  0x00007f5990ece425 in ??? () at /usr/lib64/libc.so.6
#1  0x00007f5990ed0d82 in pthread_cond_wait () at /usr/lib64/libc.so.6
#2  0x0000559169d7bdd5 in os_thread_helper_wait_locked ()
#3  0x0000559169d7c776 in run_func ()
#4  0x00007f5990ed1be1 in ??? () at /usr/lib64/libc.so.6
#5  0x00007f5990f3e5dc in ??? () at /usr/lib64/libc.so.6

Thread 30 (Thread 0x7f5947e006c0 (LWP 26087) "wivrn-server"):
#0  0x00007f5990f3ea3a in epoll_wait () at /usr/lib64/libc.so.6
#1  0x0000559169d22d50 in client_loop ()
#2  0x0000559169d2326c in ipc_server_client_thread ()
#3  0x00007f5990ed1be1 in ??? () at /usr/lib64/libc.so.6
#4  0x00007f5990f3e5dc in ??? () at /usr/lib64/libc.so.6

Thread 29 (Thread 0x7f5950c006c0 (LWP 26070) "wivrn-server"):
#0  0x00007f5990f3ea3a in epoll_wait () at /usr/lib64/libc.so.6
xytovl commented 2 days ago

Are there any relevant logs in server output? Which encoder are you using, and does the issue happen on software encoding as well?

galister commented 2 days ago

no relevant logs other than the socket closed ones from the prior disconnect. this is on vaapi, will test with x264, but the issue is quite rare, so not sure when i'll have more info