On Tuesday 17 September 2002 07:25 pm, Bsd Neophyte wrote:
> i'm setting up samba on my FreeBSD box.  the goal is to make it a PDC.
>
> i'm following the directions from "Samba Unleased" by SAMS.
>
> in the instructions, there's mention that each machine needs to have a
> user account on the server.
>
> it gives the following command to setup a machine account:
>
> useradd -c "Samba ODC fir MYDOMAIN' -M -s /bin/false -n PERSEUS$
>
> now, I don't know what the -M stands for when you add a user.  i'm
> assuming i need to use "pw useradd".  when i try i get an error.
>
> the man page for pw shows a -M, but it's only used for the groupadd
> option.
>
> i would like to know what i should use instead of the -M.
>
> any and all help will be appreciated.
>

'pw' has different arguments based on the first argument. If you say
'pw useradd' then "-M" is not valid. You'll see this if you carefully
read the man page.

What I think you want is -g groupname . IE; for group 'staff", it would
be 'pw useradd username -g staff  -y /dev/null -s /bin/false' . I'm not sure 
this works right with machine accounts, where the last character of the user 
name is '$'. I've never tried it. I just run 'vipw' and add the line.

username$:I:4055:3000::0:0:Machine Foobo:/dev/null:/bin/false

Then you run 'smbpasswd -a -m username' .

-jim



To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-questions" in the body of the message

Reply via email to