Find the answer to your Linux question:
Results 1 to 3 of 3
Originally Posted by someguynearby You can add a user with their password in one go, just use the -p option: useradd -p '$1$S5P0QMGg$1RJ8yBPnDvyJ0SynNkESL1' mruser The above password hash is for ...
  1. #1
    Just Joined!
    Join Date
    Apr 2010
    Posts
    6

    adding users with Kickstart

    Quote Originally Posted by someguynearby View Post
    You can add a user with their password in one go, just use the -p option:

    useradd -p '$1$S5P0QMGg$1RJ8yBPnDvyJ0SynNkESL1' mruser


    The above password hash is for the word: password
    The easiest way to hash your password would be to grab it out of /etc/shadow
    Easy Peazy!

    Hi,
    I am trying the same with the ks.cfg for RHEL5.4, but the users dont seem to get creted, after I login.

    useradd -p <ENCRYPTE_PWD> username

    Am i missing anything, or is this not supported now ??

    Thanks for your help in advance!!

  2. #2
    Linux Enthusiast
    Join Date
    Jul 2005
    Location
    Maryland
    Posts
    521
    Put it in %post section, and try with full path:

    Code:
    %post
    /usr/sbin/useradd username -p 'oPnCuj1vgg272'

  3. #3
    Just Joined!
    Join Date
    Apr 2010
    Posts
    6
    Quote Originally Posted by pavlo_7 View Post
    Put it in %post section, and try with full path:

    Code:
    %post
    /usr/sbin/useradd username -p 'oPnCuj1vgg272'
    Thanks Pavlo,
    Basically the issue was with the --chroot option in the %post section after it was removed it worked.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
...