Installing Knox on ODP

After installing the Knox service via the Ambari UI and activating the Knox plugin in Ranger (if not done already), execute the following steps to assess Knox functionality.

Demo LDAP Server

Start Demo Knox LDAP server from the actions menu in Knox.

Proxy Users in HDFS

Update the following configs in custom core-site in HDFS:

Bash
Copy

Attempt the given curl command:

Bash
Copy

This command is expected to fail unless you have disabled Audit to SOLR in the Knox configuration.

Disable Audit to SOLR

On disabling Audit to SOLR in the Knox configuration, the API calls must function as expected.

Bash
Copy

Update Advanced Topology

In Knox configurations, update or add the URL's based on the hostname at your end for the services as shown below:

Bash
Copy

Note Change the hostnames according to your requirement.

Additionally, modify the gateway.dispatch.whitelist in the Advanced gateway-site section of the Knox configuration to use regular expressions as illustrated below:

For hostnames resembling newreleaseub1.acceldata.ce:

Bash
Copy

For hostnames resembling odp01.ubuntu.ce:

Bash
Copy

Setup Ambari SSO

Generate the Certificate

Bash
Copy

Display the contents using cat as you'll require them in the next step.

Bash
Copy

Ambari Server Setup SSO

Bash
Copy

Restart the Ambari server.

LDAP Setup and Sync

To setup LDAP, perform the following:

Bash
Copy

Sync LDAP as shown below:

Bash
Copy

Restart the Ambari server and clear all cookies after setting up LDAP or SSO in the browser.

  1. Perform UI checks for the following services

UI Checks

Oozie

Added the following configs in Oozie configuration to move forward:

Bash
Copy

Oozie UI URL

Bash
Copy

HDFS

HDFS UI URL

Bash
Copy

Yarn

Yarn UI URL

Bash
Copy

Troubleshooting

If the service UI, when accessed in incognito mode (similar to attempting to log in without cookies) in Chrome, redirects to the Knox login page again, include the following configuration (add the last parameter section) in the Advanced knoxsso-topology under the service attribute:

Bash
Copy

This will set the cookie property as mentioned above. After restarting the service and clearing old cookies in the browser, the UIs should also function correctly in Chrome.

Knox Uninstallation

To uninstall Knox, perform the following:

  1. Disable SSO setup on Ambari by doing the following:
Bash
Copy

Restart your Ambari server.

  1. Stop and delete the Knox service from the Ambari UI:
  2. To revert to the older quicklinks and other configurations added by Knox, the simplest approach is to roll back the version in the configurations of all services associated with Knox to an earlier version used just before Knox was introduced. Alternatively, if you have incorporated other required configurations into the service, you can remove these configurations by searching for the specified keywords in each of the services.

For HDFS, YARN, and MapReduce, navigate to Advanced Ambari configs and remove the following configurations:

Bash
Copy

For Ranger and Oozie, go to Advanced Ambari configs and remove the following configurations:

Bash
Copy

Additionally, check other services where additional Knox configurations may have been added.

Type to search, ESC to discard
Type to search, ESC to discard
Type to search, ESC to discard
  Last updated