How to set/reset IdM user password non-interactively?

Solution Verified - Updated -

Issue

  • IdM domain admin wants to set user's password with script non-interactively.
  • Below commands prompts for password twice for verification:

    • ipa user-add --password <user>
    • ipa user-mod --password <user>
    • ipa passwd <user>
    # ipa passwd user1
    New Password: 
    Enter New Password again to verify:
    

Environment

  • Red Hat Enterprise Linux 7
  • Red Hat Enterprise Linux 8
  • Red Hat Enterprise Linux 9
  • Red Hat Identity Management (IdM) / FreeIPA
    • ipa-server

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content