SlideShare une entreprise Scribd logo
1  sur  16
1 © Hortonworks Inc. 2011 – 2017. All Rights Reserved
Troubleshooting Kerberos
In Hadoop :
Taming the Beast
DataWorks Summit
Sept 2017
2 © Hortonworks Inc. 2011 – 2017. All Rights Reserved
Author Profile
Vipin Rathor
Sr. Product Specialist (HDP Security)
Contributed to Kerberos, Apache Zeppelin, Apache Atlas
vrathor@hortonworks.com / @VipinRathor46
3 © Hortonworks Inc. 2011 – 2017. All Rights Reserved
Agenda
• Why Kerberos?
• Where is Kerberos used across the Hadoop Stack?
• What is Kerberos & how does it work
• Realms, Principals and Keytabs
• Systematic Approach to Kerberos Nirvana
• Tools available in Hadoop
• Native Kerberos Tools / Debug Options
• Kerberos Checklist
• Most Common Kerberos Error Messages (& their meanings)
4 © Hortonworks Inc. 2011 – 2017. All Rights Reserved
Why Kerberos?
• Universal Authentication mechanism for Hadoop stack
• Integrates with enterprise user management (e.g. Active Directory)
Solves:
• How can parts of a cluster trust each other
(NameNodes, DataNodes, YARN, HBase, ZooKeeper...)
• How can users trust the system?
• How can the system trust users?
• Foundation for: how can users delegate rights to applications?
• Without Kerberos: your cluster has NO security
Hadoop clusters are some of the largest Kerberos systems ever!!
5 © Hortonworks Inc. 2011 – 2017. All Rights Reserved
Where is Kerberos used across the Hadoop Stack?
• Ubiquitous End-User / Hadoop Service Authentication mechanism
• Hadoop DelegationToken (Delegated authentication to NameNode)
• != Kerberos Tickets
• Bootstrapped with Kerberos authentication token
• HTTP Authentication
• Using SPNEGO (RFC 4559)
• Via Browsers / cURL (curl --negotiate)
• RPC Authentication
• Using Simple Authentication & Security Layer aka SASL (!= SSL)
• Java API Based Kerberos login
• Using JGSS / JAAS
• GSS-API (RFC 2743)
6 © Hortonworks Inc. 2011 – 2017. All Rights Reserved
What is Kerberos
• Open source, Developed by MIT
• Password is NEVER transmitted over wire
• Central trusted authority – Key Distribution Center (KDC)
• Symmetric key (common shared key)
• Flavors:
• MIT Kerberos
• Active Directory
• Heimdal Kerberos (OS X)
7 © Hortonworks Inc. 2011 – 2017. All Rights Reserved
How does Kerberos work
End User
- Does kinit (1 & 2)
- Runs HDFS
command (3 - 6)
Hadoop NameNode
- Starts up with nn.service.keytab
- Verifies user and gives access to
HDFS
KDC
- Provisions user keys and
service keytabs (e.g.
nn.service.keytab)
- Provides TGT and TGS
8 © Hortonworks Inc. 2011 – 2017. All Rights Reserved
Realms, Principals and Keytabs
• Realm
• User Principal
• E.g. user1@HWX.COM
• ken/admin@HWX.COM
• ken/sandbox.hortonworks.com@HWX.COM
• Service Principal
• E.g. HTTP/sandbox.hortonworks.com@HWX.COM
• nn/node1.hortonworks.com@HWX.COM
• dn/node2.hortonworks.com@HWX.COM
• dn/_HOST@HWX.COM
• Keytabs
• Service keytabs (for service)
• Headless keytabs (for user)
9 © Hortonworks Inc. 2011 – 2017. All Rights Reserved
Systematic Approach to Kerberos Nirvana
• Identify the involved parties (user, service, keytabs, nodes)
• Identify the stage where Kerberos is failing
• Based on stage & error message, narrow down between client-side or service-
side issue
• Check & verify configurations for correctness using the appropriate tools
• Repeat as necessary
10 © Hortonworks Inc. 2011 – 2017. All Rights Reserved
Kerberos Tools Available in Hadoop
• Kdiag
• Runs a series of diagnostic checks & gives suggestions
• hadoop org.apache.hadoop.security.KDiag
11 © Hortonworks Inc. 2011 – 2017. All Rights Reserved
Kerberos Tools Available in Hadoop (cntd..)
• HadoopKerberosName
• Checks Auth_to_local rules (Kerberos Principal to Unix user name conversion)
• hadoop org.apache.hadoop.security.HadoopKerberosName
nn/bali1.openstacklocal@LAB.HORTONWORKS.NET
12 © Hortonworks Inc. 2011 – 2017. All Rights Reserved
Native Kerberos Tools / Debug Options
• via command line
• kinit
• klist -eaf / klist –kte
• kvno
• kdestroy
• export KRB5_TRACE=/tmp/krb5-curl.out
curl -ivL --negotiate -u: "http://namenode-host:50070/webhdfs/v1/?op=LISTSTATUS"
• via debug messages
• export HADOOP_JAAS_DEBUG=true
• export HADOOP_ROOT_LOGGER=DEBUG,console
• via Java library
• -Dsun.security.krb5.debug=true
• -Dsun.security.spnego.debug=true
• export OPTS=“$OPTS -Dsun.security.krb5.debug=true”
13 © Hortonworks Inc. 2011 – 2017. All Rights Reserved
Kerberos Checklist
• FQDN
• Name Resolution
• If DNS is configured, then check reverse lookup
• Date/Time sync (< 5 minutes)
• Configuration file - /etc/krb5.conf
• Principal Names
• Stale Keytabs (via kvno)
• Credential Cache location (JAAS config)
• Which Java suite, JCE policy
• KDC log file - /var/log/kerberos/krb5kdc.log
14 © Hortonworks Inc. 2011 – 2017. All Rights Reserved
Most Common Kerberos Error Messages (& their meaning)
• <unknown client> for <unknown service> 
• Decrypt Integrity Check Failed
• AES256 EncType not supported
• Clock skew too great
• Kerberos service principal not found in the database
• Client not found in the database
• No valid initial credential found
15 © Hortonworks Inc. 2011 – 2017. All Rights Reserved
References
• http://web.mit.edu/kerberos/
• http://www.kerberos.org/software/tutorial.html
• https://github.com/steveloughran/kerberos_and_hadoop
16 © Hortonworks Inc. 2011 – 2017. All Rights Reserved
Thank you !

Contenu connexe

Tendances

Tendances (20)

Galera Cluster for MySQL vs MySQL (NDB) Cluster: A High Level Comparison
Galera Cluster for MySQL vs MySQL (NDB) Cluster: A High Level Comparison Galera Cluster for MySQL vs MySQL (NDB) Cluster: A High Level Comparison
Galera Cluster for MySQL vs MySQL (NDB) Cluster: A High Level Comparison
 
OpenTelemetry For Operators
OpenTelemetry For OperatorsOpenTelemetry For Operators
OpenTelemetry For Operators
 
Building Reliable Lakehouses with Apache Flink and Delta Lake
Building Reliable Lakehouses with Apache Flink and Delta LakeBuilding Reliable Lakehouses with Apache Flink and Delta Lake
Building Reliable Lakehouses with Apache Flink and Delta Lake
 
Apache Spark Architecture
Apache Spark ArchitectureApache Spark Architecture
Apache Spark Architecture
 
Building large scale transactional data lake using apache hudi
Building large scale transactional data lake using apache hudiBuilding large scale transactional data lake using apache hudi
Building large scale transactional data lake using apache hudi
 
Apache Kafka’s Transactions in the Wild! Developing an exactly-once KafkaSink...
Apache Kafka’s Transactions in the Wild! Developing an exactly-once KafkaSink...Apache Kafka’s Transactions in the Wild! Developing an exactly-once KafkaSink...
Apache Kafka’s Transactions in the Wild! Developing an exactly-once KafkaSink...
 
Apache Tez – Present and Future
Apache Tez – Present and FutureApache Tez – Present and Future
Apache Tez – Present and Future
 
Evening out the uneven: dealing with skew in Flink
Evening out the uneven: dealing with skew in FlinkEvening out the uneven: dealing with skew in Flink
Evening out the uneven: dealing with skew in Flink
 
Building an open data platform with apache iceberg
Building an open data platform with apache icebergBuilding an open data platform with apache iceberg
Building an open data platform with apache iceberg
 
[2018] MySQL 이중화 진화기
[2018] MySQL 이중화 진화기[2018] MySQL 이중화 진화기
[2018] MySQL 이중화 진화기
 
Hudi architecture, fundamentals and capabilities
Hudi architecture, fundamentals and capabilitiesHudi architecture, fundamentals and capabilities
Hudi architecture, fundamentals and capabilities
 
Fundamentals of Apache Kafka
Fundamentals of Apache KafkaFundamentals of Apache Kafka
Fundamentals of Apache Kafka
 
Cosco: An Efficient Facebook-Scale Shuffle Service
Cosco: An Efficient Facebook-Scale Shuffle ServiceCosco: An Efficient Facebook-Scale Shuffle Service
Cosco: An Efficient Facebook-Scale Shuffle Service
 
Autoscaling Flink with Reactive Mode
Autoscaling Flink with Reactive ModeAutoscaling Flink with Reactive Mode
Autoscaling Flink with Reactive Mode
 
APACHE KAFKA / Kafka Connect / Kafka Streams
APACHE KAFKA / Kafka Connect / Kafka StreamsAPACHE KAFKA / Kafka Connect / Kafka Streams
APACHE KAFKA / Kafka Connect / Kafka Streams
 
How to build a streaming Lakehouse with Flink, Kafka, and Hudi
How to build a streaming Lakehouse with Flink, Kafka, and HudiHow to build a streaming Lakehouse with Flink, Kafka, and Hudi
How to build a streaming Lakehouse with Flink, Kafka, and Hudi
 
kafka
kafkakafka
kafka
 
Deploying Flink on Kubernetes - David Anderson
 Deploying Flink on Kubernetes - David Anderson Deploying Flink on Kubernetes - David Anderson
Deploying Flink on Kubernetes - David Anderson
 
Building robust CDC pipeline with Apache Hudi and Debezium
Building robust CDC pipeline with Apache Hudi and DebeziumBuilding robust CDC pipeline with Apache Hudi and Debezium
Building robust CDC pipeline with Apache Hudi and Debezium
 
Grafana Loki: like Prometheus, but for Logs
Grafana Loki: like Prometheus, but for LogsGrafana Loki: like Prometheus, but for Logs
Grafana Loki: like Prometheus, but for Logs
 

En vedette

Improvements in Hadoop Security
Improvements in Hadoop SecurityImprovements in Hadoop Security
Improvements in Hadoop Security
DataWorks Summit
 

En vedette (20)

Improvements in Hadoop Security
Improvements in Hadoop SecurityImprovements in Hadoop Security
Improvements in Hadoop Security
 
Hadoop
HadoopHadoop
Hadoop
 
An Approach for Multi-Tenancy Through Apache Knox
An Approach for Multi-Tenancy Through Apache KnoxAn Approach for Multi-Tenancy Through Apache Knox
An Approach for Multi-Tenancy Through Apache Knox
 
Built-In Security for the Cloud
Built-In Security for the CloudBuilt-In Security for the Cloud
Built-In Security for the Cloud
 
Hdp security overview
Hdp security overview Hdp security overview
Hdp security overview
 
Big Data Security with Hadoop
Big Data Security with HadoopBig Data Security with Hadoop
Big Data Security with Hadoop
 
Hadoop & Security - Past, Present, Future
Hadoop & Security - Past, Present, FutureHadoop & Security - Past, Present, Future
Hadoop & Security - Past, Present, Future
 
Information security in big data -privacy and data mining
Information security in big data -privacy and data miningInformation security in big data -privacy and data mining
Information security in big data -privacy and data mining
 
Apache Knox setup and hive and hdfs Access using KNOX
Apache Knox setup and hive and hdfs Access using KNOXApache Knox setup and hive and hdfs Access using KNOX
Apache Knox setup and hive and hdfs Access using KNOX
 
Big Data and Security - Where are we now? (2015)
Big Data and Security - Where are we now? (2015)Big Data and Security - Where are we now? (2015)
Big Data and Security - Where are we now? (2015)
 
Securing Hadoop's REST APIs with Apache Knox Gateway Hadoop Summit June 6th, ...
Securing Hadoop's REST APIs with Apache Knox Gateway Hadoop Summit June 6th, ...Securing Hadoop's REST APIs with Apache Knox Gateway Hadoop Summit June 6th, ...
Securing Hadoop's REST APIs with Apache Knox Gateway Hadoop Summit June 6th, ...
 
Apache Knox Gateway "Single Sign On" expands the reach of the Enterprise Users
Apache Knox Gateway "Single Sign On" expands the reach of the Enterprise UsersApache Knox Gateway "Single Sign On" expands the reach of the Enterprise Users
Apache Knox Gateway "Single Sign On" expands the reach of the Enterprise Users
 
Treat your enterprise data lake indigestion: Enterprise ready security and go...
Treat your enterprise data lake indigestion: Enterprise ready security and go...Treat your enterprise data lake indigestion: Enterprise ready security and go...
Treat your enterprise data lake indigestion: Enterprise ready security and go...
 
Hadoop Security Today & Tomorrow with Apache Knox
Hadoop Security Today & Tomorrow with Apache KnoxHadoop Security Today & Tomorrow with Apache Knox
Hadoop Security Today & Tomorrow with Apache Knox
 
OAuth - Open API Authentication
OAuth - Open API AuthenticationOAuth - Open API Authentication
OAuth - Open API Authentication
 
Hadoop and Data Access Security
Hadoop and Data Access SecurityHadoop and Data Access Security
Hadoop and Data Access Security
 
Hadoop Internals (2.3.0 or later)
Hadoop Internals (2.3.0 or later)Hadoop Internals (2.3.0 or later)
Hadoop Internals (2.3.0 or later)
 
Hadoop Security Architecture
Hadoop Security ArchitectureHadoop Security Architecture
Hadoop Security Architecture
 
HADOOP TECHNOLOGY ppt
HADOOP  TECHNOLOGY pptHADOOP  TECHNOLOGY ppt
HADOOP TECHNOLOGY ppt
 
Cours Big Data Chap1
Cours Big Data Chap1Cours Big Data Chap1
Cours Big Data Chap1
 

Similaire à Troubleshooting Kerberos in Hadoop: Taming the Beast

Hadoop Security Today and Tomorrow
Hadoop Security Today and TomorrowHadoop Security Today and Tomorrow
Hadoop Security Today and Tomorrow
DataWorks Summit
 

Similaire à Troubleshooting Kerberos in Hadoop: Taming the Beast (20)

Apache Ranger
Apache RangerApache Ranger
Apache Ranger
 
CIS13: Big Data Platform Vendor’s Perspective: Insights from the Bleeding Edge
CIS13: Big Data Platform Vendor’s Perspective: Insights from the Bleeding EdgeCIS13: Big Data Platform Vendor’s Perspective: Insights from the Bleeding Edge
CIS13: Big Data Platform Vendor’s Perspective: Insights from the Bleeding Edge
 
Improvements in Hadoop Security
Improvements in Hadoop SecurityImprovements in Hadoop Security
Improvements in Hadoop Security
 
Curb Your Insecurity - Tips for a Secure Cluster (with Spark too)!!
Curb Your Insecurity - Tips for a Secure Cluster (with Spark too)!!Curb Your Insecurity - Tips for a Secure Cluster (with Spark too)!!
Curb Your Insecurity - Tips for a Secure Cluster (with Spark too)!!
 
Curb your insecurity with HDP
Curb your insecurity with HDPCurb your insecurity with HDP
Curb your insecurity with HDP
 
Curb your insecurity with HDP - Tips for a Secure Cluster
Curb your insecurity with HDP - Tips for a Secure ClusterCurb your insecurity with HDP - Tips for a Secure Cluster
Curb your insecurity with HDP - Tips for a Secure Cluster
 
Practical Kerberos
Practical KerberosPractical Kerberos
Practical Kerberos
 
An Apache Hive Based Data Warehouse
An Apache Hive Based Data WarehouseAn Apache Hive Based Data Warehouse
An Apache Hive Based Data Warehouse
 
Securing the Hadoop Ecosystem
Securing the Hadoop EcosystemSecuring the Hadoop Ecosystem
Securing the Hadoop Ecosystem
 
Practical Kerberos with Apache HBase
Practical Kerberos with Apache HBasePractical Kerberos with Apache HBase
Practical Kerberos with Apache HBase
 
Micro services vs hadoop
Micro services vs hadoopMicro services vs hadoop
Micro services vs hadoop
 
Bridle your Flying Islands and Castles in the Sky: Built-in Governance and Se...
Bridle your Flying Islands and Castles in the Sky: Built-in Governance and Se...Bridle your Flying Islands and Castles in the Sky: Built-in Governance and Se...
Bridle your Flying Islands and Castles in the Sky: Built-in Governance and Se...
 
HBaseConAsia2018 Track2-1: Kerberos-based Big Data Security Solution and Prac...
HBaseConAsia2018 Track2-1: Kerberos-based Big Data Security Solution and Prac...HBaseConAsia2018 Track2-1: Kerberos-based Big Data Security Solution and Prac...
HBaseConAsia2018 Track2-1: Kerberos-based Big Data Security Solution and Prac...
 
Big Data Warehousing Meetup: Securing the Hadoop Ecosystem by Cloudera
Big Data Warehousing Meetup: Securing the Hadoop Ecosystem by ClouderaBig Data Warehousing Meetup: Securing the Hadoop Ecosystem by Cloudera
Big Data Warehousing Meetup: Securing the Hadoop Ecosystem by Cloudera
 
Fortifying Multi-Cluster Hybrid Cloud Data Lakes using Apache Knox
Fortifying Multi-Cluster Hybrid Cloud Data Lakes using Apache KnoxFortifying Multi-Cluster Hybrid Cloud Data Lakes using Apache Knox
Fortifying Multi-Cluster Hybrid Cloud Data Lakes using Apache Knox
 
MiniFi and Apache NiFi : IoT in Berlin Germany 2018
MiniFi and Apache NiFi : IoT in Berlin Germany 2018MiniFi and Apache NiFi : IoT in Berlin Germany 2018
MiniFi and Apache NiFi : IoT in Berlin Germany 2018
 
Hadoop Security Today and Tomorrow
Hadoop Security Today and TomorrowHadoop Security Today and Tomorrow
Hadoop Security Today and Tomorrow
 
Apache NiFi in the Hadoop Ecosystem
Apache NiFi in the Hadoop Ecosystem Apache NiFi in the Hadoop Ecosystem
Apache NiFi in the Hadoop Ecosystem
 
Apache NiFi in the Hadoop Ecosystem
Apache NiFi in the Hadoop EcosystemApache NiFi in the Hadoop Ecosystem
Apache NiFi in the Hadoop Ecosystem
 
Introduction to the Hadoop EcoSystem
Introduction to the Hadoop EcoSystemIntroduction to the Hadoop EcoSystem
Introduction to the Hadoop EcoSystem
 

Plus de DataWorks Summit

HBase Global Indexing to support large-scale data ingestion at Uber
HBase Global Indexing to support large-scale data ingestion at UberHBase Global Indexing to support large-scale data ingestion at Uber
HBase Global Indexing to support large-scale data ingestion at Uber
DataWorks Summit
 
Security Framework for Multitenant Architecture
Security Framework for Multitenant ArchitectureSecurity Framework for Multitenant Architecture
Security Framework for Multitenant Architecture
DataWorks Summit
 
Computer Vision: Coming to a Store Near You
Computer Vision: Coming to a Store Near YouComputer Vision: Coming to a Store Near You
Computer Vision: Coming to a Store Near You
DataWorks Summit
 

Plus de DataWorks Summit (20)

Data Science Crash Course
Data Science Crash CourseData Science Crash Course
Data Science Crash Course
 
Floating on a RAFT: HBase Durability with Apache Ratis
Floating on a RAFT: HBase Durability with Apache RatisFloating on a RAFT: HBase Durability with Apache Ratis
Floating on a RAFT: HBase Durability with Apache Ratis
 
Tracking Crime as It Occurs with Apache Phoenix, Apache HBase and Apache NiFi
Tracking Crime as It Occurs with Apache Phoenix, Apache HBase and Apache NiFiTracking Crime as It Occurs with Apache Phoenix, Apache HBase and Apache NiFi
Tracking Crime as It Occurs with Apache Phoenix, Apache HBase and Apache NiFi
 
HBase Tales From the Trenches - Short stories about most common HBase operati...
HBase Tales From the Trenches - Short stories about most common HBase operati...HBase Tales From the Trenches - Short stories about most common HBase operati...
HBase Tales From the Trenches - Short stories about most common HBase operati...
 
Optimizing Geospatial Operations with Server-side Programming in HBase and Ac...
Optimizing Geospatial Operations with Server-side Programming in HBase and Ac...Optimizing Geospatial Operations with Server-side Programming in HBase and Ac...
Optimizing Geospatial Operations with Server-side Programming in HBase and Ac...
 
Managing the Dewey Decimal System
Managing the Dewey Decimal SystemManaging the Dewey Decimal System
Managing the Dewey Decimal System
 
Practical NoSQL: Accumulo's dirlist Example
Practical NoSQL: Accumulo's dirlist ExamplePractical NoSQL: Accumulo's dirlist Example
Practical NoSQL: Accumulo's dirlist Example
 
HBase Global Indexing to support large-scale data ingestion at Uber
HBase Global Indexing to support large-scale data ingestion at UberHBase Global Indexing to support large-scale data ingestion at Uber
HBase Global Indexing to support large-scale data ingestion at Uber
 
Scaling Cloud-Scale Translytics Workloads with Omid and Phoenix
Scaling Cloud-Scale Translytics Workloads with Omid and PhoenixScaling Cloud-Scale Translytics Workloads with Omid and Phoenix
Scaling Cloud-Scale Translytics Workloads with Omid and Phoenix
 
Building the High Speed Cybersecurity Data Pipeline Using Apache NiFi
Building the High Speed Cybersecurity Data Pipeline Using Apache NiFiBuilding the High Speed Cybersecurity Data Pipeline Using Apache NiFi
Building the High Speed Cybersecurity Data Pipeline Using Apache NiFi
 
Supporting Apache HBase : Troubleshooting and Supportability Improvements
Supporting Apache HBase : Troubleshooting and Supportability ImprovementsSupporting Apache HBase : Troubleshooting and Supportability Improvements
Supporting Apache HBase : Troubleshooting and Supportability Improvements
 
Security Framework for Multitenant Architecture
Security Framework for Multitenant ArchitectureSecurity Framework for Multitenant Architecture
Security Framework for Multitenant Architecture
 
Presto: Optimizing Performance of SQL-on-Anything Engine
Presto: Optimizing Performance of SQL-on-Anything EnginePresto: Optimizing Performance of SQL-on-Anything Engine
Presto: Optimizing Performance of SQL-on-Anything Engine
 
Introducing MlFlow: An Open Source Platform for the Machine Learning Lifecycl...
Introducing MlFlow: An Open Source Platform for the Machine Learning Lifecycl...Introducing MlFlow: An Open Source Platform for the Machine Learning Lifecycl...
Introducing MlFlow: An Open Source Platform for the Machine Learning Lifecycl...
 
Extending Twitter's Data Platform to Google Cloud
Extending Twitter's Data Platform to Google CloudExtending Twitter's Data Platform to Google Cloud
Extending Twitter's Data Platform to Google Cloud
 
Event-Driven Messaging and Actions using Apache Flink and Apache NiFi
Event-Driven Messaging and Actions using Apache Flink and Apache NiFiEvent-Driven Messaging and Actions using Apache Flink and Apache NiFi
Event-Driven Messaging and Actions using Apache Flink and Apache NiFi
 
Securing Data in Hybrid on-premise and Cloud Environments using Apache Ranger
Securing Data in Hybrid on-premise and Cloud Environments using Apache RangerSecuring Data in Hybrid on-premise and Cloud Environments using Apache Ranger
Securing Data in Hybrid on-premise and Cloud Environments using Apache Ranger
 
Big Data Meets NVM: Accelerating Big Data Processing with Non-Volatile Memory...
Big Data Meets NVM: Accelerating Big Data Processing with Non-Volatile Memory...Big Data Meets NVM: Accelerating Big Data Processing with Non-Volatile Memory...
Big Data Meets NVM: Accelerating Big Data Processing with Non-Volatile Memory...
 
Computer Vision: Coming to a Store Near You
Computer Vision: Coming to a Store Near YouComputer Vision: Coming to a Store Near You
Computer Vision: Coming to a Store Near You
 
Big Data Genomics: Clustering Billions of DNA Sequences with Apache Spark
Big Data Genomics: Clustering Billions of DNA Sequences with Apache SparkBig Data Genomics: Clustering Billions of DNA Sequences with Apache Spark
Big Data Genomics: Clustering Billions of DNA Sequences with Apache Spark
 

Dernier

Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
WSO2
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(☎️+971_581248768%)**%*]'#abortion pills for sale in dubai@
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Victor Rentea
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
panagenda
 

Dernier (20)

FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor Presentation
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
Platformless Horizons for Digital Adaptability
Platformless Horizons for Digital AdaptabilityPlatformless Horizons for Digital Adaptability
Platformless Horizons for Digital Adaptability
 
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Vector Search -An Introduction in Oracle Database 23ai.pptx
Vector Search -An Introduction in Oracle Database 23ai.pptxVector Search -An Introduction in Oracle Database 23ai.pptx
Vector Search -An Introduction in Oracle Database 23ai.pptx
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamDEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
 
Introduction to Multilingual Retrieval Augmented Generation (RAG)
Introduction to Multilingual Retrieval Augmented Generation (RAG)Introduction to Multilingual Retrieval Augmented Generation (RAG)
Introduction to Multilingual Retrieval Augmented Generation (RAG)
 
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
 
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot ModelMcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
 
Understanding the FAA Part 107 License ..
Understanding the FAA Part 107 License ..Understanding the FAA Part 107 License ..
Understanding the FAA Part 107 License ..
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 

Troubleshooting Kerberos in Hadoop: Taming the Beast

  • 1. 1 © Hortonworks Inc. 2011 – 2017. All Rights Reserved Troubleshooting Kerberos In Hadoop : Taming the Beast DataWorks Summit Sept 2017
  • 2. 2 © Hortonworks Inc. 2011 – 2017. All Rights Reserved Author Profile Vipin Rathor Sr. Product Specialist (HDP Security) Contributed to Kerberos, Apache Zeppelin, Apache Atlas vrathor@hortonworks.com / @VipinRathor46
  • 3. 3 © Hortonworks Inc. 2011 – 2017. All Rights Reserved Agenda • Why Kerberos? • Where is Kerberos used across the Hadoop Stack? • What is Kerberos & how does it work • Realms, Principals and Keytabs • Systematic Approach to Kerberos Nirvana • Tools available in Hadoop • Native Kerberos Tools / Debug Options • Kerberos Checklist • Most Common Kerberos Error Messages (& their meanings)
  • 4. 4 © Hortonworks Inc. 2011 – 2017. All Rights Reserved Why Kerberos? • Universal Authentication mechanism for Hadoop stack • Integrates with enterprise user management (e.g. Active Directory) Solves: • How can parts of a cluster trust each other (NameNodes, DataNodes, YARN, HBase, ZooKeeper...) • How can users trust the system? • How can the system trust users? • Foundation for: how can users delegate rights to applications? • Without Kerberos: your cluster has NO security Hadoop clusters are some of the largest Kerberos systems ever!!
  • 5. 5 © Hortonworks Inc. 2011 – 2017. All Rights Reserved Where is Kerberos used across the Hadoop Stack? • Ubiquitous End-User / Hadoop Service Authentication mechanism • Hadoop DelegationToken (Delegated authentication to NameNode) • != Kerberos Tickets • Bootstrapped with Kerberos authentication token • HTTP Authentication • Using SPNEGO (RFC 4559) • Via Browsers / cURL (curl --negotiate) • RPC Authentication • Using Simple Authentication & Security Layer aka SASL (!= SSL) • Java API Based Kerberos login • Using JGSS / JAAS • GSS-API (RFC 2743)
  • 6. 6 © Hortonworks Inc. 2011 – 2017. All Rights Reserved What is Kerberos • Open source, Developed by MIT • Password is NEVER transmitted over wire • Central trusted authority – Key Distribution Center (KDC) • Symmetric key (common shared key) • Flavors: • MIT Kerberos • Active Directory • Heimdal Kerberos (OS X)
  • 7. 7 © Hortonworks Inc. 2011 – 2017. All Rights Reserved How does Kerberos work End User - Does kinit (1 & 2) - Runs HDFS command (3 - 6) Hadoop NameNode - Starts up with nn.service.keytab - Verifies user and gives access to HDFS KDC - Provisions user keys and service keytabs (e.g. nn.service.keytab) - Provides TGT and TGS
  • 8. 8 © Hortonworks Inc. 2011 – 2017. All Rights Reserved Realms, Principals and Keytabs • Realm • User Principal • E.g. user1@HWX.COM • ken/admin@HWX.COM • ken/sandbox.hortonworks.com@HWX.COM • Service Principal • E.g. HTTP/sandbox.hortonworks.com@HWX.COM • nn/node1.hortonworks.com@HWX.COM • dn/node2.hortonworks.com@HWX.COM • dn/_HOST@HWX.COM • Keytabs • Service keytabs (for service) • Headless keytabs (for user)
  • 9. 9 © Hortonworks Inc. 2011 – 2017. All Rights Reserved Systematic Approach to Kerberos Nirvana • Identify the involved parties (user, service, keytabs, nodes) • Identify the stage where Kerberos is failing • Based on stage & error message, narrow down between client-side or service- side issue • Check & verify configurations for correctness using the appropriate tools • Repeat as necessary
  • 10. 10 © Hortonworks Inc. 2011 – 2017. All Rights Reserved Kerberos Tools Available in Hadoop • Kdiag • Runs a series of diagnostic checks & gives suggestions • hadoop org.apache.hadoop.security.KDiag
  • 11. 11 © Hortonworks Inc. 2011 – 2017. All Rights Reserved Kerberos Tools Available in Hadoop (cntd..) • HadoopKerberosName • Checks Auth_to_local rules (Kerberos Principal to Unix user name conversion) • hadoop org.apache.hadoop.security.HadoopKerberosName nn/bali1.openstacklocal@LAB.HORTONWORKS.NET
  • 12. 12 © Hortonworks Inc. 2011 – 2017. All Rights Reserved Native Kerberos Tools / Debug Options • via command line • kinit • klist -eaf / klist –kte • kvno • kdestroy • export KRB5_TRACE=/tmp/krb5-curl.out curl -ivL --negotiate -u: "http://namenode-host:50070/webhdfs/v1/?op=LISTSTATUS" • via debug messages • export HADOOP_JAAS_DEBUG=true • export HADOOP_ROOT_LOGGER=DEBUG,console • via Java library • -Dsun.security.krb5.debug=true • -Dsun.security.spnego.debug=true • export OPTS=“$OPTS -Dsun.security.krb5.debug=true”
  • 13. 13 © Hortonworks Inc. 2011 – 2017. All Rights Reserved Kerberos Checklist • FQDN • Name Resolution • If DNS is configured, then check reverse lookup • Date/Time sync (< 5 minutes) • Configuration file - /etc/krb5.conf • Principal Names • Stale Keytabs (via kvno) • Credential Cache location (JAAS config) • Which Java suite, JCE policy • KDC log file - /var/log/kerberos/krb5kdc.log
  • 14. 14 © Hortonworks Inc. 2011 – 2017. All Rights Reserved Most Common Kerberos Error Messages (& their meaning) • <unknown client> for <unknown service>  • Decrypt Integrity Check Failed • AES256 EncType not supported • Clock skew too great • Kerberos service principal not found in the database • Client not found in the database • No valid initial credential found
  • 15. 15 © Hortonworks Inc. 2011 – 2017. All Rights Reserved References • http://web.mit.edu/kerberos/ • http://www.kerberos.org/software/tutorial.html • https://github.com/steveloughran/kerberos_and_hadoop
  • 16. 16 © Hortonworks Inc. 2011 – 2017. All Rights Reserved Thank you !

Notes de l'éditeur

  1. Realms = Domain in Active Directory KDC makes no differentiation between user principals and service principals. Goes same for the keytabs too.