Apache Drill Impersonation -
i'm trying build in security on our drill (1.6.0) system. managed security user authentication work(jpam explained in documentation), impersonation not seem work. seems execute , fetch via the admin user regardless of has logged in via odbc.
my drill-override.conf file configured follows:
drill.exec: { cluster-id: "drillbits1", zk.connect: "localhost:2181", impersonation: { enabled: true, max_chained_user_hops: 3 }, security.user.auth { enabled: true, packages += "org.apache.drill.exec.rpc.user.security", impl: "pam", pam_profiles: [ "sudo", "login" ] } }
we using drill on 1 server, therefore i'm running drill-embedded start things up. troubleshooting:
root@srv001:/opt/apache-drill-1.6.0# bin/sqlline -u "jdbc:drill:schema=dfs;zk=localhost:2181;impersonation_target=duser001" -n entryuser -p entryuserpassword error: failure in connecting drill: org.apache.drill.exec.rpc.rpcexception: failure setting zk client. (state=,code=0) java.sql.sqlexception: failure in connecting drill: org.apache.drill.exec.rpc.rpcexception: failure setting zk client. @ org.apache.drill.jdbc.impl.drillconnectionimpl.<init> (drillconnectionimpl.java:159) @ org.apache.drill.jdbc.impl.drilljdbc41factory.newdrillconnection(drilljdbc41factory.java:64) @ org.apache.drill.jdbc.impl.drillfactory.newconnection(drillfactory.java:69) @ net.hydromatic.avatica.unregistereddriver.connect(unregistereddriver.java:126) @ org.apache.drill.jdbc.driver.connect(driver.java:72) @ sqlline.databaseconnection.connect(databaseconnection.java:167) @ sqlline.databaseconnection.getconnection(databaseconnection.java:213) @ sqlline.commands.connect(commands.java:1083) @ sqlline.commands.connect(commands.java:1015) @ sun.reflect.nativemethodaccessorimpl.invoke0(native method) @ sun.reflect.nativemethodaccessorimpl.invoke(nativemethodaccessorimpl.java:57) @ sun.reflect.delegatingmethodaccessorimpl.invoke(delegatingmethodaccessorimpl.java:43) @ java.lang.reflect.method.invoke(method.java:606) @ sqlline.reflectivecommandhandler.execute(reflectivecommandhandler.java:36) @ sqlline.sqlline.dispatch(sqlline.java:742) @ sqlline.sqlline.initargs(sqlline.java:528) @ sqlline.sqlline.begin(sqlline.java:596) @ sqlline.sqlline.start(sqlline.java:375) @ sqlline.sqlline.main(sqlline.java:268) caused by: org.apache.drill.exec.rpc.rpcexception: failure setting zk client. @ org.apache.drill.exec.client.drillclient.connect(drillclient.java:200) @ org.apache.drill.jdbc.impl.drillconnectionimpl.<init>(drillconnectionimpl.java:151) ... 18 more caused by: java.io.ioexception: failure connect zookeeper cluster service within allotted time of 10000 milliseconds. @ org.apache.drill.exec.coord.zk.zkclustercoordinator.start(zkclustercoordinator.java:123) @ org.apache.drill.exec.client.drillclient.connect(drillclient.java:198) ... 19 more
any ideas on this?
i have looked @ doing own built in security, i'm not able retrieve username sql query. have tried following without luck:
current_user() user() session_user()
any ideas on approach?
Comments
Post a Comment