Enable Impersonation for Flume

The mapr user is the only user with impersonation enabled on a MapR cluster. Flume agents that use impersonation must run as the user mapr on the cluster. To use impersonation with Flume, your flume.conf file must contain the properties in the following example, with the correct values for your cluster:

Property Value Comment
agent1.sinks.sink1.type HDFS
agent1.sinks.sink1.hdfs.proxyUser user ID of target user Can be any valid MapR user identity.
agent1.sinks.sink1.hdfs.kerberosPrincipal mapr
agent1.sinks.sink1.hdfs.kerberosKeytab path to file If you are not using Kerberos to authenticate, this can be any valid file. If you are using Kerberos to authenticate, provide the path to your flume.keytab file.

Even though in this instance Flume is not using Kerberos authentication, the values for the hdfs.kerberosPrincipal and hdfs.kerberosKeytab parameters must exist in flume.conf. The user component of the principal must be the username of the user running flume-ng. The file at the location specified by hdfs.kerberosKeytab must exist, but need not be a valid keytab if Kerberos is not being used.