Description of problem: It appears that doing localectl set-locale as root works globally. Doing as user changes locale settings but the locale after login is still what root has initially set. I would expect that changes by root would affect whole system and changes by user would affect only the particular user. That means after user sets locale, new shells will use that locale for the particular user. See current behavior: # localectl set-locale LANG=C.utf8 // now system locale changed to C.utf8 // lets do as a user $ localectl set-locale LANG=bg_BG.utf8 // then in a new shell $ locale LANG=C.utf8 LC_CTYPE="C.utf8" LC_NUMERIC="C.utf8" LC_TIME="C.utf8" LC_COLLATE="C.utf8" LC_MONETARY="C.utf8" LC_MESSAGES="C.utf8" LC_PAPER="C.utf8" LC_NAME="C.utf8" LC_ADDRESS="C.utf8" LC_TELEPHONE="C.utf8" LC_MEASUREMENT="C.utf8" LC_IDENTIFICATION="C.utf8" LC_ALL= $ localectl System Locale: LANG=bg_BG.utf8 VC Keymap: us X11 Layout: us,bg X11 Variant: ,phonetic X11 Options: grp:alt_shift_toggle Even worse as root: # localectl status System Locale: LANG=bg_BG.utf8 VC Keymap: us X11 Layout: us,bg X11 Variant: ,phonetic X11 Options: grp:alt_shift_toggle Version-Release number of selected component (if applicable): systemd-229-8.fc24.x86_64 I'm not even sure if there's any security implication here.
localectl communicates with systemd-localed which modifies /etc/locale.conf, i.e. the global configuration. It does not dynamically modify the environment of a user, because there's no way to do that. You have to log in again to see the changes. Whether the root or a normal user invokes localectl makes no difference for the result of the command (assuming that the user has sufficient privileges to invoke set-locale). To summarize, localectl set-locale sets the state for all users, but does not influence existing sessions. That's the design and your examples seems to show everything working as designed.
I also filed https://github.com/systemd/systemd/pull/3754 to maybe clarify things a bit in the man page.