-1

I performed tonight, a virus scanning with ClamAV by running the software with the supersusers options by mistake, and after removing the detected potential threats, I can not login to my Unity session anymore. Indeed when I enter my password, the system constantly returns to the login page. Other users and invited sessions works normally. I can also use the console by pressing Ctrl + Alt + F1. I tried to perform a unity reset but no positive result

Could you help me fix this problem quickly?

Best regards.

Here is the output of ls -lah

romain@romain-W240EU-W250EUQ-W270EUQ:~$ ls -lah 
ls: impossible d'accéder à .gvfs: Permission non accordée 
total 908K 
-rw-rw-r-- 1 romain romain 0 oct 4 22:08 = 
drwxr-xr-x 50 romain romain 4.0K oct 4 22:08 . 
drwxr-xr-x 4 root root 4.0K jun 25 17:06 .. 
-rw------- 1 romain romain 116K aoû 16 22:27 2.jpg 
-rw------- 1 romain romain 15K aoû 16 22:28 3.jpg 
-rw------- 1 romain romain 4.1K aoû 16 22:29 4.jpg 
drwx------ 3 romain romain 4.0K jun 25 17:18 .adobe 
drwxrwxr-x 4 romain romain 4.0K sep 15 20:59 .audacity-data 
-rw------- 1 romain romain 7.6K oct 4 22:14 .bash_history 
-rw-r--r-- 1 romain romain 220 jun 24 14:24 .bash_logout 
-rw-r--r-- 1 romain romain 3.6K jun 24 14:24 .bashrc 
-rw-rw-r-- 1 romain romain 1.7K avr 12 2010 bd.key.asc 
drwx------ 41 romain romain 4.0K oct 4 21:47 .cache 
drwxrwxr-x 6 romain romain 4.0K sep 26 05:31 .clamtk 
drwx------ 3 romain romain 4.0K jun 24 14:35 .compiz 
drwx------ 38 romain romain 4.0K oct 3 23:37 .config 
drwx------ 3 romain romain 4.0K jun 26 16:43 .dbus 
drwxrwxr-x 2 romain romain 4.0K jui 5 14:35 deja-dup 
drwxr-xr-x 2 romain romain 4.0K sep 21 19:05 Desktop 
-rw-r--r-- 1 romain romain 25 jun 24 14:24 .dmrc 
drwxr-xr-x 2 romain romain 4.0K sep 30 17:11 Documents 
drwxr-xr-x 3 romain romain 4.0K jun 25 17:48 .dvdcss 
-rw-rw-r-- 1 romain romain 341 sep 27 11:57 .easyMP3Gain 
-rw-r--r-- 1 romain romain 8.8K jun 24 14:24 examples.desktop 
drwx------ 5 romain romain 4.0K oct 4 22:07 .gconf 
drwxr-xr-x 24 romain romain 4.0K sep 30 16:50 .gimp-2.8 
-rw-r----- 1 romain romain 0 oct 3 23:14 .gksu.lock 
drwx------ 3 romain romain 4.0K jui 19 19:46 .gnome 
drwx------ 3 romain romain 4.0K sep 24 22:11 .gnome2 
drwx------ 2 romain romain 4.0K aoû 1 14:15 .gnome2_private 
drwx------ 2 root root 4.0K jui 18 09:25 .gnupg 
drwx------ 2 romain romain 4.0K aoû 26 17:38 .gphoto 
drwxrwxr-x 4 romain romain 4.0K oct 4 00:53 gPodder 
drwxrwxr-x 2 romain romain 4.0K sep 9 15:05 .gstreamer-0.10 d????????? ? ? ? ? ? .gvfs 
-rw------- 1 romain romain 4.1K oct 4 21:47 .ICEauthority 
drwxr-xr-x 3 romain romain 4.0K sep 19 08:55 Images 
-rw------- 1 romain romain 5.4K aoû 16 22:26 images.jpg 
drwxrwxr-x 3 romain romain 4.0K jui 11 10:56 .java 
drwx------ 3 romain romain 4.0K jui 22 16:17 .kde 
drwx------ 3 romain romain 4.0K jun 24 14:24 .local 
drwx------ 3 romain romain 4.0K jun 25 17:18 .macromedia 
drwxrwxr-x 4 romain romain 4.0K sep 14 23:11 .miro 
drwxr-xr-x 3 romain romain 4.0K aoû 25 22:09 Modèles 
drwx------ 4 romain romain 4.0K jun 24 14:25 .mozilla 
drwxrwxr-x 2 romain romain 4.0K jui 22 17:50 .mplayer 
drwxr-xr-x 3 romain romain 4.0K sep 17 19:09 Musique 
drwxrwxr-x 4 romain romain 4.0K aoû 9 17:24 My PhotoFilmStrips 
drwxrwxr-x 2 romain romain 4.0K sep 7 21:27 OneDrive 
drwxr-x--- 6 romain romain 4.0K sep 24 21:26 .openshot 
-rw-rw-r-- 1 romain romain 362 sep 26 05:34 .PhotoFilmStrip 
-rw-rw-r-- 1 romain romain 388K sep 8 2009 pidgin-facebookchat-1.61.deb 
drwx------ 3 romain romain 4.0K jui 14 19:59 .pki 
-rw-r--r-- 1 romain romain 675 jun 24 14:24 .profile 
drwxr-xr-x 2 romain romain 4.0K oct 4 22:07 Public 
drwxrwxr-x 6 romain romain 4.0K sep 12 09:10 .puddletag 
drwx------ 6 romain romain 4.0K oct 3 23:08 .purple 
-rw-rw-r-- 1 romain romain 57K jui 19 16:31 purple-facebook.git 
drwxrwxr-x 3 romain romain 4.0K aoû 1 11:27 .pyrenamer 
drwxrwxr-x 2 romain romain 4.0K sep 17 15:51 .quodlibet 
drwx------ 2 romain romain 4.0K jui 25 21:08 .sbd 
drwx------ 6 romain romain 4.0K oct 3 23:36 .Skype 
drwxrwxr-x 2 romain romain 4.0K sep 7 21:27 .storagemadeeasy 
-rw-rw-r-- 1 romain romain 692 sep 7 21:27 .StorageMadeEasy.cnf 
-rw-rw-r-- 1 romain romain 107 sep 7 21:27 .storagemadeeasy.conf 
-rw-rw-r-- 1 romain romain 1.1K sep 7 21:29 .StorageMadeEasy.log 
-rw-rw-r-- 1 romain romain 0 sep 7 21:30 StorageMadeEasy_log.txt 
-rw-rw-r-- 1 romain romain 4.0K sep 27 11:54 .tagtoolrc 
drwxr-xr-x 11 romain romain 20K oct 4 00:43 Téléchargements 
drwx------ 3 romain romain 4.0K sep 19 08:55 .thumbnails 
drwx------ 4 romain romain 4.0K jun 25 17:09 .thunderbird 
drwxr-xr-x 3 romain romain 4.0K jui 5 14:00 Vidéos 
drwxrwxr-x 4 romain romain 4.0K jui 18 09:36 .wine-pipelight64 
-rw------- 1 root root 148 oct 4 21:50 .Xauthority 
-rw-rw-r-- 1 romain romain 131 aoû 17 22:37 .xinputrc 
-rw------- 1 romain romain 16K oct 4 21:50 .xsession-errors 
-rw------- 1 romain romain 725 oct 4 21:37 .xsession-errors.old

PPS : is there a file that resume what ClamAV did ?

  • Can you press CTRL + ALT + F3 at the login screen, login with your usual user and password, and then run "ls -lah" (no quotes) and add the results to your question please? (I suspect it's one of two things.) I really only need the results for .Xauthority if that saves some time. – KGIII Oct 04 '15 at 16:57
  • 1
    Viruses are rare in Linux and Linux is not Windows. In Linux your system is patched against viruses and antivirus is not necessary. In addition, false positives are very common and you should never delete anything without first investigating what you found. You can try unity reset – Panther Oct 04 '15 at 16:58
  • Do you by any chance know what file you deleted? Could you boot from a LiveUSB and try and find out? Or do you at least have any idea where the file was that you deleted? –  Oct 04 '15 at 16:59
  • 1
    Vaild uses of antivirus are to scan shared USB or folders, mail servers, samba shares. See https://help.ubuntu.com/community/Antivirus and learn Linux security and apparmor ;) – Panther Oct 04 '15 at 17:01
  • Was the file you deleted /usr/share/mime/mime.cache by any chance (there have been several threads about false positives from ClamAV from that file)? – steeldriver Oct 04 '15 at 19:28
  • @Steeldriver : Yes I don't see "mime.cache" in usr/share/mime – Rclement Oct 05 '15 at 15:24
  • I should point out, again, that I can connect to the guest and "normal" user session. Mine is a superuser session I can use for commands on the Ctrl+Alt+F1 console. – Rclement Oct 05 '15 at 15:34
  • I found this command to repair mime.cache update-mime-database /usr/share/mime but this didn't solve the problem. – Rclement Oct 05 '15 at 18:52
  • Can you run "ls -ld /tmp" and add that to your question as well? Basically, I'm trying to have you check the permissions. It should look almost exactly like this: drwxrwxrwt 20 root root 4096 Oct 5 15:15 /tmp but with the letters in that exact order. I'm unsure if this is the problem but it is worth eliminating it. – KGIII Oct 05 '15 at 19:19
  • 1
    root owns your .Xauthority file (among others): from the Ctrl-Alt-F1 virtual terminal, execute sudo chown -R romain:romain /home/romain/ – steeldriver Oct 05 '15 at 19:36
  • @KGIII : outpu of ls-ld / tmp

    drwxrwxrwt 5 root root 4096 oct 6 09:35 /tmp

    – Rclement Oct 06 '15 at 07:37

1 Answers1

0

This was a comment left that answered the question, and for easier access to a fix, here it is. NOTE all credit should go to steeldriver!!

Your files that let you login w/unity and enter Ubuntu are owned by root, not your user (In this case romain) Fixing this is simple. On the login screen do CTRL + ALT + F3 And that should bring you to a terminal like program. If it doesnt try CTRL + ALT + F1 Instead. Anyways, once you're at the terminal screen do

ls -lah

And any files that have "root" ownership, Chown them. For example if the file was located at /home/(USER)/example.file you would do

sudo chown -R romain:romain /home/(USER)/example.file

NOT RECCOMENDED, AS VIRUSES TRY TO MANIPULATE /HOME FOLDER FILES But if you want to simply chown all of your /home files at once you can do:

sudo chown -R romain:romain /home/romain/

Then reboot and login!

David
  • 3,367