Yes. You started a standard new user session.
But that’s what you asked.
How to create a new session via some command.
Apparently what you asked is not what you want though.
However, there is a worse problem, namely: after john’s KDE session is started and joe then logs in as john and runs dolphin as john in joe’s KDE session, if john’s KDE session is then shutdown and restarted, then both joe’s and john’s KDE sessions will collide. The only way to prevent that is for joe to logout of his KDE session and log back in.
No, they don’t collide.
Why do you think that?
And I think you misunderstood something.
If you run “kdmctl reserve”, you create a completely independent user session.
I.e. user john logs in, it’s not user joe that logs in as user john.
Linux is a multi-user system, it is perfectly possible to have several (even hundreds) of users logged in at the same time.
And again, you can switch between those sessions with Ctrl+Alt+Fx, no need to logout.
Therefore, I have another question: how can I cause a KDE session to be automatically restarted? In other words, have a shell script execute “kdmctl suicide” (which will end joe’s current KDE session) and then have that same shell script automatically start a new KDE session for joe (without me having to manually login again as joe).
You can’t.
It is possible to “remote control” KDE via DBUS to some degree (e.g. it is possible to automatically logout).
But if a user logs out, he is logged out and has to login again.
So what you actually still want to do is just run a file manager as a different user?
Then this approach is thinking way too complicated anyway.
Alternatively, if I open up dolphin in system user mode from within joe’s KDE session, is it possible to tell that dolphin file manager to automatically write out everything using john’s file permissions instead of root’s?
No.
If it is running as root, it is running as root.
But if you copy/move files, they will keep their original permissions, it’s not that dolphin writes out anything.
As I already said, I don’t see a way to do what you want with dolphin, mainly because dolphin relies on certain KDE services to be running.
It should be possible with a simpler file manager though, like mc, or even nautilus.