Enabling Ranger HDFS Audits

To enable HDFS auditing for the supported components in the ODP stack, the following properties must be validated in Ranger.

  1. Ensure Ranger is enabled for all components. The Ranger service must be created in the Ranger UI, the service test connection and policies are working.
  2. In the Ambari UI, navigate to Ranger > Configs> RANGER AUDIT, and enable Audit to HDFS.
  1. Ensure that the destination HDFS directory is set to hdfs://<nameservice>. You can find the <nameservice> value in Ambari UI > HDFS > Configs > Advanced core-site > fs.defaultFS. Updating the destination HDFS directory should automatically update the HDFS audit path across all Ranger-enabled services, as shown.

Refer to the following documentation pages to enable HDFS auditing for the components.

HDFS

  1. In the Ambari UI, navigate to HDFS > Configs > Advanced ranger-hdfs-audit, and enable Audit to HDFS.
  2. In Advanced ranger-hdfs-audit, verify the following properties.
Bash
Copy

YARN

  1. In the Ambari UI, navigate to YARN > Configs > Advanced ranger-yarn-audit, and enable Audit to HDFS.
  2. In Advanced ranger-yarn-audit, verify the following properties.
Bash
Copy
Bash
Copy

Hive

  1. In the Ambari UI, navigate to Hive> Configs > Advanced ranger-hive-audit, and enable Audit to HDFS.
  2. In Advanced ranger-hive-audit, verify the following properties.
Bash
Copy

Impala

Impala — Audit to HDFS is enabled with Hive by default; no additional settings are required.

HBase

  1. In the Ambari UI, navigate to HBase > Configs > Advanced ranger-hbase-audit, and enable Audit to HDFS.
  2. In Advanced ranger-hbase-audit, verify the following properties.
Bash
Copy

Kafka

  1. In the Ambari UI, navigate to Kafka > Configs> Advanced ranger-kafka-audit, and enable Audit to HDFS.
  2. In Advanced ranger-kafka-audit, verify the following properties.
Bash
Copy

Kafka3

  1. In the Ambari UI, navigate to Kafka 3 > Configs> Advanced ranger-kafka3-audit, and enable Audit to HDFS.
  2. In Advanced ranger-kafka3-audit, verify the following properties.
Bash
Copy

Ozone

  1. In the Ambari UI, navigate to Ozone > Configs > Advanced ranger-ozone-audit, and enable Audit to HDFS.
  2. In Advanced ranger-ozone-audit, verify the following properties.
Bash
Copy

RangerKMS

  1. In the Ambari UI, navigate to RangerKMS > Configs > Advanced ranger-rangerkms-audit, and enable Audit to HDFS.
  2. In Advanced ranger-kms-audit, update the following properties.
Bash
Copy

Kudu

Before enabling Ranger HDFS audit for Kudu, ensure the required Ranger policies are in place as outlined in the documentation: Security. On this page, see Ranger.

  1. In the Ambari UI, navigate to Kudu > Configs > Advanced ranger-kudu-audit, and enable Audit to HDFS.
  2. In Advanced ranger-kudu-audit, verify the following properties.
Bash
Copy

Schema Registry

Before enabling Ranger HDFS audit for Schema Registry, ensure the required Ranger policies are in place as outlined in the documentation: Installation. On this page, see Ranger Configuration.

  1. In the Ambari UI, navigate to Schema Registry > Configs > Advanced ranger-schema-registry-audit, and enable Audit to HDFS.
  2. In Advanced ranger-schema-registry-audit, update the following properties.
Bash
Copy

Knox

  1. In the Ambari UI, navigate to Knox > Configs > Advanced ranger-knox-audit, and enable Audit to HDFS.
  2. In Advanced ranger-knox-audit, update the following properties.
Bash
Copy

NiFi

Before enabling Solr audit for NiFi, ensure the required Ranger policies are in place as outlined in the documentation: NiFi Installation and SSL Enablement. On this page, see Ranger Configuration.

  1. Copy hdfs-site.xml and core-site.xml to the NiFi conf directory.
Bash
Copy

Verify the following properties under Advanced ranger-nifi-audit.

Bash
Copy

NiFi Registry

Before enabling Solr audit for NiF-Registry, ensure the required Ranger policies are in place as outlined in the documentation: Installing NiFi Registry. On this page, see see Ranger Configuration.

  1. Copy hdfs-site.xml and core-site.xml to the NiFi conf directory.
Bash
Copy
  1. Verify the following properties under Advanced ranger-nifi-audit.
Bash
Copy
  1. Restart NiFi Registry, and you must be able to view HDFS audits at/ranger/audit/nifi-registry/.
Type to search, ESC to discard
Type to search, ESC to discard
Type to search, ESC to discard
  Last updated