Mailing Lists: Apple Mailing Lists
Image of Mac OS face in stamp
Re: add user account - I am CLI newbie
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: add user account - I am CLI newbie



copied off the opendarwin.org page under FAQ.
there is a script *I think* that does most of this for you.


How do I make a user under Darwin?
Creating a user under Darwin involves creating the user in the netinfo database.
This creates an entry in the database for the user:
niutil -create / /users/bbraun
This sets the shell for the user:
niutil -createprop / /users/bbraun shell /bin/tcsh
This sets the "Real Name" of the user:
niutil -createprop / /users/bbraun realname "Rob Braun"
This sets the uid of the user:
niutil -createprop / /users/bbraun uid 1000
This sets the gid of the user:
niutil -createprop / /users/bbraun gid 1000
This sets the home directory of the user:
niutil -createprop / /users/bbraun home /Local/Users/bbraun
This creates an entry in the directory for the password, but doesn't set it:
niutil -createprop / /users/bbraun _shadow_passwd
And finally, you have to set the user's password:
passwd bbraun
How do I add a user to a group?
This adds the user bbraun to the group wheel:
niutil -appendprop / /groups/wheel users bbraun


> from: "Garr, Amber, & Cale" <email@hidden>
> date: Thu, 19 Sep 2002 00:15:20
> to: email@hidden
> subject: Re: add user account - I am CLI newbie
_______________________________________________
darwinos-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/darwinos-users
Do not post admin requests to the list. They will be ignored.



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2011 Apple Inc. All rights reserved.