search for: process_userlist

Displaying 1 result from an estimated 1 matches for "process_userlist".

2014 Mar 28
1
basic dsync wrapper for migration from another server
...uot; SIGINT workdir=/root/migrate # Load list of users into array. The file "migration_map" should contain one user at domain.tld per line. mapfile userList < $workdir/migration_map # Number of symultanious migrations num=10 index=0 # Loop over the array of user accounts function process_userlist { procs=$(ps aux | grep "dsync" | grep -v "grep" | wc -l) # Perform $num operations at a time for the length of the userList while [[ $procs -lt $num ]] && [[ ${#userList[@]} -gt $index ]]; do procs=$(ps aux | grep "dsync" | grep -v "grep&quo...