1. your_home.tar.gz
2.useradd -m your_home_name
usermod -s /bin/bash your_home_name
paswd your_home_name
How do I add a user in Ubuntu? [closed]
3.add your_home_name as a sudoer
in
As root edit /etc/sudoers and place the following line:
youruser ALL=(ALL) NOPASSWD:ALL
after
# Allow members of group sudo to execute any command
%sudo ALL=(ALL:ALL) ALL
In this way you will be capable to execute all commands that require sudo privileges passwordless.
In order to use sudo and be prompted for a password you need to remove
NOPASSWD:ALL
4.enter your new user tty
copy your_home.tar.gz
and unzip it into your new user tty
5.all thing come back at new devies