Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I would like to change the default group for new users which are added to the system. Does anybody know in which file this is stored?

I'm using Solaris 11

share|improve this question

See the man page for useradd, specifically the -D flag. You would use

useradd -D -g newusergroupname

The same is true for roleadd

share|improve this answer

Initial defaults values are hardcoded in useradd binaries so you have no access to them.

Should you modify one of the defaults values using the command already provided by Timothy Butler (useradd -D ...), a file named /usr/sadm/defadduser is created to persistently store the settings.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.