Member since
07-19-2018
613
Posts
101
Kudos Received
117
Solutions
My Accepted Solutions
| Title | Views | Posted |
|---|---|---|
| 5099 | 01-11-2021 05:54 AM | |
| 3423 | 01-11-2021 05:52 AM | |
| 8790 | 01-08-2021 05:23 AM | |
| 8386 | 01-04-2021 04:08 AM | |
| 36699 | 12-18-2020 05:42 AM |
04-09-2020
11:52 AM
1 Kudo
@bhara You do not have to use LDAP. You can create the users in HUE admin, using the first admin user you created. If you want to configure LDAP please see official documentation here: https://docs.gethue.com/administrator/configuration/server/#ldap You will need to make the LDAP hue.ini changes via ambari in the HUE->Config->Advanced->Advanced Hue-Ini and restart hue after each change. Your error above are 2 issues I notice: SSL Configuration for HDFS. Your HUE truststore must have the ssl certs for hdfs hosts https://gethue.com/configure-hue-with-https-ssl/ (bottom section) https://docs.cloudera.com/documentation/enterprise/5-11-x/topics/cm_sg_ssl_hue.html (top section) HDFS Configuration - Doc Here The SSL Example links above are not specific to your case (HDP) but still apply. Also I am assuming you have hdfs secure. The links I share for SSL outline the fundamentals required to put the right HDFS and SSL settings in hue.ini for secure access to hdfs. The HDFS Configuration link is official gethue.com documentation for HDFS. You will need to make the SSL hue.ini changes via ambari in the HUE->Config->Advanced->Advanced Hue-Ini and restart hue after each change.
... View more
04-08-2020
01:26 PM
1 Kudo
@ForrestGump there must be some configuration difference then. I created a simple flow and was able to get below output using exact proc I screen shot above on your Before data: Year,Day,Hour,Minute,ID_for_SW_Plasma_spacecraft,Percent_of_interpolation,Timeshift,RMS_Timeshift,RMS_Min_var,Time_btwn_observation_sec,Field_magnutude_average_nT,BY_nT(GSM),BZ_nT_(GSM),RMS_SD_B_scalar_nT,RMS_SD_field_vector_nT,Speed_km/s,Alfven_mach_number,Magnetosonic_Mach_number,BSN_location_Xgse_Re,2019,1,0,0,51,100,2788,164,0.12,999999,5.11,2.00,2.73,0.08,1.03,451.0,9.8,6.5,13.15 2019,1,0,1,51,100,2810,159,0.12,37,5.10,2.33,2.58,0.11,1.04,451.3,9.8,6.5,13.10 2019,1,0,2,51,80,2852,109,0.09,18,4.86,2.37,2.56,0.12,0.56,454.7,10.3,6.7,13.07 2019,1,0,3,51,67,2951,66,0.06,-39,4.78,2.21,2.55,0.03,0.33,452.3,11.0,6.8,13.00 2019,1,0,4,51,100,3025,7,0.00,-13,4.80,2.17,2.37,0.03,0.14,451.4,11.2,6.8,13.00 2019,1,0,5,99,80,2973,111,0.09,111,4.94,2.68,2.39,0.13,0.55,99999.9,999.9,99.9,13.19 2019,1,0,6,51,67,3074,20,0.02,-40,4.88,2.54,2.01,0.02,0.28,451.0,9.8,6.5,13.27 2019,1,0,7,51,50,3114,9,0.00,19,4.82,2.37,2.93,0.02,0.14,451.0,9.9,6.5,13.29 2019,1,0,8,99,999,999999,999999,99.99,999999,9999.99,9999.99,9999.99,9999.99,9999.99,99999.9,999.9,99.9,9999.99 2019,1,0,9,99,100,3036,0,0.00,999999,5.16,3.34,2.44,0.00,0.00,99999.9,999.9,99.9,13.24 2019,1,0,10,99,100,3036,0,0.00,60,5.16,3.34,2.43,0.00,0.00,99999.9,999.9,99.9,13.24 I have dropped the template for you here: https://github.com/steven-dfheinz/NiFi-Templates/blob/master/Replace_Text_Demo.xml
... View more
04-08-2020
12:47 PM
1 Kudo
@bhara Change the line 193 below and try to start again. File:/var/lib/ambari-agent/cache/common-services/HUE/4.6.0/package/scripts/params.py dfs_namenode_http_address = config['configurations']['hdfs-site']['dfs.namenode.http-address'] to dfs_namenode_http_address = 'localhost' That will give dfs_namenode_http_address a value and get past the error.
... View more
04-08-2020
12:06 PM
@Pe If you have a new question, you can post it and reference the article. However, since im already responding, I will be brief. Yes, all dev, test,prod to usually Prod NiFi Registry. Or sometimes all to Dev, your preference. To connect to existing keystores, would just add the new certs from the nifi registry host to all the other existing keystores/truststores.
... View more
04-08-2020
11:51 AM
Notice my settings for All Properties and I use Regex. If you don't want to use Regex, change Replacement Strategy. I would recommend doing it as I have shown, with regex on complete flow file. Not line by line. Also, you can append and prepend more text and transformations in same replace too. For Example: PREPEND ${'$1':replace('"',''):replace(',',' '):replace('\n',',\n')} APPEND
... View more
04-08-2020
10:00 AM
@ForrestGump I believe you are using ReplaceText. I use it like this:
... View more
04-08-2020
06:17 AM
@unrec I would recommend and absolute path outside of the nifi folder. Then provide the full path inside the processor not using "." which is causing your conflict. This folder should be writeable and owned to nifi.
... View more
04-08-2020
03:35 AM
1 Kudo
The creation of large database schemas can be a very complicated task. In this article, I am going to share how I used NiFi to fully automate a monstrous task. For my project, I needed to create very large Avro Schemas, and corresponding Hive Tables for five or more Data Sources, each having from 400-500+ different CSV columns. Doing this manually would have been a nightmare just to manage the initial schema creations. Managing schema changes an even bigger task over time. My answer was the Schema Generator API using NiFi and Schema Registry.
Please reference the following NiFi Template:
Schema Generator API Demo Template
Schema Generator API
The above NiFi template provides the following capabilities:
A NiFi API is capable of the following:
Accepting POST for a new table, given the tables data columns and data types is in CSV Format
Creating Schema Registry Entity (POST: create)
Creating Schema Registry Avro Schema (POST: parse)
Creating Hive HQL Schema
Executing Hive HQL Statement
A sample call to create Schema Registry Entity (demo).
A sample call to parse Data Columns (22 string columns).
Lots of helpful labels with notes.
The following are the template setup instructions:
Download, Upload Template, and Drag Template to your NiFi Pallette.
Make sure a Schema Registry is Setup within reach of NiFi.
Edit the following Schema Generator Demo Process Group's Variables:
schemaGeneratorApiHost
schemaGeneratorApiPort
schemaRegistryUrl
hiveDatabaseName
hiveDatabaseConnectionUrl (jdbc string)
hiveConfigurationResources (path to hive-site.xml)
Enable controller services in Schema Generator API process group:
StandardHttpContextMap for HandleHttpRequest & Response
HiveConnectionPool for PutHiveQl
Start Schema Generator API Processor group.
Navigate to samples and execute Sample Call 1, then 2 by switching appropriate GenerateFlowFile On/Off. These 2 proc are disabled by default as you should switch them On and Off immediately. These are the only 2 proc that should not always run. Disable them again when done.
This is just a basic demonstration to get you started with Schema Registry and Data Source Schema Automation. Parts of this template are also helpful for anyone who needs to automate creating Avro Schemas and/or Hive Schemas for large CSVs which could still be done without Schema Registry. The demo above has been tested up to 500 columns and includes mapping various different column types to hive data types.
Important Information
The template is built and tested on NiFi 1.9, Single Node Nifi Cluster, with local Schema Registry Installed.
The Schema Registry UI doesn't have full capability. Learn the API to work with your Schemas Directly. For Example: Delete. See my previous post Using the Schema Registry API for detailed API info.
Versioning Schema Forward and Backward can be very problematic. Be Warned.
Use a proper and consistent table and column naming conventions. Complicated column names will break Avro and Hive. Example characters include but not limited to: spaces, /, \, $, *, [, ], (, ), etc.
Schema Registry Entities and Associated Avro Schemas can be used in NiFi Record Readers, using HortonworksSchemaRegistry, and other Controller Services.
... View more
Labels:
04-07-2020
07:05 AM
In a recent Use Case of NiFi + ELK, we route all failures for ELK Processors to a Replay Process Group. If any failures, we have a notification, and collect them in a replay queue that is disabled. Once the notification is seen, and or some corrective action taken to make sure there are no issues, a user logs in and enables queue, which routes back to original processor to execute again. I hope a similar setup can help resolve your issue.
... View more
04-03-2020
10:11 AM
@bhara No problem. Glad I could help and I appreciate your feedback too. When you do get it started, the setup and configuration is going to need similar attention. Please keep me updated and/or reach out in Private Messages. You can always open new Questions here and tag me in them too.
... View more