X11 Forwarding from FreeBSD Qemu Guest to Linux Host

From: Jishan Alam <jishanalam9128_at_gmail.com>
Date: Fri, 23 Jan 2026 15:49:40 UTC
Hello,
So I have set up FreeBSD-15.0 in my system using qemu and I'm using
ssh to connect to the local qemu instance using ssh.

Host System: Arch Linux 6.18.2 Hyprland (Xwayland installed)
Guest System: FreeBSD 15.0 (Qemu) (xorg-apps, xauth and xterm installed)

So what I would like to try is to run GUI applications without
installing the whole Desktop Environment in FreeBSD and I'm trying to
achieve this using the X11 Forwarding option from ssh with
X11Forwarding options enabled but It's still not connecting. Is it due
to using hyprland in my host?
I'm trying the following:

1. Start Qemu using the following command
    qemu-system-x86_64 \
        -m 4096 \
        -smp 4 \
        -enable-kvm \
        -drive file=freebsd15.qcow2,format=qcow2 \
        -boot d \
        -net nic \
        -net user,hostfwd=tcp::2222-:22

2. Normally Connect using the following command
    ssh user@localhost -p 2222

3. Now Im trying to connect using the following command
    ssh -X user@localhost -p 2222
and
    ssh -Y user@localhost -p 2222

4. after connection I try the following command
    echo $DISPLAY
which displays nothing and I supposed its supposed to display
something like `localhost:10.0` but its not

5. Tried with verbose output
    ssh -vv -X user@localhost -p 2222
the relevent logs
debug2: channel_input_open_confirmation: channel 0: callback start
debug2: x11_get_proto: /usr/bin/xauth  list :1 2>/dev/null
Warning: No xauth data; using fake authentication data for X11 forwarding.
debug1: Requesting X11 forwarding with authentication spoofing.
debug2: channel 0: request x11-req confirm 1
debug2: client_session2_setup: id 0
debug2: channel 0: request pty-req confirm 1
debug2: channel 0: request shell confirm 1
debug2: channel_input_open_confirmation: channel 0: callback done
debug2: channel 0: open confirm rwindow 0 rmax 32768
debug1: Remote: No xauth program; cannot forward X11.
debug2: channel_input_status_confirm: type 100 id 0
X11 forwarding request failed on channel 0
debug2: channel_input_status_confirm: type 99 id 0
debug2: PTY allocation request accepted on channel 0
debug2: channel 0: rcvd adjust 2097152
debug2: channel_input_status_confirm: type 99 id 0
debug2: shell request accepted on channel 0

as you can see its says `X11 forwarding request failed on channel 0`
So I don't know what to do next or how to debug this
Any tips would be appreciated

-- 
Best Regards,
Jishan Alam