Created attachment 158890 [details] image of users settings error SUMMARY Opening Users settings and changing username givers error. `org.kde.kcm_users: "org.freedesktop.Accounts.Error.Failed" "running '/usr/sbin/usermod' failed: Child process exited with code 8"` Changing the account name involves security risks that explains the fact that the name cannot be changed, I guess, but the entry is still there. It shouldn't be there, either because it doesn't work and/or because it is risky to be present as a such obvious option (if it worked). Linux/KDE Plasma: Kubuntu 23.04 (available in About System) KDE Plasma Version: 5.27.4 KDE Frameworks Version: 5.104.0 Qt Version: 5.15.8
*** Bug 511969 has been marked as a duplicate of this bug. ***
code 8 means the user is logged in
Confirming for Operating System: KDE neon User Edition KDE Plasma Version: 6.5.2 KDE Frameworks Version: 6.19.0 Qt Version: 6.9.3 Kernel Version: 6.14.0-35-generic (64-bit) Graphics Platform: Wayland Though, I have no log or debug information.
Currently, renaming a user via System Settings fails if the user is actively logged in, resulting in an error. The idea is to allow the renaming operation to be applied differently depending on the user’s session status: For active users: schedule the name change to take effect after the next system reboot. The UI could display a message such as: “Changes will take effect after the next reboot.” This way, the operation does not fail, and the user is clearly informed. For inactive users: apply the name change immediately, as usual. This approach preserves the full functionality of the renaming feature, avoids errors when a user is logged in, and provides a clear and user-friendly workflow.
That will be extremely complicated, probably not worth it. Far simpler to just prevent people from changing their own username while logged in.
A possibly relevant merge request was started @ https://invent.kde.org/plasma/plasma-workspace/-/merge_requests/6046
Git commit 46ceaa2de635973201ca5e1345c9e5ecfb01a733 by Nate Graham. Committed on 02/12/2025 at 02:22. Pushed by ngraham into branch 'master'. kcms/users: prevent changing own username and add explanations Changing your own username while logged in does not work. Prevent trying, and add an explanation for why. Also add a similar explanation for the "Delete User" button, which already conditionally disables itself, but with no explanation. FIXED-IN: 6.6.0 M +47 -25 kcms/users/src/ui/UserDetailsPage.qml https://invent.kde.org/plasma/plasma-workspace/-/commit/46ceaa2de635973201ca5e1345c9e5ecfb01a733