On 12/27/06, Uwe Dippel <[EMAIL PROTECTED]> wrote:
I can't seem to get the -batch to work.
What I want, is to create user $stuid and group $stuid; of course put the
user into their group; with a password $STUD.
I have tried tens of combinations, but I don't get there, yet.
I follow the two examples at the end of the man pages and do something
like
adduser -unencrypted -batch $stuid $stuid $STUD
, but it wouldn't:
Group ``rr09876'' does not exist
I leave out one of the $stuid; along the example
Create user ``falken'' and login group ``falken''. Invite user
``falken'' into groups ``guest'', ``staff'', and ``beer''. Realname
(fullname) is ``Prof. Falken''. Password is ``joshua'' [...]
# adduser -batch falken guest,staff,beer 'Prof. Falken' joshua
and it still wouldn't. The only thing that I get to work is
adduser -unencrypted -batch $stuid nobody $STUD
, but that's not what I want. I tried -group $stuid and -group USER, but
then it always doesn't like the non-existing group '-group'.
I also tried the third example, which looks quite different, (I leave out
all the variations), still, no success.
I wonder, if the examples are clear; to me not.
Yes, I have tried Google, but essentially end at the examples from the man
page.
Thanks for any help,
These invocations work here (OpenBSD 4.0-current):
$ sudo adduser -batch test1 staff,wheel 'Test User 1' \
'$2a$06$kaLk/lPsfDpSibjO4frBf.WyoWOGY98illmMOL/bo6QsPTBmovsoC'
(password crypt generated using 'encrypt -b 6').
$ sudo adduser -unencrypted -batch test2 staff,wheel 'Test User 2' 'test2'
Correct password settings verified using security/john.
DS