2

I just fixed an issue with a login loop, using this solution. So now I can log into my account again, but the home directory looks empty. I can see my old folders (Documents, Pictures, PycharmProjects etc) when I do cd /home/tmp/ && ls, but the folders don't appear graphically in my file system nor in /home/ when I try to list them. I tried moving them from tmp to home and I tried copying, but they remain invisible. How do I get the normal filesystem back? I'd rather not fix this by trial and error, that's why I ask it here.

I'm using Ubuntu 18.04 with a 5.3.0-28-generic kernel on a Dell Vostro 5590 laptop (only a few months old). It's not dual booted, I removed Windows.

Cheers!

  • What does whoami show you? – K7AAY Mar 3 at 22:38
  • 1
    @K7AAY, my username... – Sarah Mar 4 at 6:49
  • Which version of Linux have you installed (Ubuntu server, Ubuntu desktop, Kubuntu, Lubuntu, Xubuntu, Ubuntu MATE, et al.) , and which release number? Are you using virtualization, and if so, which package? Please click edit and add that vital information to your question so all the facts we need are in the question. Please do not use Add Comment. – K7AAY Mar 4 at 16:04
1
gedit ~/.config/user-dirs.dirs

It should look like this:

XDG_DESKTOP_DIR="$HOME/Desktop"
XDG_DOWNLOAD_DIR="$HOME/Downloads"
XDG_TEMPLATES_DIR="$HOME/Templates"
XDG_PUBLICSHARE_DIR="$HOME/Public"
XDG_DOCUMENTS_DIR="$HOME/Documents"
XDG_MUSIC_DIR="$HOME/Music"
XDG_PICTURES_DIR="$HOME/Pictures"
XDG_VIDEOS_DIR="$HOME/Videos"

Logout and log in again. They should become visible. But make sure these folders exist in your ~/ folder. That is:

$ ls ~/

Desktop  Downloads  Documents  Music  Public  Pictures  Videos    Templates

If you do not see these folders in your user's directory, then

  • create them manually
  • edit user-dirs.dirs file
  • copy files cp -fr /home/tmp/Documents/* /home/youruser/Documents/
  • Change ownership if required: chown -R /home/youruser/Documents
  • logout/login and check if Documents folder appeared.
  • repeat for the rest folders

Reference

| improve this answer | |
  • I get the right output of that gedit command, but the folders do not appear. The only thing in my homedirectory is examples.desktop, which, I suspect, is needed for login. – Sarah Mar 5 at 9:27
  • You need to ensure, those directories are present in your home folder. If no, create them. – Gryu Mar 5 at 12:01

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.