Hi, I just want to post this thread in the event this helps somebody else when they google for the same issue.
I also wanted to report it in the OpenSuse bugzilla, but I found it impossible to create an account (I only find a login option, not register?), so perhaps somebody else can verify this and eventually open a bug.
**
Background**:
a few days ago I installed OpenSuse for the first time (coming from other distros), so I had my first discovery of Yast.
Not being an expert on all those configurations, one of the things I disliked was that my PC hostname is localhost.localdomain, so I wanted to change it if it was easy. I opened the Hostnames configuration in Yast, I probably opened the Edit window of 127.0.0.1, had the feeling that I didn’t really know what I was doing, so I believe I closed it without changing anything (perhaps clicking OK?). I am not 100% sure of the actions I performed in the last sentence, but going by memory that’s what I did. Anyway, I didn’t think much of this since I believed that nothing was changed.
Issue:
since yesterday I noticed that suddenly opening any application was taking 5-10 seconds. For example Konsole, Kcalc, Dolphin, or Kate. Restarting or updating the system did not help. This issue was not there the day before (when the distro was installed).
Analysis:
Checking the journald log I noticed that this error was recurring when launching any application: Qt: Session management error: Could not open network socket
I googled for a while and I couldn’t find much, until I came on the following reddit thread: https://www.reddit.com/r/openSUSE/comments/hxgort/programs_slow_to_launch_on_fresh_install_of/
Then I remembered that I had checked the Hostnames menu in Yast, so I looked whether something was wrong there.
Previously I had also launched the command hostnamectl and saw this line in the output: Transient hostname: localhost.localdomain
In Yast I found that for address 127.0.0.1 the hostname was just: localhost
So I tried changing it to: localhost.localdomain As soon as that was saved, opening any applications was back to normal and the issue was solved.
**
Possible Yast issue:
Is it possible that Yast changed the configured hostname without any actual change from me, apart from clicking the OK button in the edit window?
I have seen similar issues in other software: just opening an edit window loads some preconfigured string which is different from the actual value, and if you click OK it gets saved.
Can somebody try this on a fresh installation or any installation where the Hostnames menu in Yast was never opened?
The account and password that you used to login to this forum should work.
Issue:
since yesterday I noticed that suddenly opening any application was taking 5-10 seconds. For example Konsole, Kcalc, Dolphin, or Kate. Restarting or updating the system did not help. This issue was not there the day before (when the distro was installed).
When that happens, try running “top” at a terminal (konsole). There might be a looping process that is eating up much of the processor time.
localhost:~ # ll /etc/hosts
** -rw-r--r-- 1 root root 684 Aug 6 08:06 /etc/hosts**
localhost:~ # cat /etc/hosts
#
# hosts This file describes a number of hostname-to-address
# mappings for the TCP/IP subsystem. It is mostly
# used at boot time, when no name servers are running.
# On small systems, this file can be used instead of a
# "named" name server.
# Syntax:
#
# IP-Address Full-Qualified-Hostname Short-Hostname
#
127.0.0.1 localhost
# special IPv6 addresses
::1 localhost ipv6-localhost ipv6-loopback
fe00::0 ipv6-localnet
ff00::0 ipv6-mcastprefix
ff02::1 ipv6-allnodes
ff02::2 ipv6-allrouters
ff02::3 ipv6-allhosts
192.168.178.2 erlangen.fritz.box erlangen
localhost:~ #
All applications startup without noticeable delay.