This forum has been archived. All content is frozen. Please use KDE Discuss instead.

slow computer after login

Tags: None
(comma "," separated)
User avatar
alainroger
Registered Member
Posts
159
Karma
0
OS

slow computer after login

Sat Nov 27, 2021 4:22 pm
Hi,

I run Ubuntu 21.04 with KDE 5.22.5.
Computer boots quite fast but when it's about user session it's very slow once I type my user password (about 1m30), while several months ago it was about 10s.
I checked with command line "systemd-analyze" and here is the result:
Code: Select all
Startup finished in 3.271s (kernel) + 7.852s (userspace) = 11.124s 
graphical.target reached after 7.846s in userspace


When I run "systemd-analyze critical-chain", it returns:
Code: Select all
The time when unit became active or started is printed after the "@" character.
The time the unit took to start is printed after the "+" character.

graphical.target @7.846s
└─multi-user.target @7.846s
  └─teamviewerd.service @7.766s +79ms
    └─network-online.target @7.762s
      └─NetworkManager-wait-online.service @4.362s +3.399s
        └─NetworkManager.service @4.133s +227ms
          └─dbus.service @4.130s
            └─dbus.socket @4.119s
              └─basic.target @4.119s
                └─sockets.target @4.119s
                  └─snapd.socket @4.118s +898us
                    └─sysinit.target @4.112s
                      └─systemd-timesyncd.service @4.015s +96ms
                        └─systemd-tmpfiles-setup.service @3.883s +125ms
                          └─local-fs.target @3.876s
                            └─home.mount @3.785s +90ms
                              └─dev-sdb1.device @3.784s


But times written are far from what I experience each time I log into system.

When I edited my /etc/systemd/system.conf and uncomment the following lines:
Code: Select all
#DefaultTimeoutStartSec=90s
#DefaultTimeoutStopSec=90s


and write:
Code: Select all
#DefaultTimeoutStartSec=10s
#DefaultTimeoutStopSec=10s


It seems that nothing changed.


Kubuntu 22.04 / kernel 5.15.x
KDE 5.24.5 / KDE framework: 5.95 / Qt version: 5.15.3
User avatar
Mamarok
Manager
Posts
6071
Karma
16
OS

Re: slow computer after login

Sun Nov 28, 2021 3:20 am
Do you have enough free space on your home and / partition?


Running Kubuntu 22.10 with Plasma 5.26.3, Frameworks 5.100.0, Qt 5.15.6, kernel 5.19.0-23 on Ryzen 5 4600H, AMD Renoir, X11
FWIW: it's always useful to state the exact Plasma version (+ distribution) when asking questions, makes it easier to help ...
User avatar
alainroger
Registered Member
Posts
159
Karma
0
OS

Re: slow computer after login

Sun Nov 28, 2021 11:53 am
Yes, I still have 50 GB free on SSD /Home and more than 383 GB free on / partition


Kubuntu 22.04 / kernel 5.15.x
KDE 5.24.5 / KDE framework: 5.95 / Qt version: 5.15.3
User avatar
Mamarok
Manager
Posts
6071
Karma
16
OS

Re: slow computer after login

Sun Nov 28, 2021 6:25 pm
You probably run something on startup that slows down the login. A few ideas that could cause this are an attempt to load remote files, a graphic driver that can't be loaded correctly, some third-party software that slows down the login, a problem with HDMI audio loading, etc.
Make a new user and check the difference in time, if there is none then the problem is not in your user space but probably in the graphic stack


Running Kubuntu 22.10 with Plasma 5.26.3, Frameworks 5.100.0, Qt 5.15.6, kernel 5.19.0-23 on Ryzen 5 4600H, AMD Renoir, X11
FWIW: it's always useful to state the exact Plasma version (+ distribution) when asking questions, makes it easier to help ...
User avatar
alainroger
Registered Member
Posts
159
Karma
0
OS

Re: slow computer after login

Wed Dec 01, 2021 4:34 pm
The only thing I have it's 2 monitors for game development.


Kubuntu 22.04 / kernel 5.15.x
KDE 5.24.5 / KDE framework: 5.95 / Qt version: 5.15.3
User avatar
alainroger
Registered Member
Posts
159
Karma
0
OS

Re: slow computer after login

Fri Dec 03, 2021 8:30 am
Ok so after analyzing logs I discovered 3 weird messages:

first one is about pulse audio and it's notified as error:
Code: Select all
03/12/2021 09:17   pulseaudio   Sink 'alsa_output.pci-0000_00_1b.0.analog-stereo' does not exist.
03/12/2021 09:17   pulseaudio   Source 'alsa_input.usb-041e_Live__Cam_Connect_HD_1080_VF0760-02.analog-stereo' does not exist.


and the next one is about missing data miner (error):
Code: Select all
03/12/2021 09:14   systemd   Failed to start Tracker file system data miner.


i did a reset of tracker typing:
Code: Select all
tracker reset -e


regarding pulseaudio, when I type: pactl list sinks | grep "Name:"
I only have 1 sink:
Code: Select all
Name: alsa_output.pci-0000_00_1b.0.analog-stereo


But I'm sure that my slow issue (3 minutes from login to taskbar display) is due to my profile as I have a test profile and it starts (from login to taskbar display) in less than 11s.

I installed driver NVidia delivered by ubuntu v470 instead of propiertary 460 and now my computer is faster by 1 minute, so I still have a 2 minutes time gap between login and taskbar display.


Kubuntu 22.04 / kernel 5.15.x
KDE 5.24.5 / KDE framework: 5.95 / Qt version: 5.15.3
User avatar
Mamarok
Manager
Posts
6071
Karma
16
OS

Re: slow computer after login

Fri Dec 03, 2021 11:01 am
Is the test profile new or has it been used before? An entirely new user is the best way to check if the problem is in user space.

FWIW: lack of space on the / and /home partitions can also result in slow startups


Running Kubuntu 22.10 with Plasma 5.26.3, Frameworks 5.100.0, Qt 5.15.6, kernel 5.19.0-23 on Ryzen 5 4600H, AMD Renoir, X11
FWIW: it's always useful to state the exact Plasma version (+ distribution) when asking questions, makes it easier to help ...
User avatar
alainroger
Registered Member
Posts
159
Karma
0
OS

Re: slow computer after login

Fri Dec 03, 2021 2:22 pm
Test profile is new...I just created it this morning.
It is just a simple user profile created and to be able to log in.

So just by log in into system it takes less than 11s while on my personal profile it takes 2-3min.
As I wrote previously, on / partition there is almost 383Gb free and on /home partition (different HDD) there is more than 50 Gb free, so I do not think this is the issue, as it would also be present on different user profile.

I'm not satisfied how KsystemLog app display issues (errors and warning) as filter is not working well and color are not respected.... :(

Even if i reset data miner/tracker I still have error in log with it:
Code: Select all
Failed to start Tracker file system data miner.


Just for fun I decided to upgrade to Kubuntu 21.10 and so far nothing has changed.


Kubuntu 22.04 / kernel 5.15.x
KDE 5.24.5 / KDE framework: 5.95 / Qt version: 5.15.3
User avatar
alainroger
Registered Member
Posts
159
Karma
0
OS

Re: slow computer after login

Sat Dec 04, 2021 12:50 pm
Today I decided to try to remove the tracker to check if it has some effect on that time desktop needs to display fully itself.

so I typed:
Code: Select all
sudo apt remove tracker tracker-extract tracker-miner-fs

and I rebooted.

So I checked several times by restarting computer and Ubuntu now needs 30-40 s to fully display KDE desktop. So for an unknow reason tracker slow my computer. Maybe it would be great to postpond the start of such service to 5min after login, as some GNOME app do not work without such service.


Kubuntu 22.04 / kernel 5.15.x
KDE 5.24.5 / KDE framework: 5.95 / Qt version: 5.15.3
User avatar
claydoh
Registered Member
Posts
1170
Karma
9
OS

Re: slow computer after login

Sat Dec 04, 2021 2:35 pm
If you are on a KDE desktop, why would you be running a Gnome-specific file indexer, anyway?
Maybe turn of KDE's search indexer, and see if it helps? Multiple redundant indexing services might contribute to the slow desktop loading. Though of course you lose the search features in Dolphin.

Maybe check what Tracker is set to index, maybe reducing the number of locations?
Tracker is not designed to index directories of source code or video game data. If content like this appears in the locations it is configured to index then you might see unwanted high resource usage.

In any case, configuring the startup for Gnome's tracker is unrelated to KDE, or Kubuntu.


claydoh, proud to be a member of KDE forums since 2008-Oct, and KDE user since 2001
User avatar
alainroger
Registered Member
Posts
159
Karma
0
OS

Re: slow computer after login

Sat Dec 04, 2021 3:02 pm
I did not install Gnome indexer, it seems that some Gnome app install it as part of them.
I already for 1 year now, do not have KDE search indexer activated. I checked and it is disabled still, so no problem from this side.
Disable Tracker was 1 point of my issue.



claydoh wrote:If you are on a KDE desktop, why would you be running a Gnome-specific file indexer, anyway?
Maybe turn of KDE's search indexer, and see if it helps? Multiple redundant indexing services might contribute to the slow desktop loading. Though of course you lose the search features in Dolphin.

Maybe check what Tracker is set to index, maybe reducing the number of locations?
Tracker is not designed to index directories of source code or video game data. If content like this appears in the locations it is configured to index then you might see unwanted high resource usage.

In any case, configuring the startup for Gnome's tracker is unrelated to KDE, or Kubuntu.


Kubuntu 22.04 / kernel 5.15.x
KDE 5.24.5 / KDE framework: 5.95 / Qt version: 5.15.3
User avatar
alainroger
Registered Member
Posts
159
Karma
0
OS

Re: slow computer after login

Mon Dec 06, 2021 10:19 am
Today, I checked my logs after disabling autoFS and I noticed that some services take too much time to execute (from my point of view).

Here is a log extract:
Code: Select all
déc. 06 09:23:42 PC0001 systemd[1800]: Starting Evolution address book service...
déc. 06 09:23:42 PC0001 dbus-daemon[1814]: [session uid=1000 pid=1814] Successfully activated service 'org.gnome.evolution.dataserver.AddressBook10'
déc. 06 09:23:42 PC0001 systemd[1800]: Started Evolution address book service.

déc. 06 09:23:47 PC0001 NetworkManager[1289]: <info>  [1638779027.3439] manager: NetworkManager state is now CONNECTED_GLOBAL
déc. 06 09:23:47 PC0001 dbus-daemon[1288]: [system] Activating via systemd: service name='org.freedesktop.nm_dispatcher' unit='dbus-org.freedesktop.nm-dispatcher.service' requested by ':1.11' (uid=0 pid=1289 comm="/usr/sbin/NetworkManager --no-daemon " label="unconfined")
déc. 06 09:23:47 PC0001 whoopsie[1677]: [09:23:47] The default IPv4 route is: /org/freedesktop/NetworkManager/ActiveConnection/1
déc. 06 09:23:47 PC0001 systemd[1]: Starting Network Manager Script Dispatcher Service...
déc. 06 09:23:47 PC0001 whoopsie[1677]: [09:23:47] Not a paid data plan: /org/freedesktop/NetworkManager/ActiveConnection/1
déc. 06 09:23:47 PC0001 whoopsie[1677]: [09:23:47] Found usable connection: /org/freedesktop/NetworkManager/ActiveConnection/1
déc. 06 09:23:47 PC0001 dbus-daemon[1288]: [system] Successfully activated service 'org.freedesktop.nm_dispatcher'
déc. 06 09:23:47 PC0001 systemd[1]: Started Network Manager Script Dispatcher Service.
déc. 06 09:23:48 PC0001 whoopsie[1677]: [09:23:48] online

déc. 06 09:23:57 PC0001 systemd[1]: NetworkManager-dispatcher.service: Deactivated successfully.
déc. 06 09:23:59 PC0001 PackageKit[2110]: get-updates transaction /2381_badbaace from uid 1000 finished with success after 464ms

déc. 06 09:24:20 PC0001 systemd[1800]: Starting Sound Service...
déc. 06 09:24:20 PC0001 systemd[1]: Starting Discard unused blocks on filesystems from /etc/fstab...



I would like to understand why there is a so huge gap between 2 line of logs.

Here the gap is 5s:
Code: Select all
déc. 06 09:23:42 PC0001 systemd[1800]: Started Evolution address book service.

déc. 06 09:23:47 PC0001 NetworkManager[1289]: <info>  [1638779027.3439] manager: NetworkManager state is now CONNECTED_GLOBAL


Here the gap is 9s:
Code: Select all
déc. 06 09:23:48 PC0001 whoopsie[1677]: [09:23:48] online

déc. 06 09:23:57 PC0001 systemd[1]: NetworkManager-dispatcher.service: Deactivated successfully.


Am I too much demanding or is it normal such gap ?

I have stomach feeling that NetworkManager is not working so great under the latest update.

thx


Kubuntu 22.04 / kernel 5.15.x
KDE 5.24.5 / KDE framework: 5.95 / Qt version: 5.15.3


Bookmarks



Who is online

Registered users: Bing [Bot], blue_bullet, Google [Bot], rockscient, Yahoo [Bot]