Creating Custom Profiles

Create a custom profile based on an existing profile.

If you don't want to use the profiles included in Oracle Linux or those provided by vendors, you can create a custom profile.

  1. Create the new profile.

    Use the authselect create-profile command to create a profile. The syntax is:

    sudo authselect create-profile newprofile -b template --symlink-meta --symlink-pam
    newprofile

    The name for the custom profile.

    template

    The existing profile on which to base the new profile .

    --symlink-meta

    Creates symbolic links to the meta files in the original directory of the base template profile.

    --symlink-pam

    Creates symbolic links to the PAM templates in the original directory of the base template profile.

    This command creates an /etc/authselect/custom/newprofile directory that contains symbolic links to the files in the base profile's original directory. The only file that's not a symbolic link in this directory is nsswitch.conf.

  2. Customize the profile's configuration settings.

    Edit the /etc/authselect/custom/newprofile/nsswitch.conf file to include the required configuration.

  3. Select the new profile.

    Select the new, custom profile:

    sudo authselect select custom/newprofile                        

    Running this command also creates a backup of the original /etc/nsswitch.conf file and replaces it with a symbolic link to the corresponding file in the custom profile's directory.

    You can check this by comparing the symbolic link /etc/nsswitch.conf with the original /etc/nsswitch.conf.bak to verify that the original file's contents remain intact.

  4. Enable any required features.

    See Enabling Profile Features for reference.

  5. (Optional) Verify the profile's configuration.

    Run the following command to display information about the custom profile:

    authselect current