Slow Start Up on Ubuntu 22.04 wXFCE
I have the same issue described here: https://support.mozilla.org/en-US/questions/1387715. However, the accepted solution was not the answer for my situation, since the ownership of the ~/.local/share/ directory was correct on my system.
In my case the slow start-up resulted from the xdg-desktop-portal-gtk service failing to start because of DISPLAY setting issue. This was a difficult issue to debug, since the console wasn't showing timeout errors resulting from Firefox not being able to communicate with the xdg-desktop-portal-gtk service.
My fix was is elegant, but works:
- Edit /usr/lib/systemd/user/xdg-desktop-portal-gtk.service and add the line Environment="DISPLAY=:1.0" under the "[Service]" line.
- sudo systemctl daemon-reload
- systemctl --user restart xdg-desktop-portal-gtk
- To get the service to start correctly every time I start a VNC server, I also added this line (systemctl --user restart xdg-desktop-portal-gtk) to my ~/.vnc/xstartup file
While I think this solution will continue to work, because my DISPLAY is always :1.0 when I use Firefox, I would rather have the xdg-desktop-portal-gtk service figure out the correct DISPLAY setting. Are there any suggestions on how to do that? Or, is there a way to configure Firefox to not rely on this service?