HDP on Windows – Other Forum

Python Errors

  • #50739
    S R
    Participant

    I installed HDP 2.0 in Win 2012 Standard R2 Server as a Single Node Cluster. Downloaded the latest Python software 3.4.0 and JDK 1.8.0 Smoke Tests were failing (following err message) and I went to command line and tried the following command to see existing databases

    c:\hdp\hcatalog-0.12.0.2.0.6.0-0009\bin>hcat.py -e “Show Databases”
    File “C:\hdp\hcatalog-0.12.0.2.0.6.0-0009\bin\hcat.py”, line 143
    print “Would run:”
    ^
    SyntaxError: invalid syntax

    If anyone encountered the same issue and resolved, please let me know and appreciate it.

    Thanks

to create new topics or reply. | New User Registration

  • Author
    Replies
  • #50744
    Rohit Bakhshi
    Moderator

    Hi S R,

    Can you please try the install with Python 2.7.x? We have not certified with Python 3.x, and that is different enough from Python 2.7 that I don’t see Python 3.x working.

    Thanks,
    Rohit

    #50746
    S R
    Participant

    Thank You Rohit ! Will Uninstall latest Python Version and go back to Older version and test it out. Appreciate your quick response !

    #50747
    S R
    Participant

    Rohit – After Installing 2.7.6 Version of Python, the issue is resolved and Thank you. Currently the only Smoke Test that’s failing is WebHCatSmokeTest .

    Calling URL: http://WIN-ATKSGSRL5DL:50111/templeton/v1/ddl/database?user.name=hadoop
    Response: -1
    Data:
    Run-WebHcatSmokeTest : WebHcat Smoke Test: FAILED
    At line:1 char:1
    + Run-WebHcatSmokeTest
    + ~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo : NotSpecified: (:) [Write-Error], WriteErrorException
    + FullyQualifiedErrorId : Microsoft.PowerShell.Commands.WriteErrorException,Run-WebHcatSmokeTest

    #50752
    S R
    Participant

    WebHCatSmokeTest issue is resolved. This might help others if they have similar issue that I faced

    When I first installed Python 3.4, looks like the webhcat-site.xml (under C:\hdp\hcatalog-0.12.0.2.0.6.0-0009\etc\webhcat) file is updated with the following entry as part of the HDP 2.0 installation process.

    <property>
    <name>templeton.python</name>
    <value>C:\Python34\python.exe</value>
    </property>

    I Uninstalled the Python 3.4 and installed Python 2.7 as suggested and updated the “PATH” Environmental value to c:\python27\
    I updated the the Property value to

    <property>
    <name>templeton.python</name>
    <value>c:\python27\python.exe</value>
    </property>

    Note that I had to STOP and START the Services for the new values to be picked up. If not the old values are being cached and simple Property update may not help. Hope this helps !

    Thanks. Satya Raju.

You must be to reply to this topic. | Create Account

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.