1

I left my laptop on for a night while I was downloading some songs but when I woke up it was shutdown and when I tried to restart it I came to the login window normally.

Now when I try to login as a guest a black screen flashes with some message and I am thrown back to the login window again [even as a guest user].

When I try to go to the shell by pressing Ctrl+Alt+F1 then login.

I see this error message.

--bash: /usr/lib/command-not-found: /usr/bin/python3: bad interpreter: permission denied

error image

I tried to set permissions to my home directory using this command :

sudo chmod -R ug+rwx /home/xor

but it didn't helped and I saw the same error again. [as above]

I also tried this command chown xor:xor .Xauthority this time no message but problem remained unresolved.

please help me as I am very new to ubuntu as I installed it 2 weeks ago and have no idea what is happening with my system. [and sorry for bad image]

xor
  • 111
  • 4
  • try typing restart – Chinmaya B Jul 04 '14 at 15:24
  • common I am not that idiot...I am rebooting it for 2 days That's the first thing every one does. – xor Jul 04 '14 at 15:25
  • Try installing/reinstalling Python3: sudo apt-get install --reinstall python3. (You could press Tab a couple of times after python3 to see the latest version and install that.) – muru Jul 04 '14 at 15:26
  • @adil sorry for that use ctrl+alt+f7 or ctrl+alt+f8 – Chinmaya B Jul 04 '14 at 15:32
  • @Creator He couldn't log in using the GUI. My guess is that an error in anything processed by one of the profiles (/etc/profile, .profile, etc.) causes a GUI login to fail. – muru Jul 04 '14 at 15:34
  • @muru so it might be a problem with lightdm ?? – Chinmaya B Jul 04 '14 at 15:35
  • @adil- take a look at this http://askubuntu.com/questions/186350/on-boot-black-screen-says-ubuntu-12-04-1-lts-ubuntu-name-tty1-and-asks-for – Chinmaya B Jul 04 '14 at 15:36
  • @Creator, not a problem with lightdm. Here: Try adding this to your .profile: . somefilewhichdoesnotexist, log out and log back in again. – muru Jul 04 '14 at 15:40
  • @Creator Thanks but..I already tried re-configuring lightdm / gdm / lxdm but no help.. – xor Jul 04 '14 at 18:15
  • @muru actually whatever command I try it just gives me --bash: /usr/lib/command-not-found: /usr/bin/python3: bad interpreter: permission denied error again. How ever I can use commands cd,ls,cat ,etc but not ones like sudo apt-get install . – xor Jul 04 '14 at 18:17
  • @muru Can you tell me how will I know which file is missing? – xor Jul 04 '14 at 18:18
  • What's the output of ls -l /usr/bin/python3? – muru Jul 04 '14 at 18:25
  • @muru output is : ls: cannot access /usr/bin/python3: permission denied however ls work else where It seems I dont have permissions over /usr/bin as I can't even cd or ls there – xor Jul 05 '14 at 03:26
  • What about ls -l /usr? If the permissions of /usr/bin are bad, we can fix that using chmod. – muru Jul 05 '14 at 11:56

1 Answers1

1

I know it's an old topic, but I had the same issue. I didn't find a solution to it either, so I decided to add my solution in case someone else is having the same problem.

What I did is actually very easy:

  1. I started Live CD
  2. Enter in Terminal
  3. Mount my disk - sudo mount /dev/sda1 mnt
  4. Go to /mnt
  5. Change the privileges - sudo chmod -R 755 /usr/bin
  6. You are DONE!

I hope this will help!

Aaron
  • 6,714