• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer navigation

The Geek Diary

  • OS
    • Linux
    • CentOS/RHEL
    • Solaris
    • Oracle Linux
    • VCS
  • Interview Questions
  • Database
    • oracle
    • oracle 12c
    • ASM
    • mysql
    • MariaDB
  • DevOps
    • Docker
    • Shell Scripting
  • Big Data
    • Hadoop
    • Cloudera
    • Hortonworks HDP

authconfig Command Examples in Linux

by admin

authconfig is a command-line utility in Linux that is used to configure the system’s authentication and user account settings. It is typically used to manage the settings and policies related to how users authenticate to the system, such as by using a password, a smart card, or a biometric factor.

authconfig can be used to enable or disable various authentication methods, such as local password authentication, LDAP authentication, or Kerberos authentication. It can also be used to set the default authentication policies for the system, such as the minimum password length or the number of failed login attempts before the account is locked.

To use authconfig, you will need to have administrative privileges on the system. You can run authconfig with various command-line options to specify the authentication settings you want to configure. For example, to enable local password authentication and set the minimum password length to 8 characters, you could use the following command:

authconfig --enablelocal --passminlen=8 --update

For more information on using authconfig, you can consult the authconfig documentation or use the authconfig –help command to view a list of available options and usage examples.

authconfig Command Examples

1. Display the current configuration (or dry run):

# authconfig --test

2. Configure the server to use a different password hashing algorithm:

# authconfig --update --passalgo=algorithm

3. Enable LDAP authentication:

# authconfig --update --enableldapauth

4. Disable LDAP authentication:

# authconfig --update --disableldapauth

5. Enable Network Information Service (NIS):

# authconfig --update --enablenis

6. Enable Kerberos:

# authconfig --update --enablekrb5

7. Enable Winbind (Active Directory) authentication:

# authconfig --update --enablewinbindauth

8. Enable local authorization:

# authconfig --update --enablelocauthorize

Filed Under: Linux

Some more articles you might also be interested in …

  1. po4a-updatepo: command not found
  2. CentOS/RHEL: How to find the package with a missing file using YUM
  3. How to uninstall rbenv from Ubuntu
  4. lvextend command examples in Linux
  5. logwatch : command not found
  6. CentOS/RHEL: Mount Command Fails With “mount: does not contain SELinux labels”
  7. arp: command not found
  8. grep Command Examples in Linux (Cheat Sheet)
  9. aws-shell: command not found
  10. CentOS / RHEL 7 : How to configure kdump

You May Also Like

Primary Sidebar

Recent Posts

  • “aws s3 mv” Command Examples
  • “aws s3 mb” Command Examples
  • “aws s3 ls” Command Examples
  • “aws s3 cp” Command Examples

© 2023 · The Geek Diary

  • Archives
  • Contact Us
  • Copyright