I'm running an Ubuntu 12.04 LTS partition and I've recently have had issues logging in.
From the GUI login screen, when I enter my username and password, it takes me right back to the login screen. This is different from when I enter my username and password incorrectly.
So I entered alt+ctrl+F1 to access the terminal and I signed in. It then reads:
-bash: /etc/profile Permission denied
From what I've tested, the only commands that I can run from terminal are basic terminal commands like ls and pwd. I tried changing my access to /etc
:
sudo chmod 755 /etc
I get the errors:
sudo: unable to open /etc/sudoers: Permission denied
sudo: no valid sudoers sources found, quitting
sudo: unable to initialize policy plugin
If I run it without sudo I get a permission denied. If someone knows how to get around this issue that would be great
ls -l /etc/profile
andls -l /etc/sudoers
? – rusty Mar 03 '14 at 18:19sudo chmod -R 755...
? In that case it will be more or less impossible to recover... because/etc
is 755 in my machine, so nothing should have happened. See for example http://unix.stackexchange.com/questions/61997/recovering-from-chmod-r-777-in-ubuntu (there is a question specific here, but the search box is unable to help me... found: http://askubuntu.com/questions/43621/what-if-i-accidently-run-command-chmod) – Rmano Mar 03 '14 at 19:18drw-rw----
and I get permission denied when I try to run the two commands you mentioned – Anu Vedantham Mar 20 '14 at 00:56sudo
– Anu Vedantham Mar 20 '14 at 04:44