Uploaded image for project: 'Hive'
  1. Hive
  2. HIVE-17654

Beeline dfs -get retrieved file on Hiveserver2 server at /home/hiveserver2 location.

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 2.1.0
    • None
    • Beeline
    • None
    • Centos6.8. VM. Remote Desktop connected to hiveserver2.

    Description

      Hello,

      An user tried to retrieved an HDFS files from Beeline to its local /home/

      {user}

      repository. For that he used the `dfs -get /hdfs/path/to/file.csv file.csv` command from beeline client.
      First try, it seems to work. The ouput is the following:
      -------------+
      DFS Output |
      -------------+
      -------------+

      Second and furthur tries lead to the following error:
      Error: Error while processing statement: null (state=,code=1)

      It seems that the error was due to the file already existing in the current folder. However he couldn't find the file in its current folder, the VM on which he is running beeline client connected to the hiveserver2 server.

      After looking into the matter, we found its file (files because he did several tries) on the hiveserver2 server at /home/hiveserver2 location.

      Is it the expected behavior ? When using Hive client, The file is retrieved as expected on the current directory and not on the hiveserver2 under /home/hiveserver2 location. In fact the user change from Hive client to beeline as Hive client is considered as deprecated. He was expecting to get the same result from beeline.
      After looking a bit into our Hive configuration file, we did not found a parameter to change this beeline behavior. Did we missed something ? Or is there a way to change this behavior in order for beeline to work the same way as Hive client for dfs commands ?

      Also we are wondering if it could lead to a "security breach". What we mean is anyone that have the access to an hiveserver2 server through beeline could blow it up by retrieving files until "no space left on device".

      Regards.

      Attachments

        Activity

          People

            Unassigned Unassigned
            BigDataOrange Alexandre Linte
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: