添加账号并建立所属目录:

1
2
3
4
5
6
sudo su 
useradd username -m -s /bin/bash
passwd username
mkdir /home/username
chown username:username -R /home/username
chgrp root /home/usesrname

赋予sudo权限:

1
2
visudo -f  /etc/sudoers
username ALL(ALL):ALL

添加常用软件conda环境变量:

1
2
echo 'export PATH="/home/ubuntu/anaconda3/bin:$PATH"' >> ~/.bashrc
source .bashrc