Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

6
  • sudo su user is being used to not prompt for password (I am aware of the security implications of doing this). Anyways, if I use su user and introduce the password manually the exact same problem still rises. I have read the manuals you mentioned and used both options, unfortunately with no results. The sequence of commands used is only: sudo su user or su user. Any other suggestions? Thanks. Commented Nov 7, 2019 at 17:00
  • su -l user and su -l root still reproduce the issue. I have feeling that it has to do with some kind of "user aliases" or "environment variables" as you mentioned, unfortunately I haven't found related info to test it. Commented Nov 7, 2019 at 17:05
  • 1
    No, I can't think of anything more except on your use of sudo su: if a user can use sudo without a password, then sudo -iu username is the command to use. There really is no purpose invoking sudo su. Commented Nov 7, 2019 at 17:56
  • What’s the result of running id user1 and id user2? Commented Nov 7, 2019 at 20:50
  • Both IDs are the same (0, which I believe belongs to root). What I have noticed is that USER, LOGNAME and MAIL environment variables are being overwritten from one another occasionally. Already tried to search for the process that generates them, with no luck. Commented Nov 8, 2019 at 14:01