9

My main account got messed up, as I tried to fix it things went downhills.

  • keyboard mess - tried unity --restore and deleting .gconf2*, fail
  • deleted .* in ~, total havoc. Chromium and Firefox crashes etc.

Now, another user account is fully functioning, but I really want my regular username back.

Is there any way to completely wipe the settings for the messed up account or copy the profile from the functioning user?

Braiam
  • 69,112
user8302
  • 205

2 Answers2

11

I would boot into recovery mode an go to the root shell, then do:

Backup old folder:

mv /home/youruser /home/youruser-backup

Create new 'home' folder for youruser

mkdir /home/youruser

Restore operating system default user configuration files (e.g. bash config)

cp -rT /etc/skel/ /home/youruser/

Set correct read/write access

chown -R youruser:youruser /home/youruser

Reboot system

shutdown -r now

That would give you an empty folder for your old default user. You should be able to login and then copy your important files back from youruser-backup to youruser.

vanadium
  • 97,564
minimec
  • 846
2

You can remove your old non-working user account, then rename the new working account to the old username, see this question: How do I change my username?

enzotib
  • 96,093