You are not logged in.

#1 Yesterday 07:04:21

alexdandrea
Member
Registered: 2020-10-09
Posts: 2

Sway crashes w/ multiple monitors

I use sway w/ the same system in different places, one with 4k monitor and another with 2x hdmi monitors - both connected via docking station. On the workplace with dual monitor setup, I suffer random crashes, at least once a day. Sway was rock solid on 1.9, these crashes only started with the upgrade to 1.10.

With sway, I also use swww for background images and kanshi for output management. This is the info from the last crash of yesterday:

$ DEBUGINFOD_URLS='https://debuginfod.archlinux.org' coredumpctl debug 246439
           PID: 246439 (sway)
           UID: 1000 (dandral)
           GID: 1000 (dandral)
        Signal: 11 (SEGV)
     Timestamp: Mon 2025-03-31 15:54:00 CEST (16h ago)
  Command Line: sway
    Executable: /usr/bin/sway
 Control Group: /user.slice/user-1000.slice/session-12.scope
          Unit: session-12.scope
         Slice: user-1000.slice
       Session: 12
     Owner UID: 1000 (dandral)
       Boot ID: 51c26b478ab44e41880836a13d5b471b
    Machine ID: b82b58dcec2c4490b8e646145c9a635c
      Hostname: dandroid
       Storage: /var/lib/systemd/coredump/core.sway.1000.51c26b478ab44e41880836a13d5b471b.246439.1743429240000000.zst (present)
  Size on Disk: 10.1M
       Message: Process 246439 (sway) of user 1000 dumped core.

[...]

(gdb) bt
#0  wl_resource_get_client (resource=0x5dd6810f2e38) at ../wayland-1.23.1/src/wayland-server.c:824
#1  0x00007f6fe877c244 in surface_handle_output_bind (listener=0x5dd35c22a060, data=0x7ffddb94ac60) at ../wlroots-0.18.2/types/wlr_compositor.c:1048
#2  0x00007f6fe882947e in wl_signal_emit_mutable (signal=signal@entry=0x5dd35c011358, data=data@entry=0x7ffddb94ac60) at ../wayland-1.23.1/src/wayland-server.c:2314
#3  0x00007f6fe8764b1c in output_bind (wl_client=<optimized out>, data=0x5dd35c011250, version=<optimized out>, id=<optimized out>) at ../wlroots-0.18.2/types/output/output.c:126
#4  0x00007f6fe7e1d976 in ffi_call_unix64 () at ../src/x86/unix64.S:104
#5  0x00007f6fe7e1a12c in ffi_call_int (cif=cif@entry=0x7ffddb94ae60, fn=<optimized out>, rvalue=<optimized out>, avalue=<optimized out>, closure=closure@entry=0x0) at ../src/x86/ffi64.c:676
#6  0x00007f6fe7e1cf0e in ffi_call (cif=cif@entry=0x7ffddb94ae60, fn=<optimized out>, rvalue=rvalue@entry=0x0, avalue=avalue@entry=0x7ffddb94af30) at ../src/x86/ffi64.c:713
#7  0x00007f6fe8827e85 in wl_closure_invoke (closure=closure@entry=0x5dd35c2838c0, target=<optimized out>, target@entry=0x5dd35c21efe0, opcode=opcode@entry=0, data=<optimized out>, data@entry=0x5dd35c2484f0, flags=2)
    at ../wayland-1.23.1/src/connection.c:1228
#8  0x00007f6fe882cd22 in wl_client_connection_data (fd=<optimized out>, mask=<optimized out>, data=0x5dd35c2484f0) at ../wayland-1.23.1/src/wayland-server.c:444
#9  0x00007f6fe882b112 in wl_event_loop_dispatch (loop=0x5dd35b108b00, timeout=<optimized out>, timeout@entry=-1) at ../wayland-1.23.1/src/event-loop.c:1105
#10 0x00007f6fe882d1f7 in wl_display_run (display=0x5dd35b10e320) at ../wayland-1.23.1/src/wayland-server.c:1530
#11 0x00005dd326c7edd2 in server_run (server=<optimized out>) at ../sway/sway/server.c:501
#12 main (argc=<optimized out>, argv=<optimized out>) at ../sway/sway/main.c:374

Not sure where to look and whether this bt can help someone? Should I open an issue at the sway project?

Thank you
Alex

Offline

#2 Yesterday 19:17:02

seth
Member
Registered: 2012-09-03
Posts: 62,260

Re: Sway crashes w/ multiple monitors

There're no hits for https://github.com/swaywm/sway/issues?q … ut_bind%20 so it's likely not been reported yet.

I suffer random crashes, at least once a day

Any discernable pattern at all?

Offline

#3 Today 06:47:44

alexdandrea
Member
Registered: 2020-10-09
Posts: 2

Re: Sway crashes w/ multiple monitors

So, yesterday was really bad:

$ coredumpctl list --since=2025-04-01 sway
TIME                            PID  UID  GID SIG     COREFILE EXE           SIZE
Tue 2025-04-01 09:07:30 CEST   1964 1000 1000 SIGSEGV present  /usr/bin/sway 9.1M
Tue 2025-04-01 09:08:55 CEST   9836 1000 1000 SIGSEGV present  /usr/bin/sway 8.6M
Tue 2025-04-01 09:32:40 CEST   1811 1000 1000 SIGSEGV present  /usr/bin/sway 9.1M
Tue 2025-04-01 09:47:38 CEST  24264 1000 1000 SIGSEGV present  /usr/bin/sway 8.6M
Tue 2025-04-01 09:48:13 CEST  62730 1000 1000 SIGSEGV present  /usr/bin/sway 8.6M
Tue 2025-04-01 12:43:32 CEST  64103 1000 1000 SIGSEGV present  /usr/bin/sway 9.2M
Tue 2025-04-01 13:36:20 CEST 302584 1000 1000 SIGSEGV present  /usr/bin/sway 9.1M
Tue 2025-04-01 13:42:34 CEST 379387 1000 1000 SIGSEGV present  /usr/bin/sway   9M
Tue 2025-04-01 13:57:55 CEST 391421 1000 1000 SIGSEGV present  /usr/bin/sway 8.7M
Tue 2025-04-01 15:06:29 CEST   1910 1000 1000 SIGSEGV present  /usr/bin/sway 9.4M
Tue 2025-04-01 15:14:58 CEST 104739 1000 1000 SIGSEGV present  /usr/bin/sway 8.8M

A pattern I see is, this only happens when a new widget is to be placed on the "surface", ie. when I run wofi (which creates one), open a new wezterm window, it even crashed when swaylock kicked in. Since this is my machine at work, I have today disabled the second monitor, since I need to get work done reliably :-).

If I open an issue, is this backtrace sufficient? There are other threads in the dump, but when dumping them, output gets voluminous and not telling AFAICT. The backtrace for all the dumps looks identical in the excerpt that I posted.

Thank you for your support!

Offline

#4 Today 07:36:10

seth
Member
Registered: 2012-09-03
Posts: 62,260

Re: Sway crashes w/ multiple monitors

The one in #1 (plus the circumstances) is what you have, if upstream requires more details or a gdwarf build, they'll tell you.
nb, the crash happens in https://archlinux.org/packages/extra/x86_64/wayland/ via https://archlinux.org/packages/extra/x86_64/wlroots/ but if downgrading sway to 1.9 prevents this, the cause is in sway 1.10

Offline

Board footer

Powered by FluxBB