Sway: Can't upload images

I can’t see any issues with your config. I bet it’s not a Sway issue. Do you use UFW or some else firewall? How about downloading some linux .iso and launch it from USB to upload something?

1 Like

Thanks , that is what I thought you meant.
You need to determine if the problem is only in browsers.
You also need to determine if the WM is causing the problem…try another WM

1 Like

Hi George,
I’m impressed with your experience. I am just a user of Linux, but feel my research skills are
good either using the web or using AI. I posed your problem to 2 different AI’s and both pointed to a portal problem.

AI1 - " This is almost certainly an xdg-desktop-portal / portal backend problem, not your browsers and not the images themselves."

AI2 - " xdg-desktop-portal is broken, missing, or misconfigured
On Wayland, all file uploads go through xdg-desktop-portal, not the browser. If the portal is broken, every upload fails everywhere.

There was an awful lot of explanation and many steps for checking what is wrong. Too long to post it all here, plus I don’t even know if this is the answer to the problem. I will post one of them.
Begin -----------------------------

ps aux | grep xdg-desktop-portal

You should see something like:

  • xdg-desktop-portal
  • xdg-desktop-portal-wlr (for Sway/Hyprland)
  • NOT xdg-desktop-portal-gnome or -kde unless you’re using GNOME/KDE

Check if the wlr portal is installed:
sudo zypper install xdg-desktop-portal-wlr

:check_mark: Restart portals:
systemctl --user restart xdg-desktop-portal
systemctl --user restart xdg-desktop-portal-wlr

Then restart your browser.
END -------------------

I hope this helps or points you in the right direction.

Have a good day.
Howard

3 Likes

Can someone please explain what a portal is?.

2 Likes

I was kind of wondering what it was myself. Sounds like something out of a sci-fi move as in a portal to another world or dimension.

3 Likes

Nice catch! I can confirm that I have the xdg-desktop-portal:
┌─[✗]─[pete@gentoo]─[~]
└──╼ sudo ps aux | grep xdg
pete 8444 0.0 0.1 387632 11056 tty1 Sl+ 09:36 0:00 /usr/libexec/xdg-desktop-portal
pete 8459 0.0 0.0 308416 5800 tty1 Sl+ 09:36 0:00 /usr/libexec/xdg-permission-store
pete 8469 0.0 0.0 539560 6460 tty1 Sl+ 09:36 0:00 /usr/libexec/xdg-document-portal
pete 8493 0.0 0.2 481304 22348 tty1 Sl+ 09:36 0:00 /usr/libexec/xdg-desktop-portal-gtk
pete 8507 0.0 0.4 370992 35644 tty1 Sl+ 09:36 0:00 /usr/libexec/xdg-desktop-portal-wlr
pete 8513 0.0 0.4 454824 37724 tty1 Sl+ 09:36 0:00 /usr/libexec/xdg-desktop-portal-hyprland
pete 8627 0.0 0.0 9032 2256 pts/0 S+ 09:38 0:00 grep --color=auto xdg

┌─[pete@gentoo]─[~]
└──╼ cat ~/.config/sway/config | grep XDG
#XDG_CURRENT_DESKTOP=sway
exec dbus-update-activation-environment --systemd WAYLAND_DISPLAY DISPLAY SWAYSOCK XDG_CURRENT_DESKTOP=sway XDG_SESSION_DESKTOP=sway
exec dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP

┌─[pete@gentoo]─[~]
└──╼ emerge --pretend xdg-desktop-portal

These are the packages that would be merged, in order:

Calculating dependencies … done!
Dependency resolution took 7.63 s (backtrack: 0/20).

[binary R ] sys-apps/xdg-desktop-portal-1.20.3-2::gentoo USE=“seccomp udev -flatpak -geolocation (-systemd) -test” 420 KiB

Total: 1 package (1 reinstall, 1 binary), Size of downloads: 420 KiB

2 Likes

I suggested trying a browser to check if there are other problems lurking otherwise you could spend hours looking in the wrong direction

What firewall are you using if any

1 Like

Check the openSUSE’s own dotfiles:

Maybe there’s something openSUSE does differently

1 Like

Well, as far as I know, no. YaST says: “Current State: active Invoked by: Program”, but Status says disabled, and all ports are open.

george      1565  0.0  0.1 829916 23492 ?        Ssl  Jan03   0:00 /usr/libexec/xdg-desktop-portal
george     28111  0.0  0.0   6696  4188 pts/2    S+   08:59   0:00 grep --color=auto xdg-desktop-portal

Zypper says all are installed.

Repository-Daten werden geladen...
Installierte Pakete werden gelesen...
'xdg-desktop-portal' ist bereits installiert.
Kein Aktualisierungskandidat für 'xdg-desktop-portal-1.20.3-2.2.x86_64'. Die neueste Version ist bereits installiert.
'xdg-desktop-portal-wlr' ist bereits installiert.
Kein Aktualisierungskandidat für 'xdg-desktop-portal-wlr-0.8.1-1.1.x86_64'. Die neueste Version ist bereits installiert.
Paketabhängigkeiten werden aufgelöst...
Keine auszuführenden Aktionen.

And the systemctl didn’t work.

I did install sway-branding-openSUSEand removed sway-branding-upstream, but nothing helped. So I went back to upstream.

2 Likes

Do you mean that these commands from Howard’s post didn’t work?

Restart portals:systemctl --user restart xdg-desktop-portal
systemctl --user restart xdg-desktop-portal-wlr

1 Like

No, I mean that they just didn’t do anything. Silent output, no error or stuff. New browser session after killall - same.

1 Like

What do you get from:

systemctl status xdg-desktop-portal

systemctl status xdg-desktop-portal-wlr

1 Like
george@opensuse:~> systemctl --user status xdg-desktop-portal-wlr.service 
○ xdg-desktop-portal-wlr.service - Portal service (wlroots implementation)
     Loaded: loaded (/usr/lib/systemd/user/xdg-desktop-portal-wlr.service; static)
     Active: inactive (dead)

Jan 04 09:01:16 opensuse systemd[1447]: Portal service (wlroots implementation) was>
Jan 04 11:40:36 opensuse systemd[1447]: Portal service (wlroots implementation) was>
george@opensuse:~> systemctl --user status xdg-desktop-portal
● xdg-desktop-portal.service - Portal service
     Loaded: loaded (/usr/lib/systemd/user/xdg-desktop-portal.service; static)
     Active: active (running) since Sun 2026-01-04 09:01:13 CET; 2h 40min ago
 Invocation: 36a9e9fef26f44038c2b5b2ec110846a
   Main PID: 30740 (xdg-desktop-por)
      Tasks: 6 (limit: 18922)
        CPU: 41ms
     CGroup: /user.slice/user-1000.slice/user@1000.service/session.slice/xdg-deskto>
             └─30740 /usr/libexec/xdg-desktop-portal

Jan 04 09:01:12 opensuse /usr/libexec/xdg-desktop-portal[30740]: Choosing gtk.porta>
Jan 04 09:01:12 opensuse /usr/libexec/xdg-desktop-portal[30740]: Choosing gtk.porta>
Jan 04 09:01:13 opensuse /usr/libexec/xdg-desktop-portal[30740]: Choosing gtk.porta>
Jan 04 09:01:13 opensuse /usr/libexec/xdg-desktop-portal[30740]: Choosing gtk.porta>
Jan 04 09:01:13 opensuse /usr/libexec/xdg-desktop-portal[30740]: Choosing gtk.porta>
Jan 04 09:01:13 opensuse /usr/libexec/xdg-desktop-portal[30740]: Choosing gtk.porta>
Jan 04 09:01:13 opensuse /usr/libexec/xdg-desktop-portal[30740]: Choosing gtk.porta>
Jan 04 09:01:13 opensuse /usr/libexec/xdg-desktop-portal[30740]: Choosing gtk.porta>
Jan 04 09:01:13 opensuse systemd[1447]: Started Portal service.
Jan 04 09:01:21 opensuse /usr/libexec/xdg-desktop-portal[30740]: Backend call faile>
george@opensuse:~> systemctl start xdg-desktop-portal-wlr.service
==== AUTHENTICATING FOR org.freedesktop.systemd1.manage-units ====
Legitimierung ist zum Starten von »xdg-desktop-portal-wlr.service« notwendig.
Authenticating as: root
Password: 
polkit-agent-helper-1: pam_authenticate failed: Authentication failure
==== AUTHENTICATION FAILED ====
Failed to start xdg-desktop-portal-wlr.service: Access denied
See system logs and 'systemctl status xdg-desktop-portal-wlr.service' for details.
george@opensuse:~> systemctl start xdg-desktop-portal-wlr.service
==== AUTHENTICATING FOR org.freedesktop.systemd1.manage-units ====
Legitimierung ist zum Starten von »xdg-desktop-portal-wlr.service« notwendig.
Authenticating as: root
Password: 
==== AUTHENTICATION COMPLETE ====
Failed to start xdg-desktop-portal-wlr.service: Unit xdg-desktop-portal-wlr.service not found.
george@opensuse:~> systemctl start ^Cg-desktop-portal-wlr.service
george@opensuse:~> systemctl --user status xdg-desktop-portal
● xdg-desktop-portal.service - Portal service
     Loaded: loaded (/usr/lib/systemd/user/xdg-desktop-portal.service; static)
     Active: active (running) since Sun 2026-01-04 09:01:13 CET; 2h 41min ago
 Invocation: 36a9e9fef26f44038c2b5b2ec110846a
   Main PID: 30740 (xdg-desktop-por)
      Tasks: 6 (limit: 18922)
        CPU: 41ms
     CGroup: /user.slice/user-1000.slice/user@1000.service/session.slice/xdg-deskto>
             └─30740 /usr/libexec/xdg-desktop-portal

Jan 04 09:01:12 opensuse /usr/libexec/xdg-desktop-portal[30740]: Choosing gtk.porta>
Jan 04 09:01:12 opensuse /usr/libexec/xdg-desktop-portal[30740]: Choosing gtk.porta>
Jan 04 09:01:13 opensuse /usr/libexec/xdg-desktop-portal[30740]: Choosing gtk.porta>
Jan 04 09:01:13 opensuse /usr/libexec/xdg-desktop-portal[30740]: Choosing gtk.porta>
Jan 04 09:01:13 opensuse /usr/libexec/xdg-desktop-portal[30740]: Choosing gtk.porta>
Jan 04 09:01:13 opensuse /usr/libexec/xdg-desktop-portal[30740]: Choosing gtk.porta>
Jan 04 09:01:13 opensuse /usr/libexec/xdg-desktop-portal[30740]: Choosing gtk.porta>
Jan 04 09:01:13 opensuse /usr/libexec/xdg-desktop-portal[30740]: Choosing gtk.porta>
Jan 04 09:01:13 opensuse systemd[1447]: Started Portal service.
Jan 04 09:01:21 opensuse /usr/libexec/xdg-desktop-portal[30740]: Backend call faile>
george@opensuse:~> systemctl --user status xdg-desktop-portal-wlr
○ xdg-desktop-portal-wlr.service - Portal service (wlroots implementation)
     Loaded: loaded (/usr/lib/systemd/user/xdg-desktop-portal-wlr.service; static)
     Active: inactive (dead)

Jan 04 09:01:16 opensuse systemd[1447]: Portal service (wlroots implementation) was>
Jan 04 11:40:36 opensuse systemd[1447]: Portal service (wlroots implementation) was>
george@opensuse:~> systemctl --user start xdg-desktop-portal-wlr -v
systemctl: Ungültige Option -- v
george@opensuse:~> systemctl --user start xdg-desktop-portal-wlr
george@opensuse:~> systemctl --user status xdg-desktop-portal-wlr
○ xdg-desktop-portal-wlr.service - Portal service (wlroots implementation)
     Loaded: loaded (/usr/lib/systemd/user/xdg-desktop-portal-wlr.service; static)
     Active: inactive (dead)

Jan 04 09:01:16 opensuse systemd[1447]: Portal service (wlroots implementation) was>
Jan 04 11:40:36 opensuse systemd[1447]: Portal service (wlroots implementation) was>
Jan 04 11:43:00 opensuse systemd[1447]: Portal service (wlroots implementation) was>













































service (wlroots implementation)
/xdg-desktop-portal-wlr.service; static)


rtal service (wlroots implementation) was skipped because of an unmet condition che>
rtal service (wlroots implementation) was skipped because of an unmet condition che>
rtal service (wlroots implementation) was skipped because of an unmet condition che>
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~

















































skipped because of an unmet condition check (ConditionEnvironment=WAYLAND_DISPLAY).
skipped because of an unmet condition check (ConditionEnvironment=WAYLAND_DISPLAY).
skipped because of an unmet condition check (ConditionEnvironment=WAYLAND_DISPLAY).
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
george@opensuse:~> 

sorry about the bad formatting… seems like there’s a bus error or something?

I’m not using SystemD so I’m not sure if the service should be dead, I think not. What happens if you open Firefox and run status check when Firefox is running?

1 Like

Now that I have read more about your systemctl message I noticed you have PAM authentication failures there. Check if you have more info in

/var/log/auth.log

/var/log/secure

And also the log in the error message

“See system logs and ‘systemctl status xdg-desktop-portal-wlr.service’ for details.”

2 Likes

Hmm, funny. They’re named different.

george@opensuse:~> sudo cat /var/log/auth.log | grep xdg
[sudo] Passwort für root: 
cat: /var/log/auth.log: Datei oder Verzeichnis nicht gefunden
george@opensuse:~> sudo cat /var/log/secure | grep xdg
cat: /var/log/secure: Datei oder Verzeichnis nicht gefunden
george@opensuse:~> ls /var
adm  cache  crash  lib  lock  log  mail  opt  run  samba  spool  tmp  agentx
george@opensuse:~> ls /var/log
audit                               boot.log-20260102.xz
chrony                              boot.log-20260103.xz
cups                                boot.log-20260104.xz
journal                             firewalld
krb5                                pbl.log
lightdm                             plymouth-debug.log
private                             plymouth-shutdown-debug.log
samba                               snapper.log
tuned                               wpa_supplicant.log
updateTestcase-2026-01-02-00-04-30  xdm.errors
updateTestcase-2026-01-03-09-35-03  Xorg.0.log
YaST2                               Xorg.0.log.old
zypp                                Xorg.1.log
alternatives.log                    zypper.log
boot.log                            zypper.log-20251031.xz
boot.log-20251223.xz                zypper.log-20251112.xz
boot.log-20251224.xz                zypper.log-20251223.xz
boot.log-20251230.xz                zypper.log-20251230.xz
boot.log-20251231.xz
george@opensuse:~> 
1 Like

I booted my Mint and it has the /var/log/auth.log

pete@pete:~$ uname -a
Linux pete 6.8.0-90-generic #91-Ubuntu SMP PREEMPT_DYNAMIC Tue Nov 18 14:14:30 UTC 2025 x86_64 x86_64 x86_64 GNU/Linux
pete@pete:~$ ls /var/log/
alternatives.log    hp
alternatives.log.1  installer
apt                 journal
auth.log            kern.log
auth.log.1          kern.log.1
auth.log.2.gz       kern.log.2.gz
auth.log.3.gz       kern.log.3.gz
auth.log.4.gz       kern.log.4.gz
boot.log            lastlog
boot.log.1          lightdm
boot.log.2          mintsystem.log
boot.log.3          mintsystem.timestamps
boot.log.4          openvpn
bootstrap.log       private
btmp                README
btmp.1              samba
cups                speech-dispatcher
cups-browsed        syslog
dmesg               syslog.1
dmesg.0             syslog.2.gz
dmesg.1.gz          syslog.3.gz
dmesg.2.gz          syslog.4.gz
dmesg.3.gz          ubuntu-system-adjustments-adjust-grub-title.log
dmesg.4.gz          ubuntu-system-adjustments-start.log
dpkg.log            ubuntu-system-adjustments-stop.log
dpkg.log.1          wtmp
faillog             Xorg.0.log
fontconfig.log      Xorg.0.log.old
gpu-manager.log

But there’s not all the logs I mentioned. I read the README in the /var/log and it says:

cat /var/log/README
You are looking for the traditional text log files in /var/log, and they are
gone?

Here's an explanation on what's going on:

You are running a systemd-based OS where traditional syslog has been replaced
with the Journal. The journal stores the same (and more) information as classic
syslog. To make use of the journal and access the collected log data simply
invoke "journalctl", which will output the logs in the identical text-based
format the syslog files in /var/log used to be. For further details, please
refer to journalctl(1).

Alternatively, consider installing one of the traditional syslog
implementations available for your distribution, which will generate the
classic log files for you. Syslog implementations such as syslog-ng or rsyslog
may be installed side-by-side with the journal and will continue to function
the way they always did.

Thank you!

The Mint is not using Sway but here’s what my journalctl shows:


pete@pete:~$ journalctl --user | grep xdg
(a lot of info before today) 
Jan 04 15:20:32 pete dbus-daemon[3359]: [session uid=1000 pid=3359] Activating via systemd: service name='org.freedesktop.portal.Desktop' unit='xdg-desktop-portal.service' requested by ':1.78' (uid=1000 pid=4143 comm="/usr/lib/firefox/firefox" label="firefox (unconfined)")
Jan 04 15:20:32 pete systemd[3335]: Starting xdg-desktop-portal.service - Portal service...
Jan 04 15:20:32 pete dbus-daemon[3359]: [session uid=1000 pid=3359] Activating via systemd: service name='org.freedesktop.portal.Documents' unit='xdg-document-portal.service' requested by ':1.80' (uid=1000 pid=4194 comm="/usr/libexec/xdg-desktop-portal" label="unconfined")
Jan 04 15:20:32 pete systemd[3335]: Starting xdg-document-portal.service - flatpak document portal service...
Jan 04 15:20:32 pete systemd[3335]: Started xdg-document-portal.service - flatpak document portal service.
Jan 04 15:20:32 pete xdg-document-portal[4200]: Ignoring invalid max threads value 4294967295 > max (100000).
Jan 04 15:20:32 pete dbus-daemon[3359]: [session uid=1000 pid=3359] Activating via systemd: service name='org.freedesktop.impl.portal.desktop.xapp' unit='xdg-desktop-portal-xapp.service' requested by ':1.80' (uid=1000 pid=4194 comm="/usr/libexec/xdg-desktop-portal" label="unconfined")
Jan 04 15:20:32 pete systemd[3335]: Starting xdg-desktop-portal-xapp.service - Portal service (XApp implementation)...
Jan 04 15:20:32 pete dbus-daemon[3359]: [session uid=1000 pid=3359] Activating service name='org.cinnamon.ScreenSaver' requested by ':1.82' (uid=1000 pid=4212 comm="/usr/libexec/xdg-desktop-portal-xapp" label="unconfined")
Jan 04 15:20:32 pete systemd[3335]: Started xdg-desktop-portal-xapp.service - Portal service (XApp implementation).
Jan 04 15:20:32 pete dbus-daemon[3359]: [session uid=1000 pid=3359] Activating via systemd: service name='org.freedesktop.impl.portal.desktop.gtk' unit='xdg-desktop-portal-gtk.service' requested by ':1.80' (uid=1000 pid=4194 comm="/usr/libexec/xdg-desktop-portal" label="unconfined")
Jan 04 15:20:32 pete systemd[3335]: Starting xdg-desktop-portal-gtk.service - Portal service (GTK/GNOME implementation)...
Jan 04 15:20:32 pete systemd[3335]: Started xdg-desktop-portal-gtk.service - Portal service (GTK/GNOME implementation).
Jan 04 15:20:32 pete systemd[3335]: Started xdg-desktop-portal.service - Portal service.

Sorry but SystemD isn’t my daily init and I’m lost with this. Hope my journalctl helps you to check how it differs from yours!

2 Likes

It is possible to do all the traditional logs with syslog and suppress the systemd journal

2 Likes

Here is the method…direct from @daniel.m.tripp

You’re right - it was relatively painless / trivial to replace journalctl with rsyslog / plain text logging :

systemctl stop systemd-journald
systemctl disable systemd-journald
systemctl stop systemd-journald-dev-log.socket
systemctl disable systemd-journald-dev-log.socket

vi /etc/systemd/journald.conf
and change
#Storage=auto
to
Storage=none

Then :

apt install rsyslog
systemctl enable --now rsyslog

Simple

2 Likes

Thank you! I don’t usually use the Mint on my laptop. I just checked the logs from it and noticed the change to journalctl.

2 Likes