Therefore, we’re going to do the following:
-
Verify that the new user has access to the same groups as your old one by executing groups and comparing the output of both users.
groups rexmalcolm groups rexmalcolm2
(Where obviously,
rexmalcolm
is your old user andrexmalcolm2
is your new one.)
E.G. ifrexmalcolm
is a member ofoperator
andrexmalcolm2
isn’t, execute:usermod --append --groups operator rexmalcolm2
-
Copy all data files from your old profile into your new one
cp --verbose --recursive --preserve=time-stamps /home/rexmalcolm/Documents/* /home/rexmalcolm2/Documents/
If that worked and you had no errors, remove the documents from your old user:
rm --recursive /home/rexmalcolm/Documents/*
repeat for:
Pictures
Videos
Music
.thunderbird
.mozilla/firefox/
- Templates, and everything else that is important to you.
- Linux games like Battle of Wesnoth have their game data stored under
~/.local/share/
E.G.~/.local/share/wesnoth/
After everything has been copied over, disable the old user so you cannot accidentally log on:
usermod --lock rexmalcolm
If you would have theming going on, don’t do everything in one day but do this at the rate of 1 application / theme / whatever per day and if the problem crops up again, roll back your last change
-
in 1 month delete the entire home directory of your old user, but don’t delete the user itself so that in 6 months time files still owned by that user will still show up under its username.
-
If you ever migrate to a new machine, just don’t migrate the old user: only the new one.
-
From now on, start making backups so you can roll back and never have to do this again: