KDE session default per user

Can you please give me some basic idea to where to start from with this?
On a computer running Debian there are -say- 2 users registered.
UserA, and UserB.
The desktop is KDE.
I want to set the default session type for UserA to Wayland, but for UserB to X11.

(I have a good reason to do so :slight_smile: )

Now when UserA needs Wayland, sets type to it, the next time when UserB logs in, if she doesn’t do care for the session type, it will be Wayland, since UserA left it so last time…

So do you know some trick to set default session type for individual users?
If UserB is always forced to X11, that’s acceptable too.

Thanks in advance!

2 Likes

I think it would have to be set in the login managers configuration file(s), because nothing
else is looked at before the session starts. I think .profile would be too late.

As to what variable to set, I have no idea, but I would start looking at what is set when you
choose X or Wayland on the login screen.
I did note that in Antix, you are forced to type the login name and password, before it will let you choose the window manager. That means there is some hope

3 Likes

Hi László,
are you using LightDM?

Jorge

Could you install the system twice on the hard disk so at grub boot the user chooses entry one or entry 2.

Not tried this as to having two versions side by side.

At install does it ask overwrite or put another copy alongside ?
Mint does this at install

@kovacslt wants 2 users on the one running system to differ.
“I want to set the default session type for UserA to Wayland, but for UserB to X11.”

I think he could do it in the S6 init system, because the 66 service manager allows users to start their own services… so user A could start Wayland server and use B could start Xorg server. I dont know if they would clash?
I dont know if any other init system allows user services?

Thanks for all your ideas!
Meanwhile I made a drastic decision… :slight_smile:

SDDM, as this is with KDE.

That could work, but requires a reboot on all user change.

I have no idea either.

Actually there are more users (5), but for simplicity I mentioned only 2.

And now let please tell about the root of the problem: nVidia.

Sadly I need Wayland. Wayland on nVidia (with proprietary driver) is less stable under Gnome, but kind of usable. Sadly, I cannot get used to Gnome.
KDE is great however!
KDE+Wayland on nVidia is a …@&%!%+!&@…
For a couple weeks I thought I can live with that instability, so I was thinking about logging in the users on my desktop to an X11 session, and only I want to specifically start a Wayland session.
If I ever login to Wayland, SDDM keeps it offerin as default for other users too.
My wife cannot bear tha buggy behavior of nVidia+Wayland, nor is she able to have a look at what session she is about to start…
Not speaking about the kids… :slight_smile:

Day after day I was more and more fed up with nVidia+Wayland, so I sold the GTX1080 Ti, and bought a Radeon RX 6600 Xt.

I needed some ugly dirty hacks to make it work in Debian 12 with rocm 5.7.2, so Davinci accepts it as a GPU at all…
I’m in no way proud of those “hacks”, it’s kind of disgusting, so wouldn’t like to tell about it in detail, but at least it works.

Guess, there’s no problem with Wayland now, so the original problem got a workaround: changed the video card :smiley:

Regarding performance, I get the same experience while editing, but when rendering from Davinci, the RX6600 XT is capable of computing 150…180 FPS while the 1080Ti could do it about a speed of 220…280 FPS.

For me anything above 2x times faster than realtime is acceptable, so 150 FPS is 3x times faster than the 50p project so that’s OK for now.
At the end there’s no reason now to keep X11 for my other users, so they get Wayland too.
Thank you all for thinking with me!

2 Likes

Think this was way beyond my understanding of the system … graphics cards always cause me issues, normally I strip them from towers and use the built in graphics capability of the mother board but dont play games or do hard cad type graphics so dont need them

1 Like

Congratulations on your solution.
I dont get this… you have multiple users, all using graphics…only one can use the console… do the others have network access from another computer?.. if they login with ssh the graphics is driven by their own computer?.. that cant be it, what are you doing? It sounds interesting.

2 Likes

Hi @nevj , looks like I need to explain a bit more about it.

There are couple computers in our home network.
I have 3 kids, they have i3 8100 based computers 8GB RAM, integrated graphics, running Debian 12 Cinnamon.
My oldest son has a laptop too, Aspire A314, it runs Debian 11 MATE (it is a weak laptop celeron N4000 or something similar, 4GB RAM).
My wife has her laptop, Thinkpad L380, i5 8250u 16GB with integrated graphics, runs on Debian 12 Cinnamon.
I have my laptop, Dell G3, i5 8300h 16GB RAM, with integrated but has nVidia 1050 as a secondary graphics, this runs Debian 12 KDE.
There’s the home server, the Odroid HC4, it runs Debian 11 it’s headless without any GUI, has a Samsung made ARM CPU (Exynos maybe) and 4GB RAM.
There’s the RPi3B+ in the living room.
I have a backup server, it’s a i5 4500T, 8GB RAM, runs Debian 11 without GUI (it’s headless too, just switches on every day at 3:00 AM, rsyncs data from the home server).
And of course my desktop, which is the most powerful computer in the family:
i7 8700, 16GB RAM, runs Debian 12 KDE.
This has 2 monitors attached.

So these are the gadgets :slight_smile:

The laptops are kind of personal.
The kids use their own machines for whatever they need it for. School related things, but yes, there are games too. Especially during the covid lockdown was important to have all their own.
These computers have 4 users, an admin (I am that :smiley: ), and all 3 kids could login to any of those, wait some minutes until Seafile client synchronizes their data there, and can do whatever could do on the other machine.
This is just for "just in case’, if a kids own computer would break, could go on with his work(?) on the other one. A theoretical possibility, not really used.
My wife used to do her homeoffice mainly on her laptop. But very often she needs my dual monitor setup, because she can have there multiple spreadsheets open, and have a better overview at the same time.
All kids also have theoretical possibility to login on the desktop. My oldest son sometimes (rarely) really logs in, for the benefit of 2 monitors, and more computational power.

So I have 5 users on that desktop, my family mebers, including me. Only I am deep diving Linux, the others are “just” users, not really interested in how things work.

I want to keep this ecosystem up and running so that they can do their jobs anytime, and also to my own pleisure.

Wayland+KDE+nVidia is kind of broken, and that affected the functionality in the wrong way.

I was not able to solve the problem just editing config files, so I changed my mind, sold the nVidia, and bought the Radeon for my desktop.

Does this make it more clear?

3 Likes

Hi László,
Thanks for your response.

I have Manjaro on my laptop (SDDM and KDE) and I’ve been testing, but so far, the only solution I’ve found is that SDDM saves the last session chosen during login.


If you open a terminal window and type the command sddm --example-config, you can see that there is a General section:

[General]
# Which display server should be used.
# Valid values are: x11, x11-user, wayland. Wayland support is experimental
DisplayServer=x11

and there is a Users section too:

[Users]
# Default $PATH for logged in users
DefaultPath=/usr/local/bin:/usr/bin:/bin

I can’t find a solution to customize the display server for each user.
I’m sorry, but I haven’t been able to go any further in this matter.

Jorge

3 Likes

Thanks @Tech_JA, I appreciate your effort!

As I dropped nvidia, the original question lost its practical importance.
Still it would be interesting to find something, as saying “impossible” sounds so cruel in Linux world :slight_smile:

3 Likes

Hello Laszlo,
Very clear, and interesting too,
I get it now, it is only when other family members sit at the main computer console
that this issue with Wayland arises… I was thinking remote logins.

You have solved it with hardware … nice, I like AMD graphics cards… despite the issue I had a while back with a new card.

It must be a challenge keeping that collection maintained.

Regards
Neville

3 Likes

It’s actually quite easy as Debian does it for me automatically.
Well, not out of the box, I have my script, that does it.

I need to intervene manually only when upgrading between distros,
say moving from Debian 11 to 12.
Or if something gets smashed, that’s a theoretical possibility, mainly for hardware faults.
I can’t remember Debian ever got screwed up without my clumsy poking, but that doesn’t mean of course it will never do it :slight_smile:

The system is updated totally-fully-automatically on all our computers (servers are different story), but in a more polite way than Windows does that.
I crafted a script that does it.
Users are notified (via notify-send), when an update begins, and when it’s finished.
Whenever something (maybe the whole system) needs to be restarted, the script politely asks for doing that in a convenient time, but does not force anything.
To gather information about what needs to ber restarted, it uses needrestart.
Before the actual update, systemback is called to make a snapshot of the current state, so if anythin would go wrong, there’s the possibility to easily roll-back.
The updater script is launched by a systemd timer every day at near 19:10.

I linked here the Lego bricks, all I did was just scripting the mortar between them :slight_smile:
I must admit, I enjoy a lot to keep it running.

3 Likes