What are equivalent parameters of adduser debian command in RHEL6? [closed]

None of this options doesn’t exist in RHEL6.

/usr/sbin/adduser --disabled-login --gecos 'GitLab' git

What is equivalent parameters for disabling account (no locking, it’s different) and adding gecos in Red Hat 6 ?

Answer

As per the Debian adduser manpage:

   --disabled-login
          Do  not  run passwd to set the password.  The user won't be able
          to use her account until the password is set.

By default, when using useradd, the account is disabled until you set a password on it for the first time, so simply not giving the user a password will accomplish the same thing as adduser --disabled-login.

Attribution
Source : Link , Question Author : holms , Answer Author : j883376

Leave a Comment