확성성 있는 인터넷 크롤러와 검색 엔진의 구축을 위한 프레임워크인 Nutch를 정리 합니다.


Nutch 개요


700px


CentOS에서 Nutch 설치



Nutch 설치

 cd install
 wget http://apache.tt.co.kr/nutch/2.2.1/apache-nutch-2.2.1-src.tar.gz
 tar xvfz apache-nutch-2.2.1-src.tar.gz
 chown -R hduser:hdgroup apache-nutch-2.2.1
 cd apache-nutch-2.2.1
 ant                                 #--- 오랜 시간동안 기다리세요.
 chown -R hduser:hdgroup *
 
 cd runtime
 tar cvf ../../nutch.tar local
 cd ../..
 tar xvf nutch.tar
 mv local /nas/appl/nutch
  • 환경 설정
    • vi ~hduser/.bash_profile
 ### ----------------------------------------------------------------------------
 ###     NUTCH 설정
 ### ----------------------------------------------------------------------------
 export NUTCH_HOME=/nas/appl/nutch
 export PATH=$PATH:$NUTCH_HOME/bin

Nutch 설정


ElasticSearch 연동 설정


HBase 연동 설정

  • vi /nas/appl/nutch/conf/hbase-site.xml
 
   
     hbase.rootdir
     hdfs://node201.hadoop.com:9000/hbase
   
 
   
     hbase.cluster.distributed
     true
   
 
   
     hbase.zookeeper.quorum
     localhost
   
 
  • vi /nas/appl/nutch/conf/nutch-site.xml
 
     
         storage.data.store.class
         org.apache.gora.hbase.store.HBaseStore
         Default class for storing data
     
     
         http.agent.name
         NutchCrawler
     
     
         http.robots.agents
         NutchCrawler,*
     
 
  • vi /nas/appl/nutch/conf/gora.properties
 gora.datastore.default=org.apache.gora.hbase.store.HBaseStore
  • vi /nas/install/apache-nutch-2.2.1/ivy/ivy.xml
    • 아래 주석 해제
    • gora.properties 파일의 설정을 변경한 후 ant를 사용하여 nutch를 재빌드 하여야 함
 

MySQL 연동 설정


참고 문헌


분류: Search BigData

최종 수정일: 2022-10-24 19:17:28

이전글 :
다음글 :
상단 menu
arrow_back_ios
arrow_forward_ios