Following script can be used to add users in a batch way. #!/bin/bash for u in `seq 9`; do useradd -m -G GROUP $u echo $u | passwd -s $u done