$ cat /etc/passwd | grep "/bin/bash" > utenti.txt

non l'ho provato, quindi non assicuro che funzioni