I clobbered my environment variables, so now when I attempt to log into the desktop I get sent back to my login screen after a short blackout of the screen. I've attempted to use 'export' but that only works for the current terminal session. Every other answer I've read has mentioned using gedit, which I don't have access to.

How should I change it? I found an answer stating that it should be changed to "/usr/sbin:/usr/bin:/sbin:/bin".

  • 3
    It would probably be useful to explain how you clobbered the variables. You should have access to the nano editor via the CLI e.g. /usr/bin/sudo nano /etc/environment. You can also copy default .profile and .bashrc files from /etc/skel if those are what got "clobbered". Commented Mar 25, 2017 at 21:03

1 Answer 1


export will set them during that session.

What you wrote is the content of one of the variables. The PATH variable.

To check what it's currently set to, you can use,

echo $PATH 

From a terminal.

This can be overrides for your user on multiple places. Most common would be a few hidden files on your home directory.

Check the following files,


See if you find a line that references the PATH

You can post here the content.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .