Tuesday, December 21, 2010

Linux - Ubuntu - clone user accounts

User account / setup to clone: john

New account: paul

====

Two Quick & Dirty Methods:

First configure john's account (account you wish to clone [copy multiple times]).
Desktop UI, Apps, Bookmarks+plugins, add default data, etc.

Avoid adding additional passwords and/or making major directory structure
changes. You can though I would test the following methods first as shown,
they have been tested and proven to work [for me] over many years, 
systems and distros.

See also: http://ubuntuforums.org

====

1.  Open a Terminal

# create new user: paul after you have configured account: john
sudo adduser paul

# copy john's account to paul
sudo cp -R /home/john* /home/paul

# set user:group, paul:paul
sudo chown -R paul:paul /home/paul

====

Src. Post: http://goo.gl/0TkgE

2. Open a Terminal

# create new user: paul after you have configured account: john
sudo adduser paul

# change directory to john
cd /home/john

# copy john's account to paul
sudo tar cf - . | (cd ../paul;tar xf -)

# set user:group, paul:paul
sudo chown -R paul:paul /home/paul

====

Login to the new account: paul

Best regards :-)