The Hortonworks Community Connection is now live. A completely rebuilt Q&A forum, Knowledge Base, Code Hub and more, backed by the experts in the industry.

You will be redirected here in 10 seconds. If your are not redirected, click here to visit the new site.

The legacy Hortonworks Forum is now closed. You can view a read-only version of the former site by clicking here. The site will be taken offline on January 31,2016

Hive / HCatalog Forum

Hive C# driver

  • #40571
    Ken Ross

    Hi guys,

    I’ve been playing around with the Microsoft Hadoop .Net SDK ( and have the WebHDFS connection working to copy data locally from my computer into HDFS on the sandbox.

    What I’m now trying to figure out is how to connect to Hive as shown here:

    When I try using Linq to Hive I keep getting .Net exceptions.

    When I try to simplify the code and do:

    var db = new HiveConnection(
    webHCatUri: new Uri("http://sandbox:50111"),
    userName: (string)"hue", password: "1111");

    var result = db.ExecuteHiveQuery("select * from sample_07;");

    I can see it running in the job tracker, but it errors out, the log looks like this: No FileSystem for scheme: asv
    at org.apache.hadoop.fs.FileSystem.createFileSystem(
    at org.apache.hadoop.fs.FileSystem.access$200(
    at org.apache.hadoop.fs.FileSystem$Cache.get(
    at org.apache.hadoop.fs.FileSystem.get(
    at org.apache.hadoop.fs.Path.getFileSystem(
    at org.apache.hcatalog.templeton.tool.TempletonControllerJob$Watcher.(
    at org.apache.hcatalog.templeton.tool.TempletonControllerJob$LaunchMapper.executeWatcher(
    at org.apache.hcatalog.templeton.tool.TempletonControllerJob$
    at org.apache.hadoop.mapred.MapTask.runNewMapper(
    at org.apache.hadoop.mapred.Child$
    at Method)
    at org.apache.hadoop.mapred.Child.main(

    Does anyone have any ideas on how to run a hive query from c#?

  • Author
  • #41132
    Yi Zhang

    Hi Ken,

    Have you tried connecting to hive through hive’s thrift api?

    Is this sandbox running on Azure? ‘the filesystem for schema: asv’ message indicates a configuration that is not pointed to hdfs filesystem schema.
    Another possibility is the doAs, which normally suggest permissions issue.

    What about trying uri of http://sandbox:50111/v1/hive


The forum ‘Hive / HCatalog’ is closed to new topics and replies.

Support from the Experts

A HDP Support Subscription connects you experts with deep experience running Apache Hadoop in production, at-scale on the most demanding workloads.

Enterprise Support »

Become HDP Certified

Real world training designed by the core architects of Hadoop. Scenario-based training courses are available in-classroom or online from anywhere in the world

Training »

Hortonworks Data Platform
The Hortonworks Data Platform is a 100% open source distribution of Apache Hadoop that is truly enterprise grade having been built, tested and hardened with enterprise rigor.
Get started with Sandbox
Hortonworks Sandbox is a self-contained virtual machine with Apache Hadoop pre-configured alongside a set of hands-on, step-by-step Hadoop tutorials.
Modern Data Architecture
Tackle the challenges of big data. Hadoop integrates with existing EDW, RDBMS and MPP systems to deliver lower cost, higher capacity infrastructure.