0

I've got a weird problem and am not sure how to google for it, or investigate the issuse. Generally my Ubuntu 23.10 behaves normally. However, after login it takes ages (so.. half a minute) to open a terminal. Some other programs work faster.

I tried to clean a few things from ~/.cache and and i deactivated all "startup applications" - no change

Also, i have a script i want to start via desktop file in the startup applications. It doesn't start. I can call it from dash, but it wont start automatically.

My startup seems slow, but I don't think this problem is related to it. It's not a huge issue, but my curiosity is triggered to dig into the problem. Any ideas what I could look for?

systemd-analyze gives:

Startup finished in 4.376s (firmware) + 7.347s (loader) + 5.398s (kernel) + 1min 30.689s (userspace) = 1min 47.811s 
graphical.target reached after 34.630s in userspace.

systemd-analyze blame gives:
6min 23.636s dev-loop3.device
6min 23.589s dev-loop4.device
6min 23.582s dev-loop6.device
6min 23.569s dev-loop2.device
6min 23.564s dev-loop5.device
6min 23.541s dev-loop7.device
6min 23.495s dev-loop1.device
6min 23.462s dev-loop0.device
36.335s snapd.service
15.389s dev-loop24.device
9.220s plymouth-quit-wait.service
5.336s NetworkManager-wait-online.service
3.486s fwupd-refresh.service
3.070s logrotate.service
2.510s apt-daily-upgrade.service
1.790s fwupd.service
1.213s postfix@-.service
922ms NetworkManager.service
896ms dpkg-db-backup.service
892ms udisks2.service
811ms apport.service
723ms polkit.service
718ms power-profiles-daemon.service
714ms dev-sda5.device
653ms accounts-daemon.service
578ms avahi-daemon.service
576ms bluetooth.service
574ms networkd-dispatcher.service
510ms cups.service
502ms gpu-manager.service

Gunter
  • 3
  • If this is about the prompt after the terminal window opens, see my https://askubuntu.com/a/1500576/1004020 . If it's about the terminal window itself, you could do a strace or fatrace over SSH – Daniel T Feb 18 '24 at 00:59
  • Post the results of systemd-analyze blame instead. – WinEunuuchs2Unix Feb 18 '24 at 02:09
  • BTW I just noticed my biggest boot time consumer is fwupd.service which isn't even necessary and I will deactivate soon. However, I only reboot once a month or so (typical operation is to suspend/resume two to three times over 24 hours). – WinEunuuchs2Unix Feb 18 '24 at 02:34
  • edited above ... hm, not sure how to read it.. seems some stuff is taking really long, but i ran the command a while after boot; @Daniel T - Termin window itself; ... sorry, but I am afraid I need more info on strace of fatrace over SSH? at which point? after boot? over SSH from another computer? – Gunter Feb 28 '24 at 19:55
  • I think it's just that your hard disk is slow. Try e4defrag – Daniel T Feb 28 '24 at 20:21
  • uhm, thanks, didn't know defrag is still a thing with SSDs - and no: Fragmentation score 4 [0-30 no problem: 31-55 a little bit fragmented: 56- needs defrag] This device (/dev/sda5) does not need defragmentation. Oh, and it seems to be mostly my terminal - the rest of the program starts halfway normal speed :-/ – Gunter Mar 01 '24 at 19:34
  • What's left to try might be moving ~/.bashrc and ~/.profile away or creating a new user account, or removing/disabling snapd – Daniel T Mar 01 '24 at 19:36
  • I analyzed a bit more... it really is only the terminal; moving away bashrc and profile didn't do anything, good idea though. Is there a way to disable snapd and get it back without changes (several of my programs run over snap)... I am more looking for an analysis tool that tells me what is happening when i click "terminal" an nothing happens for some time. I'd usually start the program I want to analyse via terminal, but... :-D – Gunter Mar 09 '24 at 10:32

0 Answers0