To rebuild your /etc/passwd file use:
nisaddent -rv -f /etc/passwd passwd
HOWEVER, if you perform the above command
you must perform the following command on
the shadow file:
nisaddent -mv -f /etc/shadow shadow
DO NOT USE the nisaddent -rv -f command on
the /etc/shadow file, this command will confuse
replica servers and lock everyone off of a system.
NOTE: All tips provided are USE AT YOUR OWN RISK. Tips are submitted
by various unix admins around the globe. UGU suggest you read and
test each tip in a non-volitile environment before placing into
production.