Member since
10-01-2015
3933
Posts
1150
Kudos Received
374
Solutions
My Accepted Solutions
| Title | Views | Posted |
|---|---|---|
| 3655 | 05-03-2017 05:13 PM | |
| 3013 | 05-02-2017 08:38 AM | |
| 3273 | 05-02-2017 08:13 AM | |
| 3219 | 04-10-2017 10:51 PM | |
| 1684 | 03-28-2017 02:27 AM |
02-26-2016
02:13 AM
@Ofer Mendelevith @scasey any insight?
... View more
02-26-2016
02:12 AM
1 Kudo
it may be my data that causes the problem as I had to create my own table with the downloaded dataset so I used my own discretion. When I run the following code DEFINE HCatLoader org.apache.hive.hcatalog.pig.HCatLoader();
DEFINE SampleByKey datafu.pig.sampling.SampleByKey('0.2');
ROWS = load 'medicare_part_b.medicare_part_b_2013_raw' using HCatLoader();
SAMPLE_BY_PROVIDERS = filter ROWS by SampleByKey(npi);
rmf medicare_part_b/ex2_by_npi_sample;
STORE SAMPLE_BY_PROVIDERS into 'medicare_part_b/ex2_by_npi_sample' using PigStorage(','); I get the following error 2016-02-26 02:07:58,053 [main] ERROR org.apache.pig.tools.grunt.Grunt - ERROR 1002: Unable to store alias SAMPLE_BY_PROVIDERS
Details at logfile: /root/pig_1456451995224.log
the log file shows this Pig Stack Trace
---------------
ERROR 1002: Unable to store alias SAMPLE_BY_PROVIDERS
org.apache.pig.impl.logicalLayer.FrontendException: ERROR 1002: Unable to store alias SAMPLE_BY_PROVIDERS
at org.apache.pig.PigServer$Graph.registerQuery(PigServer.java:1694)
at org.apache.pig.PigServer.registerQuery(PigServer.java:623)
at org.apache.pig.tools.grunt.GruntParser.processPig(GruntParser.java:1082)
at org.apache.pig.tools.pigscript.parser.PigScriptParser.parse(PigScriptParser.java:505)
at org.apache.pig.tools.grunt.GruntParser.parseStopOnError(GruntParser.java:230)
at org.apache.pig.tools.grunt.GruntParser.parseStopOnError(GruntParser.java:205)
at org.apache.pig.tools.grunt.Grunt.run(Grunt.java:66)
at org.apache.pig.Main.run(Main.java:565)
at org.apache.pig.Main.main(Main.java:177)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.apache.hadoop.util.RunJar.run(RunJar.java:221)
at org.apache.hadoop.util.RunJar.main(RunJar.java:136)
Caused by: org.apache.pig.backend.executionengine.ExecException: ERROR 0: java.lang.NullPointerException
at org.apache.pig.backend.hadoop.executionengine.HExecutionEngine.launchPig(HExecutionEngine.java:310)
at org.apache.pig.PigServer.launchPlan(PigServer.java:1390)
at org.apache.pig.PigServer.executeCompiledLogicalPlan(PigServer.java:1375)
at org.apache.pig.PigServer.execute(PigServer.java:1364)
at org.apache.pig.PigServer.access$500(PigServer.java:113)
at org.apache.pig.PigServer$Graph.registerQuery(PigServer.java:1689)
... 14 more
Caused by: java.lang.NullPointerException
Caused by: java.lang.NullPointerException
at datafu.pig.sampling.SampleByKey.setUDFContextSignature(SampleByKey.java:86)
at org.apache.pig.backend.hadoop.executionengine.physicalLayer.expressionOperators.POUserFunc.setSignature(POUserFunc.java:611)
at org.apache.pig.backend.hadoop.executionengine.physicalLayer.expressionOperators.POUserFunc.instantiateFunc(POUserFunc.java:125)
at org.apache.pig.backend.hadoop.executionengine.physicalLayer.expressionOperators.POUserFunc.<init>(POUserFunc.java:120)
at org.apache.pig.newplan.logical.expression.ExpToPhyTranslationVisitor.visit(ExpToPhyTranslationVisitor.java:505)
at org.apache.pig.newplan.logical.expression.UserFuncExpression.accept(UserFuncExpression.java:113)
at org.apache.pig.newplan.ReverseDependencyOrderWalkerWOSeenChk.walk(ReverseDependencyOrderWalkerWOSeenChk.java:69)
at org.apache.pig.newplan.logical.relational.LogToPhyTranslationVisitor.visit(LogToPhyTranslationVisitor.java:223)
at org.apache.pig.newplan.logical.relational.LOFilter.accept(LOFilter.java:79)
at org.apache.pig.newplan.DependencyOrderWalker.walk(DependencyOrderWalker.java:75)
at org.apache.pig.newplan.PlanVisitor.visit(PlanVisitor.java:52)
at org.apache.pig.backend.hadoop.executionengine.HExecutionEngine.compile(HExecutionEngine.java:260)
at org.apache.pig.backend.hadoop.executionengine.HExecutionEngine.launchPig(HExecutionEngine.java:295)
... 19 more
does not work in TEZ or MAPREDUCE mode scheme for the relation SAMPLE_BY_PROVIDERS grunt> DESCRIBE SAMPLE_BY_PROVIDERS;
SAMPLE_BY_PROVIDERS: {npi: chararray,nppes_provider_last_org_name: chararray,nppes_provider_first_name: chararray,nppes_provider_mi: chararray,nppes_credentials: chararray,nppes_provider_gender: chararray,nppes_entity_code: chararray,nppes_provider_street1: chararray,nppes_provider_street2: chararray,nppes_provider_city: chararray,nppes_provider_zip: chararray,nppes_provider_state: chararray,nppes_provider_country: chararray,provider_type: chararray,medicare_participation_indicator: chararray,places_of_service: chararray,hcpcs_code: chararray,hcpcs_desc: chararray,hcpcs_drug_indicator: chararray,line_srvc_cnt: int,bene_unique_cnt: int,bene_day_srvc_cnt: int,average_medicare_all_owed_amt: chararray,average_submitted_chrg_amt: chararray,stdev_submitted_chrg_amt: chararray,average_medicare_payment_amt: chararray,stdev_medicare_payment_amt: chararray}
... View more
Labels:
- Labels:
-
Apache Hive
-
Apache Pig
02-25-2016
10:49 PM
Found this https://github.com/wdavidw/webhdfs-java-client Personally why not just use java hdfs api? http://tutorials.techmytalk.com/2014/08/16/hadoop-hdfs-java-api/
... View more
02-25-2016
06:26 PM
no, you install master services as well. Spark History for example is a service. I don't have access to an installation right now otherwise I'd shown you install steps. Basically components are categorized by clients and master services. You check and uncheck which machines will serve as what. @Smart Solutions
... View more
02-25-2016
05:04 PM
1 Kudo
@Smart Solutions you will have to select where you want Spark History Server to run and which machines to install Spark clients on. There is a page further down the road that will allow you to pick which nodes to select what on. For example on Sandbox, if I click either URL below, will take me to sandbox.hortonworks.com, on your cluster, URLs will point to whatever servers you defined.
... View more
02-25-2016
05:00 PM
@Sunile Manjee just to clarify, you can place the jars anywhere but it's most convenient in the lib folder as Pig will see them. You can also take a look at this example https://community.hortonworks.com/questions/16415/pig-erro-execution.html#comment-16550
... View more
02-25-2016
04:56 PM
@Saurabh Kumar please see my answer, as well as this link https://community.hortonworks.com/content/idea/2391/pig-and-hive-actions-should-include-hive-hcatalog.html
... View more
02-25-2016
04:50 PM
@Xi Sanderson definitely open a support ticket and use smartsense to collect logs. Take a look in your /var/log/hive for metastore specific logs and paste errors from there here. Maybe we can help.
... View more
02-25-2016
04:46 PM
1 Kudo
@Sunile Manjee you need to download the jars for third party libs, they're not shipped with HDP by default. So in case of Parquet, download it from their site and place in /usr/hdp/current/pig-client/lib. You might actually have to build Parquet from source. https://github.com/Parquet/parquet-mr
... View more
02-25-2016
03:49 PM
@Xi Sanderson please paste the logs for hive and whatever other alerts are being referenced. We can't debug without more detail. Do you have support account with Hortonworks? We recommend you enable SmartSense proactive monitoring as well as open tickets for individual problems if we are not able to address it here.
... View more