Applicable to:
- Plesk for Linux
Symptoms
The following error message is shown in Plesk:
PLESK_ERROR: useradd: Invalid configuration: UID_MIN (10000), UID_MAX (9998)
useradd: can't create user
when:
- restoring a domain from a Plesk backup
- adding a new domain
- migrating a subscription
- changing hosting type of a domain from No web hosting to Website at Domains > example.com > Hosting & DNS > Hosting.
Cause
Custom UID and GID values are defined in /etc/login.defs:
CONFIG_TEXT: # Min/max values for automatic uid selection in useradd
#
UID_MIN 1000
UID_MAX 9998
...
# Min/max values for automatic gid selection in groupadd
#
GID_MIN 1000
GID_MAX 9998
The values in /etc/login.defs are set to create users with UID above 10000, while the MAX UID value has been set to 9998.
Resolution
- Connect to your Plesk server via SSH.
-
Open the file
/etc/login.defsin a text editor. In this example, we are using vi editor:# vi /etc/login.defs
-
Set
UID_MIN,UID_MAX,GID_MINandGID_MAXvalues on the system level as follows:CONFIG_TEXT: UID_MIN 1000
UID_MAX 60000
GID_MIN 1000
GID_MAX 60000 - Save the changes and close the file.
Comments
Please sign in to leave a comment.