Our Community is getting an upgrade! To get everything ready for the relaunch, we’ll be placing the site in read-only mode starting September 21st.
We really appreciate your understanding while we get things set up behind the scenes. Catch up on all the exciting details about the move here.
Need help or have questions? Drop us a line at [email protected]

Community Articles

Find and share helpful community-sourced technical articles.
Announcements
Share your experience with Cloudera on G2 and get a $25 Amazon Gift card.
Hi, I'm CLEO! Something exciting is coming to the Community. Stay Tuned!
Labels (1)
avatar
Master Guru

 

2020-08-11_15-24-24.jpgImage Courtesy: 

I recently ran into a scenario where I needed to gather Hive logs on the new Data Warehouse Experience on AWS.   The "old" way of fetching logs was to SSH into the nodes. Data Warehouse Experience is now deployed on K8s, so SSHing is off the table. Therefore a tool like K9s is key. This is a raw article to quickly demonstrate how to use K9s to fetch Data Warehouse Experience logs which are deployed on AWS K8s

Prerequisites

  • Data Warehouse Experience
  • K9s installed on your machine 
  • AWS ARN (instructions provided below)
  • AWS configure (CLI) pointing to your AWS env.  Simply type AWS configure via CLI and point to the correct AWS subscription

AWS ARN

Your AWS ARN is required to successfully connect K9s to CDW(DW-X)

  1. On AWS, go to IAM > Users > Search for your user name:2020-08-12_10-49-45.jpg
  2. Click on your username to fetch the ARN:2020-08-12_10-49-57.jpg

Kubeconfig

  1. Connecting to DW-X using K9s requires kubeconfig. DW-X makes this available under DW-X-> Environments > Your Environment > Show Kubeconfig. 
  2. Click on the copy option and make the contents available within a file in your machine file system.  For example, I stored the kubeconfig contents here: 
    /Users/sunile.manjee/.k9s/kubeconfig.yml​

    2020-08-11_15-26-34.jpg

 

 

 

 

 

 

 

 



ARN

To access K8s from K9s, your ARN will need to be added under Grant Access:2020-08-11_15-29-25.jpg

 

 

 

 

 

 

 

 

 

 

 

 

 

 



K9s

Now all is set up to connect to DW-X K8s using K9s.   Reference kubeconfig.yml file when using K9s

 

 

k9s --kubeconfig /Users/sunile.manjee/.k9s/kubeconfig.yml

 

 

2020-08-11_15-35-04.jpg

 

 

 

 

 

 

 

 

 

 

That's it. From here the logs are made available and a ton of other metrics.  For more information on how to use K9s, see k9scli.io

4,106 Views
Version history
Last update:
‎08-14-2020 01:17 AM
Updated by: