7

I created a virtual mail user for postfix virtual mailboxes with a gid/uid of 5555, but now every new user I create starts at > 5555, is it possible to reset the autonumbering so normal users will be back in the low 100s? I know this appears pedantic, but I am OCD AND 5555 is supposed to signify a "special" user, much like 65534 does for anonymous NFS user.

--Update--

Confirming that ssgelm's solution works. I changed /etc/login.defs and set the UID_MAX and GID_MAX to 5000, and all new users are now getting uids/gids in the low 500s (expected behavior).

9

According to the man page (http://linux.die.net/man/8/useradd):

UID_MAX (number), UID_MIN (number)
    Range of user IDs used for the creation of regular users by useradd or newusers.

I'm pretty sure that if you set UID_MAX in /etc/login.defs to 5554 you will get the behavior you are looking for.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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