Announcement

Collapse
No announcement yet.

Desktop slow to load

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Desktop slow to load

    Hi,

    After entering my login password I'm getting a long delay before the plasma desktop appears, instead I get to look at a black screen. Normal behaviour on my system was about 20 seconds but now it's more than 1 minute 30 seconds.

    Applications will load using keyboard shortcuts, it's just the desktop (panels, menu etc.) that take so long.

    Here's my output from journatctl -b which shows startup messages after boot, I'm hoping someone might be able to explain what it all means!

    Here the output from a boot process which started at 09:10:50. All seems fairly sensible until 09:11:20 and then it shows the following:

    Code:
    Feb 18 09:11:20 nick-B450-AORUS-PRO org.kde.KScreen[1965]: kscreen.xrandr: Output 87 : connected = true , enabled = true
    Feb 18 09:11:21 nick-B450-AORUS-PRO systemd-timesyncd[885]: Initial synchronization to time server 91.189.94.4:123 (ntp.ubuntu.com).
    Feb 18 09:11:21 nick-B450-AORUS-PRO systemd[1]: systemd-hostnamed.service: Succeeded.
    Feb 18 09:11:21 nick-B450-AORUS-PRO org.kde.KScreen[1965]: kscreen.xrandr: Emitting configChanged()
    Feb 18 09:11:29 nick-B450-AORUS-PRO dbus-daemon[920]: [system] Failed to activate service 'org.bluez': timed out (service_start_timeout=25000ms)
    Feb 18 09:11:29 nick-B450-AORUS-PRO pulseaudio[1528]: GetManagedObjects() failed: org.freedesktop.DBus.Error.TimedOut: Failed to activate service 'org.bluez': timed out (service_start_timeout=25000ms)
    Feb 18 09:11:36 nick-B450-AORUS-PRO PackageKit[1882]: get-updates transaction /3528_deaaedad from uid 1000 finished with success after 320ms
    Feb 18 09:12:16 nick-B450-AORUS-PRO org.freedesktop.Notifications[1932]: org.kde.knotifications: WaitForName: Service was not registered within timeout
    Feb 18 09:12:16 nick-B450-AORUS-PRO dbus-daemon[1530]: [session uid=1000 pid=1530] Activated service 'org.freedesktop.Notifications' failed: Process org.freedesktop.Notifications exited with status 1
    Feb 18 09:12:25 nick-B450-AORUS-PRO nfsidmap[2153]: nss_getpwnam: name 'admin' not found in domain 'localdomain'
    Feb 18 09:12:26 nick-B450-AORUS-PRO systemd[1]: Started Daemon for generating UUIDs.
    Feb 18 09:12:31 nick-B450-AORUS-PRO dbus-daemon[1530]: [session uid=1000 pid=1530] Activating service name='org.kde.KSplash' requested by ':1.30' (uid=1000 pid=1821 comm="/usr/bin/plasmashell " label="unconfined")
    There's an 8 second delay, followed by 7, 30, 9 and 5.

    Any ideas what the culprits are and if I can fix them?

    Thanks

    Nick
    Kubuntu 20.04(AMD64)/KDE 5

    #2
    systemd-analyze
    will give you your boot timings.
    systemd-analyze blame
    will give you a list of services from the longest times down to the shortest.
    systemd-analyze blame > plot.svg
    will dump the blame output into an svg file which you can load with your browser to see a graphical representation of your boot times.

    Here's my systemd-analyze
    Code:
    [FONT=monospace][COLOR=#000000]:[/COLOR][COLOR=#5454ff][B]~[/B][/COLOR][COLOR=#000000]$ systemd-analyze [/COLOR]
    Startup finished in 3.122s (kernel) + 4.295s (userspace) = 7.417s  
    graphical.target reached after 4.283s in userspace[/FONT]
    However, earlier this week an analyze gave me 1m26sec. When I checked with blame it was the fstrim command doing its weekly run on my SSD. My next boot was back to normal, which is shown above.
    "A nation that is afraid to let its people judge the truth and falsehood in an open market is a nation that is afraid of its people.”
    – John F. Kennedy, February 26, 1962.

    Comment


      #3
      @GreyGeek

      Thank you. As I suspected, there is a delay with NFS network mounts, but that still only accounts for 7 seconds. I'll have to do some more digging!
      Kubuntu 20.04(AMD64)/KDE 5

      Comment


        #4
        Wow you have a fast boot time, mine is really slow. I wait for my router/modem to boot and that takes awhile. In general I turn my pc on and then go make a pot of coffee so I don't really care how long it takes.
        Code:
        fred@fred-HP-Laptop-17-bs0xx:~$ systemd-analyze
        Startup finished in 7.643s (firmware) + 5.178s (loader) + 4.088s (kernel) + 2min 25.621s (userspace) = 2min 42.532s 
        graphical.target reached after 34.017s in userspace
        fred@fred-HP-Laptop-17-bs0xx:~$ systemd-analyze blame
        2min 10.266s fstrim.service                                       
            22.773s man-db.service                                       
            17.610s snapd.service                                        
            13.373s networkd-dispatcher.service                          
            12.432s udisks2.service                                      
            10.838s NetworkManager-wait-online.service                   
            10.661s accounts-daemon.service                              
            10.364s dev-sda2.device                                      
             8.527s systemd-journal-flush.service                        
             7.789s polkit.service                                       
             7.117s NetworkManager.service                               
             7.064s avahi-daemon.service                                 
             7.064s bluetooth.service                                    
             6.735s thermald.service                                     
             6.720s wpa_supplicant.service                               
             6.717s systemd-logind.service                               
             6.688s apt-daily.service                                    
             5.776s ModemManager.service                                 
             5.163s bolt.service                                         
             4.666s logrotate.service                                    
             4.610s systemd-resolved.service                             
             3.950s dev-loop3.device                                     
             3.630s gpu-manager.service                                  
             3.626s dev-loop4.device                                     
             3.258s grub-common.service                                  
             3.110s dev-loop1.device                                     
             2.509s secureboot-db.service                                
             2.232s rsyslog.service                                      
             2.118s dev-loop0.device                                     
             2.023s dev-loop5.device                                     
             1.781s user@1000.service                                    
             1.713s lm-sensors.service                                   
             1.539s apport.service                                       
             1.529s dev-loop2.device                                     
             1.456s systemd-tmpfiles-setup.service                       
             1.225s apparmor.service                                     
             1.128s laptop-mode.service                                  
             1.119s e2scrub_reap.service                                 
              855ms systemd-modules-load.service                         
              766ms systemd-udevd.service                                
              762ms systemd-udev-trigger.service                         
              733ms snapd.seeded.service 
              730ms snap-zoom\x2dclient-136.mount                        
              675ms apt-daily-upgrade.service                            
              642ms pppd-dns.service                                     
              596ms keyboard-setup.service                               
              591ms snap-snapd-11107.mount                               
              583ms systemd-tmpfiles-setup-dev.service                   
              573ms upower.service                                       
              550ms systemd-sysusers.service                             
              516ms systemd-random-seed.service                          
              515ms swapfile.swap                                        
              464ms systemd-rfkill.service                               
              452ms snapd.apparmor.service                               
              446ms snap-zoom\x2dclient-134.mount                        
              428ms grub-initrd-fallback.service                         
              411ms systemd-user-sessions.service                        
              398ms snap-core18-1944.mount                               
              393ms snap-core18-1988.mount                               
              375ms alsa-restore.service                                 
              308ms systemd-journald.service                             
              289ms systemd-timesyncd.service                            
              283ms systemd-sysctl.service                               
              239ms sddm.service                                         
              226ms setvtrgb.service                                     
              173ms systemd-remount-fs.service                           
              149ms snap-snapd-11036.mount                               
              144ms systemd-update-utmp.service                          
              139ms systemd-fsck@dev-disk-by\x2duuid-80B2\x2d359D.service
              127ms kerneloops.service                                   
              120ms plymouth-read-write.service                          
              115ms systemd-backlight@backlight:intel_backlight.service  
               97ms dev-hugepages.mount                                  
               97ms dev-mqueue.mount                                     
               96ms sys-kernel-debug.mount                               
               95ms sys-kernel-tracing.mount                             
               68ms kmod-static-nodes.service                            
               63ms motd-news.service                                    
               61ms rtkit-daemon.service                                 
               53ms systemd-tmpfiles-clean.service                       
               52ms hddtemp.service                                      
               51ms ufw.service                                          
               46ms console-setup.service                                
               38ms systemd-update-utmp-runlevel.service                 
               34ms plymouth-quit.service                                
               33ms boot-efi.mount                                       
               22ms user-runtime-dir@1000.service                        
               15ms plymouth-start.service                               
                4ms sys-fs-fuse-connections.mount                        
                3ms sys-kernel-config.mount                              
                1ms lmt-poll.service                                     
              916us snapd.socket

        Comment


          #5
          Thanks to everyone who replied to this. I never did get to the bottom of it, a clean install of 21.04 was the fix. I'd like to have identified the culprit but at least things are back to normal!
          Kubuntu 20.04(AMD64)/KDE 5

          Comment


            #6
            Originally posted by Fred47 View Post
            Wow you have a fast boot time, mine is really slow. I wait for my router/modem to boot and that takes awhile. In general I turn my pc on and then go make a pot of coffee so I don't really care how long it takes.
            Code:
            fred@fred-HP-Laptop-17-bs0xx:~$ systemd-analyze
            Startup finished in 7.643s (firmware) + 5.178s (loader) + 4.088s (kernel) + 2min 25.621s (userspace) = 2min 42.532s 
            graphical.target reached after 34.017s in userspace
            fred@fred-HP-Laptop-17-bs0xx:~$ systemd-analyze blame
            2min 10.266s fstrim.service                                       
                22.773s man-db.service                                       
                17.610s snapd.service                                        
                13.373s networkd-dispatcher.service                          
                12.432s udisks2.service                                      
                10.838s NetworkManager-wait-online.service                   
                10.661s accounts-daemon.service                              
                10.364s dev-sda2.device                                      
                 8.527s systemd-journal-flush.service                        
                 7.789s polkit.service                                       
                 7.117s NetworkManager.service                               
                 7.064s avahi-daemon.service                                 
                 7.064s bluetooth.service                                    
                 6.735s thermald.service                                     
                 6.720s wpa_supplicant.service                               
                 6.717s systemd-logind.service                               
                 6.688s apt-daily.service                                    
                 5.776s ModemManager.service                                 
                 5.163s bolt.service                                         
                 4.666s logrotate.service                                    
                 4.610s systemd-resolved.service                             
                 3.950s dev-loop3.device                                     
                 3.630s gpu-manager.service                                  
                 3.626s dev-loop4.device                                     
                 3.258s grub-common.service                                  
                 3.110s dev-loop1.device                                     
                 2.509s secureboot-db.service                                
                 2.232s rsyslog.service                                      
                 2.118s dev-loop0.device                                     
                 2.023s dev-loop5.device                                     
                 1.781s user@1000.service                                    
                 1.713s lm-sensors.service                                   
                 1.539s apport.service                                       
                 1.529s dev-loop2.device                                     
                 1.456s systemd-tmpfiles-setup.service                       
                 1.225s apparmor.service                                     
                 1.128s laptop-mode.service                                  
                 1.119s e2scrub_reap.service                                 
                  855ms systemd-modules-load.service                         
                  766ms systemd-udevd.service                                
                  762ms systemd-udev-trigger.service                         
                  733ms snapd.seeded.service 
                  730ms snap-zoom\x2dclient-136.mount                        
                  675ms apt-daily-upgrade.service                            
                  642ms pppd-dns.service                                     
                  596ms keyboard-setup.service                               
                  591ms snap-snapd-11107.mount                               
                  583ms systemd-tmpfiles-setup-dev.service                   
                  573ms upower.service                                       
                  550ms systemd-sysusers.service                             
                  516ms systemd-random-seed.service                          
                  515ms swapfile.swap                                        
                  464ms systemd-rfkill.service                               
                  452ms snapd.apparmor.service                               
                  446ms snap-zoom\x2dclient-134.mount                        
                  428ms grub-initrd-fallback.service                         
                  411ms systemd-user-sessions.service                        
                  398ms snap-core18-1944.mount                               
                  393ms snap-core18-1988.mount                               
                  375ms alsa-restore.service                                 
                  308ms systemd-journald.service                             
                  289ms systemd-timesyncd.service                            
                  283ms systemd-sysctl.service                               
                  239ms sddm.service                                         
                  226ms setvtrgb.service                                     
                  173ms systemd-remount-fs.service                           
                  149ms snap-snapd-11036.mount                               
                  144ms systemd-update-utmp.service                          
                  139ms systemd-fsck@dev-disk-by\x2duuid-80B2\x2d359D.service
                  127ms kerneloops.service                                   
                  120ms plymouth-read-write.service                          
                  115ms systemd-backlight@backlight:intel_backlight.service  
                   97ms dev-hugepages.mount                                  
                   97ms dev-mqueue.mount                                     
                   96ms sys-kernel-debug.mount                               
                   95ms sys-kernel-tracing.mount                             
                   68ms kmod-static-nodes.service                            
                   63ms motd-news.service                                    
                   61ms rtkit-daemon.service                                 
                   53ms systemd-tmpfiles-clean.service                       
                   52ms hddtemp.service                                      
                   51ms ufw.service                                          
                   46ms console-setup.service                                
                   38ms systemd-update-utmp-runlevel.service                 
                   34ms plymouth-quit.service                                
                   33ms boot-efi.mount                                       
                   22ms user-runtime-dir@1000.service                        
                   15ms plymouth-start.service                               
                    4ms sys-fs-fuse-connections.mount                        
                    3ms sys-kernel-config.mount                              
                    1ms lmt-poll.service                                     
                  916us snapd.socket
            I got rid of snapd (which, IMO, is mainly a "telemetry" tool :wink :wink ), and the chromium browser because they are joined at the hip. Once I disabled snapd I masked it. Then I uninstalled it and chromium.

            The man.db.service probably doesn't run at every bootup, BUT, if there is a service that does and it is slowing your boot times, you can set a timer for it so that it runs after a certain amount of time after boot up has past. The process is described here.
            "A nation that is afraid to let its people judge the truth and falsehood in an open market is a nation that is afraid of its people.”
            – John F. Kennedy, February 26, 1962.

            Comment

            Working...
            X