You are not logged in.
Hello,
like the subject says: Whenever I start Firefox, it takes literally more than half a minute to start up. Here's what I tried, all without success:
- Delete cache/data
- Create a new user on same system to start with a completely clean slate
- Unmount all NFS drives
- Close and immediately restart Firefox (second time takes just as long as first)
Nothing makes the slightest bit of diference. The rest of the system runs fine, also other large and slowish apps (Gimp, KDEnlive, Digikam) don't show any similar symptoms
Of course I don't know which activity coincides with the onset of the problem. It's one of those things that needs to happen a few times to start to annoy you, and by that time you don't remember what I did before. At least I don't.
Last edited by musbur (2022-04-11 15:59:23)
Offline
It sounds vaguely like firefox cannot reach some network resources.
Do you have a dual stack IPv4/IPv6 environment? Check if all servers are also reachable via IPv6.
Do you have a DNS or URL filter (DNS black hole, router blacklist etc.)? Does it block access to firefox' "internal" network?
Offline
There was https://bbs.archlinux.org/viewtopic.php … 0#p2030390 and "30 seconds" is suspiciously close to the 25s dbus timeout (repo FF or a flatpak?)
You could also strace firefox to see where it hangs.
Offline
There was https://bbs.archlinux.org/viewtopic.php … 0#p2030390 and "30 seconds" is suspiciously close to the 25s dbus timeout (repo FF or a flatpak?)
You could also strace firefox to see where it hangs.
Yeah, I already thought of that, too. Turns out that the startup hangs at a poll() system call that times out after 25 seconds. I found that starting up evince takes 50 seconds to start because it does the same call twice. Maybe this gives some insight:
~$ strace evince > strace_evince 2>&1
~$ egrep '= 11|poll.*fd=11' strace_evince
[...]
eventfd2(0, EFD_CLOEXEC|EFD_NONBLOCK) = 11
poll([{fd=11, events=POLLIN}], 1, 25000) = 1 ([{fd=11, revents=POLLIN}])
poll([{fd=11, events=POLLIN}], 1, 25000) = 0 (Timeout)
eventfd2(0, EFD_CLOEXEC|EFD_NONBLOCK) = 11
poll([{fd=11, events=POLLIN}], 1, 25000) = 1 ([{fd=11, revents=POLLIN}])
poll([{fd=11, events=POLLIN}], 1, 25000) = 0 (Timeout)
[...]
One whole "usage cycle" of such a file descriptor created by eventfd2 looks like this:
eventfd2(0, EFD_CLOEXEC|EFD_NONBLOCK) = 11
write(11, "\1\0\0\0\0\0\0\0", 8) = 8
write(10, "\1\0\0\0\0\0\0\0", 8) = 8
futex(0x56288ba9c030, FUTEX_WAKE_PRIVATE, 1) = 1
futex(0x56288bae3170, FUTEX_WAKE_PRIVATE, 1) = 1
futex(0x56288ba951d8, FUTEX_WAKE_PRIVATE, 1) = 1
poll([{fd=11, events=POLLIN}], 1, 25000) = 1 ([{fd=11, revents=POLLIN}])
read(11, "\1\0\0\0\0\0\0\0", 16) = 8
poll([{fd=11, events=POLLIN}], 1, 25000) = 0 (Timeout)
write(11, "\1\0\0\0\0\0\0\0", 8) = 8
futex(0x56288bb65720, FUTEX_WAKE_PRIVATE, 2147483647) = 0
close(11) = 0
Does this make sense to anybody?
Offline
It sounds vaguely like firefox cannot reach some network resources.
Do you have a dual stack IPv4/IPv6 environment? Check if all servers are also reachable via IPv6.
Do you have a DNS or URL filter (DNS black hole, router blacklist etc.)? Does it block access to firefox' "internal" network?
It doesn't seem to be limited to firefox. Evince (PDF viewer) even takes 50 seconds, see my other answer in this thread.
Offline
25 seconds is the default dbus timeout.
How are you starting your session?
Can you post the output of...
loginctl
Offline
I'm using dwm without a graphical login. The session is started by .xsession. There's nothing funny in my startup; in fact when I create a completely "blank" user with an empty home dir and do "sx firefox" it does the same thing.
~$ loginctl
SESSION UID USER SEAT TTY
1 1000 dh seat0 tty1
1 sessions listed.
Last edited by musbur (2022-04-10 18:53:05)
Offline
So you aren't launching the required dbus session then. Read...
https://wiki.archlinux.org/title/Xinit
Offline
So you aren't launching the required dbus session then. Read...
https://wiki.archlinux.org/title/Xinit
Yup, that did it. I installed xinit which gave me startx. When I replaced "sx" with "startx" in my .zprofile, everything worked fine. Thanks a lot!
BUT.... why did it work before? Just a few weeks ago I had something where I ran Evince all the time and it started up without delay.
Offline
You can use dbus-monitor to track what service is being called by those programs on startup.
But having a broken session is never good and has more implications (w/o the active session you can't shut down the system as regular user, you have insufficient permissions on some devices etcetc.)
To be sure, please post the updated output of "loginctl session-status" and see the last link below (because whether sx or startx - /etc/X11/xinit/xinitrc.d/50-systemd-user.sh is what logind-activates your session)
Offline