Not signed in (Sign In)
  1.  
    Member
    • CommentAuthornaresh
    • CommentTimeJun 21st 2008
     
    First of all create two files one contains username and other
    passwords. here i'm using file users as username file and file pass as
    password file and script is:

    #!/bin/bash
    arr=(`cut -f1 users`)
    for i in `cat pass`
    do
    useradd ${arr[$x]};
    echo $i|passwd --stdin ${arr[$x]};
    x=$[$x+1];
    done

    enjoy creating users in one go!!
  2.  
    Administrator
    • CommentAuthoradmin
    • CommentTimeJul 3rd 2008
     

    users

  3.  
    Administrator
    • CommentAuthoradmin
    • CommentTimeOct 19th 2008
     

    for i in `seq 1 5`; do useradd user$i; echo password$i|passwd user$i --stdin; done

    creating 5 users.