--- title: Search samples for a live demo of Search on Hadoop author: admin type: post date: 2014-03-23T05:00:00+00:00 url: /tutorial-live-demo-of-search-on-hadoop/ tumblr_gethue_permalink: - http://gethue.tumblr.com/post/78012277574/tutorial-live-demo-of-search-on-hadoop tumblr_gethue_id: - 78012277574 sf_thumbnail_type: - none sf_thumbnail_link_type: - link_to_post sf_detail_type: - none sf_page_title: - 1 sf_page_title_style: - standard sf_no_breadcrumbs: - 1 sf_page_title_bg: - none sf_page_title_text_style: - light sf_background_image_size: - cover sf_social_sharing: - 1 sf_sidebar_config: - left-sidebar sf_left_sidebar: - Sidebar-2 sf_right_sidebar: - Sidebar-1 sf_caption_position: - caption-right slide_template: - default categories: - Querying --- Edit: This post is deprecated since [Hue 3.6][1], clicking on the install button is the only thing to do now! Hue comes up with a series of examples (for [Hive][2]/[Impala][2], [HBase][3]...) to help you get started with Hadoop. Recently, some demo Collection/Indexes were added for the [Search Application][4]:

Twitter
Screenshot from 2014-04-09 08:06:26

Logs
Screenshot from 2014-04-09 08:06:35

Yelp

Screenshot from 2014-04-09 08:06:30

To install them,  got to Hue on the [/about/][5] page and on Step 2 click on 'Solr Search':

Screenshot from 2014-04-09 08:32:20

This will install the search templates in Hue. To make the demo work by default, Hue is using a predefined Solr response. Hue displays a warning in this case as the page is not updated when typing a query: [Screenshot from 2014-03-10 16:13:06][6] The next step is to create the indexed into Solr. First, make sure that Solr has been setup and initialized [correctly][7]. In order to query a live dataset, you need to index some data. Go on the Hue machine:


cd $HUE_HOME

cd apps/search/examples/bin

Then create the Solr collections:
./create_collections.sh
In case Solr is not on the same machine, add this parameter in the script:
-solr http://localhost:8983/solr
Then index some example data with:
./post.sh
Same, if Solr is on a different machine, update the url:
URL=http://localhost:8983/solr
And that’s it! The above warning message will disappear and you will be able to query Solr indexes in live! Then go create your own Search! {{< youtube ATldKiiJdqY >}} As usual feel free to comment on the[ hue-user][8] list or [@gethue][9]! [1]: https://gethue.com/analyse-apache-logs-and-build-your-own-web-analytics-dashboard-with-hadoop-and-solr [2]: https://gethue.com/hadoop-tutorial-new-impala-and-hive-editors/ [3]: https://gethue.com/the-web-ui-for-hbase-hbase-browser/ 'The Web UI for HBase: HBase Browser' [4]: http://gethue.tumblr.com/post/65969470780/hadoop-tutorials-season-ii-7-how-to-index-and-search [5]: http://127.0.0.1:8888/about/ [6]: https://cdn.gethue.com/uploads/2014/03/Screenshot-from-2014-03-10-161306.png [7]: http://www.cloudera.com/content/cloudera-content/cloudera-docs/CDH5/latest/Search/Cloudera-Search-Installation-Guide/csig_deploy_search_solrcloud.html [8]: http://groups.google.com/a/cloudera.org/group/hue-user [9]: https://twitter.com/gethue