Every user is displayed twice at the login screen

I use SDDM with KDE Plasma 5, and in my login screen every user is displayed twice. I’m talking about userland users, not system users.

I’ve also tried to create ex novo a new test user, just to see the outcome, and also this one is displayed twice (so I’m sure that this is nor related to current users’ configuration).

It is more an annoyance than a real issue, but what can be the cause of this? And, can this behavior be prevented?

A strange problem indeed, and one I’ve never seen nor heard of yet.

Maybe the users are listed twice in /etc/passwd?
Just a thought.

I suppose I should look at the sddm source code to see where it takes the users from exactly to be able to provide further suggestions, but that may take some time.

PS: is this a standard local system or are you maybe using something like LDAP?
I’m asking because I found this: https://github.com/sddm/sddm/issues/686

I don’t see this. Updated this afternoon to KDE Plasma5 5.8, but didn’t see it before either.

A question: No remainders left in de /etc/pam.d/* files from experiments to get pam_kwallet working ? :-). I had some issues after editing sddm-greeter

@wolfi323

/etc/passwd correctly lists every user just once.

I’m on a local system, it’s just my daily work laptop; like I said, it just happens at the login screen, not in /etc/passwd, and I can correctly login with both displayed options (I don’t know if I’m clear enough, it seems to be a duplicate display of the same item, not a duplicate item itself).

It happens now with Plasma 5.8 and it happened before with previous versions, and doesn’t seem to affect functionality of the system at all.

@Knurpht

I had modified pam configuration just for helping you on the other thread, then reverted back to standard configuration; so I guess it is not the source of this issue.

:smiley: ROTFL. I jumped in in that thread with a “hey, I don’t need it, but if we serve it it should work” .

My user account is displayed twice also in the SDDM KCM module, in *Startup and Shutdown > Login Screen (SDDM) > Advanced > User

*Some suggestions on how to solve this?

On the system that i clean-installed two days after the official release i had duplicated display icons on kde’s task bar after i changed the display language and adjusted localization to a different than the default. The removal of one of the two icons was not possible.

Edit
I had this issue on Leap 42.2 KDE.I didn’t see that this issue is on Tumbleweed.
I apologize for that. If the moderators think that this post does not belong here please remove it where else
appropriate.

Well, the bigger “problem” is that your post does not seem to be related to this at all (the topic is about duplicated users, you are seeing duplicated task bar items).

So please open a new thread, and I’d suggest to add a screenshot to clarify your problem.

Well, that’s actually unrelated to SDDM though I think, the config module uses KDE’s facilities to get the user accounts IIRC.
Are they listed twice in KDE’s user manager or the login screen too?

If not, I actually do not see a point in trying to fix that at all TBH.
That “User” setting is just to specify which user should Auto-Login, and has absolutely no effect in openSUSE anyway.

Regarding the original problem: I just had a quick look at SDDM’s source code, and it just seems to read the entries from the /etc/passwd file via the standard system functions.
So I don’t really see how a duplication could happen there, unless they are already duplicated in /etc/passwd…

Though according to the getpwent() man page, it may get users from NIS or LDAP as well.
Unfortunately I have absolutely no experience with this, so I have no idea what could be wrong either.

I still have this problem; well, I know that it is not a real problem, but is annoying nonetheless…

Is there some more info that I can provide to help solving this?

Well, I still have no idea how this could happen, so I also don’t know what further info may be helpful.

Just for curiosity: do you see the users twice in YaST->User and Group Management too?

No, there is just a single entry there.

It seems something related to SDDM only.

And thank you again!

Does this command also list the users twice?

getent passwd | sort -n -t ":" -k 3|tail

As I said, sddm just uses normal system functions to get the list of users. (it doesn’t explicitly remove duplicates though according to the bug report I mentioned earlier)

Other things I would try is switch to a different theme (though I don’t think that will help) or displaymanager (e.g. kdm, lightdm).

Yes, that command lists every user twice.

I’ve also tried with kdm and lightdm, they both correctly display every user once; after reverting to sddm, twice again.

This shows at least that the problem is indeed on a lower level.

The only “bug” in sddm is that it doesn’t filter out duplicates.

Maybe they do remove the duplicates then.

The question that still remains is why they are duplicated.
According to “man getent”:

       The  **getent**  command displays entries from databases supported by the
       Name Service Switch libraries,  which  are  configured  in  /etc/nss-
       witch.conf.

Can you post the file /etc/nsswitch.conf please?

Here it is (I have omitted the comments)


passwd: compat [NOTFOUND=return] files
group:  compat [NOTFOUND=return] files

hosts:  files mdns_minimal [NOTFOUND=return] dns
networks:       files dns

services:       files
protocols:      files
rpc:    files
ethers: files
netmasks:       files
netgroup:       files
publickey:      files

bootparams:     files
automount:      files
aliases:        files
shadow: compat


I never even looked at that file before, but I suppose those lines are causing your problem then:


passwd: compat [NOTFOUND=return] files
group:  compat [NOTFOUND=return] files

On my 42.2 system, they look like this:

passwd: compat
group:  compat

Try to change them accordingly, i.e. remove the “files”. I suspect that having “compat” and “files” as source would result in reading /etc/passwd twice or something like that.
Strange though that what you have is actually the default in Tumbleweed. So if that’s the problem, it should happen on every TW system. So there must be something else playing a role here too… :-/