All Articles

HIVE ETL to Elastic Search and MySQL

HIVE

HUE

HUE 인터페이스 사용

create database auctionDB;

use auctionDB;

CREATE EXTERNAL TABLE ctauInfo (
    status          STRING,
    auctionCount    STRING,
    auctionDate     STRING,
    addr            STRING,
    addr0           STRING,
    addr1           STRING,
    addr2           STRING,
    addr3           STRING,
    court           STRING,
    courtCode       STRING,
    itemNo          STRING,
    remark          STRING,
    caNo            STRING,
    pyeong          STRING,
    land1           STRING,
    land2           STRING,
    floor1          STRING,
    floor2          STRING,
    auctionInfo     STRING,
    itemType        STRING,
    appraisedValue  STRING,
    minValue        STRING,
    saleValue       STRING,
    saleRate        STRING,
    saleCount       STRING
)
ROW FORMAT SERDE 'org.apache.hive.hcatalog.data.JsonSerDe'
STORED AS TEXTFILE
location '/flume/data3';

select count(*) from ctauinfo;

Beeline

BeeLine 을 활용하여 CLI로 접근하는 방법

  • dn01 tty 접근 가정

    [eduuser@dn01 ~]$ beeline --showDbInPrompt=true
    Beeline version 1.1.0-cdh5.14.2 by Apache Hive
    beeline> !connect jdbc:hive2://dn02:10000
    scan complete in 3ms
    Connecting to jdbc:hive2://dn02:10000
    Enter username for jdbc:hive2://dn02:10000: hive
    Enter password for jdbc:hive2://dn02:10000: ****
    Connected to: Apache Hive (version 1.1.0-cdh5.14.2)
    Driver: Hive JDBC (version 1.1.0-cdh5.14.2)
    Transaction isolation: TRANSACTION_REPEATABLE_READ
    0: jdbc:hive2://dn02:10000> !list
    1 active connection:
    #0  open     jdbc:hive2://dn02:10000
    0: jdbc:hive2://dn02:10000> use auctiondb;
    INFO  : Compiling command(queryId=hive_20180423195050_f8ce7a42-92bd-4a73-938a-d78e7be15ad3): use auctiondb
    INFO  : Semantic Analysis Completed
    INFO  : Returning Hive schema: Schema(fieldSchemas:null, properties:null)
    INFO  : Completed compiling command(queryId=hive_20180423195050_f8ce7a42-92bd-4a73-938a-d78e7be15ad3); Time taken: 0.099 seconds
    INFO  : Executing command(queryId=hive_20180423195050_f8ce7a42-92bd-4a73-938a-d78e7be15ad3): use auctiondb
    INFO  : Starting task [Stage-0:DDL] in serial mode
    INFO  : Completed executing command(queryId=hive_20180423195050_f8ce7a42-92bd-4a73-938a-d78e7be15ad3); Time taken: 0.015 seconds
    INFO  : OK
    No rows affected (0.218 seconds)
    0: jdbc:hive2://dn02:10000> show tables;
    INFO  : Compiling command(queryId=hive_20180423195050_1e5fb9e3-6a6b-42c8-9a6f-5e7671210beb): show tables
    INFO  : Semantic Analysis Completed
    INFO  : Returning Hive schema: Schema(fieldSchemas:[FieldSchema(name:tab_name, type:string, comment:from deserializer)], properties:null)
    INFO  : Completed compiling command(queryId=hive_20180423195050_1e5fb9e3-6a6b-42c8-9a6f-5e7671210beb); Time taken: 0.005 seconds
    INFO  : Executing command(queryId=hive_20180423195050_1e5fb9e3-6a6b-42c8-9a6f-5e7671210beb): show tables
    INFO  : Starting task [Stage-0:DDL] in serial mode
    INFO  : Completed executing command(queryId=hive_20180423195050_1e5fb9e3-6a6b-42c8-9a6f-5e7671210beb); Time taken: 0.016 seconds
    INFO  : OK
    +-----------+--+
    | tab_name  |
    +-----------+--+
    | ctauinfo  |
    +-----------+--+
    1 row selected (0.124 seconds)
    0: jdbc:hive2://dn02:10000> select * from ctauinfo limit 5;
    INFO  : Compiling command(queryId=hive_20180423195050_b14f6f92-f00c-4a43-a5f0-35a04ad63251): select * from ctauinfo limit 5
    INFO  : Semantic Analysis Completed
    INFO  : Returning Hive schema: Schema(fieldSchemas:[FieldSchema(name:ctauinfo.status, type:string, comment:null), FieldSchema(name:ctauinfo.auctioncount, type:string, comment:null), FieldSchema(name:ctauinfo.auctiondate, type:string, comment:null), FieldSchema(name:ctauinfo.addr, type:string, comment:null), FieldSchema(name:ctauinfo.addr0, type:string, comment:null), FieldSchema(name:ctauinfo.addr1, type:string, comment:null), FieldSchema(name:ctauinfo.addr2, type:string, comment:null), FieldSchema(name:ctauinfo.addr3, type:string, comment:null), FieldSchema(name:ctauinfo.court, type:string, comment:null), FieldSchema(name:ctauinfo.courtcode, type:string, comment:null), FieldSchema(name:ctauinfo.itemno, type:string, comment:null), FieldSchema(name:ctauinfo.remark, type:string, comment:null), FieldSchema(name:ctauinfo.cano, type:string, comment:null), FieldSchema(name:ctauinfo.pyeong, type:string, comment:null), FieldSchema(name:ctauinfo.land1, type:string, comment:null), FieldSchema(name:ctauinfo.land2, type:string, comment:null), FieldSchema(name:ctauinfo.floor1, type:string, comment:null), FieldSchema(name:ctauinfo.floor2, type:string, comment:null), FieldSchema(name:ctauinfo.auctioninfo, type:string, comment:null), FieldSchema(name:ctauinfo.itemtype, type:string, comment:null), FieldSchema(name:ctauinfo.appraisedvalue, type:string, comment:null), FieldSchema(name:ctauinfo.minvalue, type:string, comment:null), FieldSchema(name:ctauinfo.salevalue, type:string, comment:null), FieldSchema(name:ctauinfo.salerate, type:string, comment:null), FieldSchema(name:ctauinfo.salecount, type:string, comment:null)], properties:null)
    INFO  : Completed compiling command(queryId=hive_20180423195050_b14f6f92-f00c-4a43-a5f0-35a04ad63251); Time taken: 0.106 seconds
    INFO  : Executing command(queryId=hive_20180423195050_b14f6f92-f00c-4a43-a5f0-35a04ad63251): select * from ctauinfo limit 5
    INFO  : Completed executing command(queryId=hive_20180423195050_b14f6f92-f00c-4a43-a5f0-35a04ad63251); Time taken: 0.002 seconds
    INFO  : OK
    +------------------+------------------------+-----------------------+--------------------------------------------+-----------------+-----------------+-----------------+-----------------+-----------------+---------------------+------------------+------------------+----------------+------------------+-----------------+-----------------+------------------+------------------+----------------------------------------------+--------------------+--------------------------+--------------------+---------------------+--------------------+---------------------+--+
    | ctauinfo.status  | ctauinfo.auctioncount  | ctauinfo.auctiondate  |               ctauinfo.addr                | ctauinfo.addr0  | ctauinfo.addr1  | ctauinfo.addr2  | ctauinfo.addr3  | ctauinfo.court  | ctauinfo.courtcode  | ctauinfo.itemno  | ctauinfo.remark  | ctauinfo.cano  | ctauinfo.pyeong  | ctauinfo.land1  | ctauinfo.land2  | ctauinfo.floor1  | ctauinfo.floor2  |             ctauinfo.auctioninfo             | ctauinfo.itemtype  | ctauinfo.appraisedvalue  | ctauinfo.minvalue  | ctauinfo.salevalue  | ctauinfo.salerate  | ctauinfo.salecount  |
    +------------------+------------------------+-----------------------+--------------------------------------------+-----------------+-----------------+-----------------+-----------------+-----------------+---------------------+------------------+------------------+----------------+------------------+-----------------+-----------------+------------------+------------------+----------------------------------------------+--------------------+--------------------------+--------------------+---------------------+--------------------+---------------------+--+
    | 배당종결             | 2                      | 2008-01-25            | 부산광역시 동래구 온천동 1444-1궁전아이브 5층 505호          | 부산광역시           | 동래구             | 온천동             |                 | 부산지방법원          | B01                 | 1                | 관련사건             | 2007타경6344     | 10.57            | 10.57           | 3.2             | 84.54            | 25.57            | 35평형,토지 10.57㎡(3.2평),건물 84.54㎡(25.57평)       | 아파트                | 176000000                |                    |                     |                    |                     |
    | 배당종결             | 1                      | 2008-01-25            | 부산광역시 북구 덕천동 250-9덕천한성맨션 2동 1층 112호        | 부산광역시           | 북구              | 덕천동             |                 | 부산지방법원          | B01                 | 1                |                  | 2007타경9220     | 39.496           | 39.496          | 11.95           | 44.73            | 13.53            | 16평형,토지 39.496㎡(11.95평),건물 44.73㎡(13.53평)    | 아파트                | 44000000                 |                    | 36,399,900          | 83                 | 4                   |
    | 배당종결             | 1                      | 2008-01-25            | 부산광역시 연제구 연산동 57-134연산부전타워 101동 2층 2-202호  | 부산광역시           | 연제구             | 연산동             |                 | 부산지방법원          | B01                 | 1                |                  | 2007타경15720    | 20.05            | 20.05           | 6.07            | 59.92            | 18.13            | 25평형,토지 20.05㎡(6.07평),건물 59.92㎡(18.13평)      | 아파트                | 76000000                 |                    | 65,999,000          | 87                 | 2                   |
    | 배당종결             | 1                      | 2008-01-25            | 부산광역시 사하구 장림동 산21-2장림우림그린빌라 101동 9층 907호   | 부산광역시           | 사하구             | 장림동             |                 | 부산지방법원          | B01                 | 1                |                  | 2007타경20951    | 79.9827          | 79.9827         | 24.19           | 132.54           | 40.09            | 50평형,토지 79.9827㎡(24.19평),건물 132.54㎡(40.09평)  | 아파트                | 120000000                |                    | 99,100,000          | 83                 | 3                   |
    | 배당종결             | 2                      | 2008-01-25            | 부산광역시 서구 암남동 81-12송도자유비치아파트 3층 307호        | 부산광역시           | 서구              | 암남동             |                 | 부산지방법원          | B01                 | 1                |                  | 2007타경23424    | 17.54            | 17.54           | 5.31            | 48.63            | 14.71            | 20평형,토지 17.54㎡(5.31평),건물 48.63㎡(14.71평)      | 아파트                | 58000000                 |                    | 42,850,000          | 74                 | 2                   |
    +------------------+------------------------+-----------------------+--------------------------------------------+-----------------+-----------------+-----------------+-----------------+-----------------+---------------------+------------------+------------------+----------------+------------------+-----------------+-----------------+------------------+------------------+----------------------------------------------+--------------------+--------------------------+--------------------+---------------------+--------------------+---------------------+--+
    5 rows selected (0.237 seconds)
    0: jdbc:hive2://dn02:10000>
    0: jdbc:hive2://dn02:10000>
    0: jdbc:hive2://dn02:10000> !sh who
    (unknown) :0           2018-04-14 00:37 (:0)
    eduuser  pts/0        2018-04-23 19:43 (192.168.1.31)
    root     pts/1        2018-04-23 19:50 (192.168.1.31)
    root     pts/2        2018-04-23 19:55 (192.168.1.31)
    eduuser  pts/5        2018-04-21 00:09 (dn02)
    eduuser  pts/6        2018-04-21 00:17 (dn02)
    esadmin  pts/7        2018-04-21 04:01 (dn02)
    0: jdbc:hive2://dn02:10000>
    0: jdbc:hive2://dn02:10000> select count(*) from ctauinfo where courtCode = 'L01';
    INFO  : Compiling command(queryId=hive_20180423210202_4a400a72-21c5-4e33-b1e4-dbd658de60c5): select count(*) from ctauinfo where courtCode = 'L01'
    INFO  : Semantic Analysis Completed
    INFO  : Returning Hive schema: Schema(fieldSchemas:[FieldSchema(name:_c0, type:bigint, comment:null)], properties:null)
    INFO  : Completed compiling command(queryId=hive_20180423210202_4a400a72-21c5-4e33-b1e4-dbd658de60c5); Time taken: 0.219 seconds
    INFO  : Executing command(queryId=hive_20180423210202_4a400a72-21c5-4e33-b1e4-dbd658de60c5): select count(*) from ctauinfo where courtCode = 'L01'
    INFO  : Query ID = hive_20180423210202_4a400a72-21c5-4e33-b1e4-dbd658de60c5
    INFO  : Total jobs = 1
    INFO  : Launching Job 1 out of 1
    INFO  : Starting task [Stage-1:MAPRED] in serial mode
    INFO  : Number of reduce tasks determined at compile time: 1
    INFO  : In order to change the average load for a reducer (in bytes):
    INFO  :   set hive.exec.reducers.bytes.per.reducer=<number>
    INFO  : In order to limit the maximum number of reducers:
    INFO  :   set hive.exec.reducers.max=<number>
    INFO  : In order to set a constant number of reducers:
    INFO  :   set mapreduce.job.reduces=<number>
    INFO  : number of splits:1
    INFO  : Submitting tokens for job: job_1523845385074_0019
    INFO  : The url to track the job: http://nn01:8088/proxy/application_1523845385074_0019/
    INFO  : Starting Job = job_1523845385074_0019, Tracking URL = http://nn01:8088/proxy/application_1523845385074_0019/
    INFO  : Kill Command = /opt/cloudera/parcels/CDH-5.14.2-1.cdh5.14.2.p0.3/lib/hadoop/bin/hadoop job  -kill job_1523845385074_0019
    INFO  : Hadoop job information for Stage-1: number of mappers: 1; number of reducers: 1
    INFO  : 2018-04-23 21:02:25,203 Stage-1 map = 0%,  reduce = 0%
    INFO  : 2018-04-23 21:02:48,568 Stage-1 map = 100%,  reduce = 100%
    ERROR : Ended Job = job_1523845385074_0019 with errors
    ERROR : FAILED: Execution Error, return code 2 from org.apache.hadoop.hive.ql.exec.mr.MapRedTask
    INFO  : MapReduce Jobs Launched:
    INFO  : Stage-Stage-1: Map: 1  Reduce: 1   HDFS Read: 0 HDFS Write: 0 FAIL
    INFO  : Total MapReduce CPU Time Spent: 0 msec
    INFO  : Completed executing command(queryId=hive_20180423210202_4a400a72-21c5-4e33-b1e4-dbd658de60c5); Time taken: 30.936 seconds
    Error: Error while processing statement: FAILED: Execution Error, return code 2 from org.apache.hadoop.hive.ql.exec.mr.MapRedTask (state=08S01,code=2)
    0: jdbc:hive2://dn02:10000> !sh ls /opt/cloudera/parcels/CDH/lib/hive-hcatalog/share/hcatalog/
    hive-hcatalog-core-1.1.0-cdh5.14.2.jar
    hive-hcatalog-core.jar
    hive-hcatalog-pig-adapter-1.1.0-cdh5.14.2.jar
    hive-hcatalog-pig-adapter.jar
    hive-hcatalog-server-extensions-1.1.0-cdh5.14.2.jar
    hive-hcatalog-server-extensions.jar
    hive-hcatalog-streaming-1.1.0-cdh5.14.2.jar
    hive-hcatalog-streaming.jar
    0: jdbc:hive2://dn02:10000> add jar /opt/cloudera/parcels/CDH/lib/hive-hcatalog/share/hcatalog/hive-hcatalog-core.jar;
    INFO  : Added [/opt/cloudera/parcels/CDH/lib/hive-hcatalog/share/hcatalog/hive-hcatalog-core.jar] to class path
    INFO  : Added resources: [/opt/cloudera/parcels/CDH/lib/hive-hcatalog/share/hcatalog/hive-hcatalog-core.jar]
    No rows affected (0.011 seconds)
    0: jdbc:hive2://dn02:10000> select count(*) from ctauinfo where courtCode = 'L01';
    INFO  : Compiling command(queryId=hive_20180423211717_21016bba-8eff-44d6-9031-d32a18aa746d): select count(*) from ctauinfo where courtCode = 'L01'
    INFO  : Semantic Analysis Completed
    INFO  : Returning Hive schema: Schema(fieldSchemas:[FieldSchema(name:_c0, type:bigint, comment:null)], properties:null)
    INFO  : Completed compiling command(queryId=hive_20180423211717_21016bba-8eff-44d6-9031-d32a18aa746d); Time taken: 0.116 seconds
    INFO  : Executing command(queryId=hive_20180423211717_21016bba-8eff-44d6-9031-d32a18aa746d): select count(*) from ctauinfo where courtCode = 'L01'
    INFO  : Query ID = hive_20180423211717_21016bba-8eff-44d6-9031-d32a18aa746d
    INFO  : Total jobs = 1
    INFO  : Launching Job 1 out of 1
    INFO  : Starting task [Stage-1:MAPRED] in serial mode
    INFO  : Number of reduce tasks determined at compile time: 1
    INFO  : In order to change the average load for a reducer (in bytes):
    INFO  :   set hive.exec.reducers.bytes.per.reducer=<number>
    INFO  : In order to limit the maximum number of reducers:
    INFO  :   set hive.exec.reducers.max=<number>
    INFO  : In order to set a constant number of reducers:
    INFO  :   set mapreduce.job.reduces=<number>
    INFO  : number of splits:1
    INFO  : Submitting tokens for job: job_1523845385074_0020
    INFO  : The url to track the job: http://nn01:8088/proxy/application_1523845385074_0020/
    INFO  : Starting Job = job_1523845385074_0020, Tracking URL = http://nn01:8088/proxy/application_1523845385074_0020/
    INFO  : Kill Command = /opt/cloudera/parcels/CDH-5.14.2-1.cdh5.14.2.p0.3/lib/hadoop/bin/hadoop job  -kill job_1523845385074_0020
    INFO  : Hadoop job information for Stage-1: number of mappers: 1; number of reducers: 1
    INFO  : 2018-04-23 21:17:21,659 Stage-1 map = 0%,  reduce = 0%
    INFO  : 2018-04-23 21:17:32,349 Stage-1 map = 100%,  reduce = 0%, Cumulative CPU 8.06 sec
    INFO  : 2018-04-23 21:17:39,863 Stage-1 map = 100%,  reduce = 100%, Cumulative CPU 11.07 sec
    INFO  : MapReduce Total cumulative CPU time: 11 seconds 70 msec
    INFO  : Ended Job = job_1523845385074_0020
    INFO  : MapReduce Jobs Launched:
    INFO  : Stage-Stage-1: Map: 1  Reduce: 1   Cumulative CPU: 11.07 sec   HDFS Read: 141858326 HDFS Write: 5 SUCCESS
    INFO  : Total MapReduce CPU Time Spent: 11 seconds 70 msec
    INFO  : Completed executing command(queryId=hive_20180423211717_21016bba-8eff-44d6-9031-d32a18aa746d); Time taken: 26.832 seconds
    INFO  : OK
    +-------+--+
    |  _c0  |
    +-------+--+
    | 9151  |
    +-------+--+
    1 row selected (27.051 seconds)
    0: jdbc:hive2://dn02:10000> !quit
    Closing: 0: jdbc:hive2://dn02:10000
    [eduuser@dn01 ~]$

Beeline 에러발생시

  1. 맵리듀스 잡 에러 발생 로그를 살펴본다 http://nn01:8088/proxy/application15238453850740019/ bug1 bug2 json Serde 관련 class 를 찾을 수 없다는 에러

  2. beeline 에서 Serde 관련 jar path 를 잡아 준다.

    0: jdbc:hive2://dn02:10000> add jar /opt/cloudera/parcels/CDH/lib/hive-hcatalog/share/hcatalog/hive-hcatalog-core.jar;
  3. 다시 실행하면 정상 동작 확인된다.

Sqoop to MySQL

  1. Mysql 테이블 생성

    -- DB 및 사용자 추가
    create database auctionDB;
    GRANT ALL PRIVILEGES ON auctionDB.* TO datatech4@localhost IDENTIFIED BY 'datatech4';
  2. MySQL 계정 접속

    # 계정 : datatech4/datatech4
    mysql -u datatech4 -pdatatech4 auctionDB
  3. 원격접속 허용

    mysql -u root -proot
    grant all privileges on *.* to 'datatech4'@'%' identified by 'datatech4';
  4. 테이블 생성

    --테이블 생성
    create table ctauInfo_out (
    status varchar(255),
    auctionCount int,
    auctionDate varchar(255),
    addr varchar(255),
    addr0 varchar(255),
    addr1 varchar(255),
    addr2 varchar(255),
    addr3 varchar(255),
    court varchar(255),
    courtCode varchar(255),
    itemNo int,
    remark varchar(255),
    caNo varchar(255),
    pyeong float,
    land1 float,
    land2 float,
    floor1 float,
    floor2 float,
    auctionInfo varchar(255),
    itemType varchar(255),
    appraisedValue bigint,
    minValue bigint,
    saleValue varchar(255),
    saleRate int,
    saleCount int
    );
  5. Hive ctauInfo 조회결과 저장

    -- auctionDate 데이터 이상함.
    -- saleValue 콤마 변환 필요    
    -- 테이블 저장
    CREATE TABLE ctauInfo_out
    row format delimited fields terminated by '|'  
    AS SELECT * FROM ctauInfo;
  6. Sqoop로 데이터 적재(Hive to Mysql)

    # mysql connector 필요
    [root@dn02 lib]# pwd
    /opt/cloudera/parcels/CDH/lib/sqoop/lib
    [root@dn02 lib]# wget http://www.java2s.com/Code/JarDownload/mysql/mysql-connector-java-5.1.15.jar.zip
    [cloudera@dn01 ~]$ sqoop list-databases --connect jdbc:mysql://localhost --username datatech4 --password datatech4
    [cloudera@dn01 ~]$ sqoop list-tables --connect jdbc:mysql://localhost/auctionDB --username datatech4 --password datatech4
    # cloudera 유저로 수행) * 권한오류
    sqoop export --connect jdbc:mysql://dn01:3306/auctionDB \
    --username datatech4 --password datatech4 \
    --table ctauInfo_out --export-dir '/user/hive/warehouse/auctiondb.db/ctauinfo_out' \
    --fields-terminated-by '|'
    # 한글깨짐 조치 
    [cloudera@dn01 ~]$ vi /etc/my.cnf
    collation-server = utf8_unicode_ci
    init-connect='SET NAMES utf8'
    character-set-server = utf8
    [client]
    default-character-set = utf8
    [mysql]
    default-character-set = utf8
    [mysqldump]
    default-character-set = utf8
    ALTER DATABASE auctionDB DEFAULT CHARACTER SET utf8;
    -- saleValue 콤마제거
    update ctauInfo_out set saleValue = replace(saleValue,',','');
    -- auctionDate 데이터 이상하여 처리함
    select count(*)  from ctauInfo_out where length(auctionDate) > 10;
    +----------+
    | count(*) |
    +----------+
    |     2677 |
    +----------+
    1 row in set (0.16 sec)
    mysql> select auctionDate  from ctauInfo_out where length(auctionDate) > 10 limit 10;
    (2011-10-06∼2011-10-13)2011-10-19
    SELECT right(auctionDate,10) from ctauInfo_out where length(auctionDate) > 10;
    update ctauInfo_out set auctionDate = right(auctionDate,10) where length(auctionDate) > 10;

HIVE to Elasticsearch

  1. Hadoop 에 필요한 Elasticsearch 연동용 StorageHandler jar 파일 등록 후 사용

    [eduuser@dn01 ~]$ sudo -u hive hadoop fs -ls /user/hive/
    Found 3 items
    drwx------   - hive hive          0 2018-04-24 19:05 /user/hive/.Trash
    drwx------   - hive hive          0 2018-04-24 04:59 /user/hive/.staging
    drwxrwxrwt   - hive hive          0 2018-04-23 22:41 /user/hive/warehouse
    [eduuser@dn01 ~]$
    [eduuser@dn01 ~]$ wget https://artifacts.elastic.co/downloads/elasticsearch-hadoop/elasticsearch-hadoop-6.2.4.zip
    --2018-04-24 19:51:32--  https://artifacts.elastic.co/downloads/elasticsearch-hadoop/elasticsearch-hadoop-6.2.4.zip
    Resolving artifacts.elastic.co (artifacts.elastic.co)... 23.21.67.46, 23.23.109.100, 184.72.242.47, ...
    Connecting to artifacts.elastic.co (artifacts.elastic.co)|23.21.67.46|:443... connected.
    HTTP request sent, awaiting response... 200 OK
    Length: 7692396 (7.3M) [application/zip]
    Saving to: ‘elasticsearch-hadoop-6.2.4.zip’
    100%[=====================================================================================================================================================>] 7,692,396   2.42MB/s   in 3.0s
    2018-04-24 19:51:37 (2.42 MB/s) - ‘elasticsearch-hadoop-6.2.4.zip’ saved [7692396/7692396]
    [eduuser@dn01 ~]$ unzip elasticsearch-hadoop-6.2.4.zip
    Archive:  elasticsearch-hadoop-6.2.4.zip
    creating: elasticsearch-hadoop-6.2.4/
    inflating: elasticsearch-hadoop-6.2.4/README.md
    inflating: elasticsearch-hadoop-6.2.4/LICENSE.txt
    inflating: elasticsearch-hadoop-6.2.4/NOTICE.txt
    creating: elasticsearch-hadoop-6.2.4/dist/
    inflating: elasticsearch-hadoop-6.2.4/dist/elasticsearch-hadoop-6.2.4.jar
    inflating: elasticsearch-hadoop-6.2.4/dist/elasticsearch-hadoop-6.2.4-javadoc.jar
    inflating: elasticsearch-hadoop-6.2.4/dist/elasticsearch-hadoop-6.2.4-sources.jar
    inflating: elasticsearch-hadoop-6.2.4/dist/elasticsearch-hadoop-cascading-6.2.4-javadoc.jar
    inflating: elasticsearch-hadoop-6.2.4/dist/elasticsearch-hadoop-cascading-6.2.4-sources.jar
    inflating: elasticsearch-hadoop-6.2.4/dist/elasticsearch-hadoop-cascading-6.2.4.jar
    inflating: elasticsearch-hadoop-6.2.4/dist/elasticsearch-hadoop-hive-6.2.4-javadoc.jar
    inflating: elasticsearch-hadoop-6.2.4/dist/elasticsearch-hadoop-hive-6.2.4-sources.jar
    inflating: elasticsearch-hadoop-6.2.4/dist/elasticsearch-hadoop-hive-6.2.4.jar
    inflating: elasticsearch-hadoop-6.2.4/dist/elasticsearch-hadoop-mr-6.2.4-sources.jar
    inflating: elasticsearch-hadoop-6.2.4/dist/elasticsearch-hadoop-mr-6.2.4-javadoc.jar
    inflating: elasticsearch-hadoop-6.2.4/dist/elasticsearch-hadoop-mr-6.2.4.jar
    inflating: elasticsearch-hadoop-6.2.4/dist/elasticsearch-hadoop-pig-6.2.4-javadoc.jar
    inflating: elasticsearch-hadoop-6.2.4/dist/elasticsearch-hadoop-pig-6.2.4-sources.jar
    inflating: elasticsearch-hadoop-6.2.4/dist/elasticsearch-hadoop-pig-6.2.4.jar
    inflating: elasticsearch-hadoop-6.2.4/dist/elasticsearch-spark-20_2.11-6.2.4-sources.jar
    inflating: elasticsearch-hadoop-6.2.4/dist/elasticsearch-spark-20_2.11-6.2.4.jar
    inflating: elasticsearch-hadoop-6.2.4/dist/elasticsearch-spark-20_2.11-6.2.4-javadoc.jar
    inflating: elasticsearch-hadoop-6.2.4/dist/elasticsearch-storm-6.2.4-sources.jar
    inflating: elasticsearch-hadoop-6.2.4/dist/elasticsearch-storm-6.2.4.jar
    inflating: elasticsearch-hadoop-6.2.4/dist/elasticsearch-storm-6.2.4-javadoc.jar
    [eduuser@dn01 ~]$ cd elasticsearch-hadoop-6.2.4/dist/
    [eduuser@dn01 dist]$
    [eduuser@dn01 dist]$
    [eduuser@dn01 dist]$ sudo -u hive hadoop fs -mkdir /user/hive/aux_jars
    [eduuser@dn01 dist]$
    [eduuser@dn01 dist]$ sudo -u hive hadoop fs -ls /user/hive/
    Found 4 items
    drwx------   - hive hive          0 2018-04-24 19:05 /user/hive/.Trash
    drwx------   - hive hive          0 2018-04-24 04:59 /user/hive/.staging
    drwxr-xr-x   - hive hive          0 2018-04-24 19:53 /user/hive/aux_jars
    drwxrwxrwt   - hive hive          0 2018-04-23 22:41 /user/hive/warehouse
    [eduuser@dn01 dist]$
    [eduuser@dn01 dist]$
    [eduuser@dn01 dist]$ sudo -u hive hadoop fs -chmod 1777 /user/hive/aux_jars
    [eduuser@dn01 dist]$
    [eduuser@dn01 dist]$ sudo -u hive hadoop fs -ls /user/hive/
    Found 4 items
    drwx------   - hive hive          0 2018-04-24 19:05 /user/hive/.Trash
    drwx------   - hive hive          0 2018-04-24 04:59 /user/hive/.staging
    drwxrwxrwt   - hive hive          0 2018-04-24 19:53 /user/hive/aux_jars
    drwxrwxrwt   - hive hive          0 2018-04-23 22:41 /user/hive/warehouse
    [eduuser@dn01 dist]$
    [eduuser@dn01 dist]$ hadoop fs -put /home/eduuser/elasticsearch-hadoop-6.2.4/dist/elasticsearch-hadoop-6.2.4.jar /user/hive/aux_jars/
    [eduuser@dn01 dist]$
    [eduuser@dn01 dist]$
    [eduuser@dn01 dist]$ sudo -u hive hadoop fs -ls /user/hive/aux_jars
    Found 1 items
    -rw-r--r--   3 eduuser hive     890273 2018-04-24 19:55 /user/hive/aux_jars/elasticsearch-hadoop-6.2.4.jar
    [eduuser@dn01 dist]$
    [eduuser@dn01 dist]$
    [eduuser@dn01 dist]$ beeline --showDbInPrompt=true;
    Beeline version 1.1.0-cdh5.14.2 by Apache Hive
    beeline> !connect jdbc:hive2://dn02:10000
    scan complete in 4ms
    Connecting to jdbc:hive2://dn02:10000
    Enter username for jdbc:hive2://dn02:10000: hive
    Enter password for jdbc:hive2://dn02:10000: ****
    Connected to: Apache Hive (version 1.1.0-cdh5.14.2)
    Driver: Hive JDBC (version 1.1.0-cdh5.14.2)
    Transaction isolation: TRANSACTION_REPEATABLE_READ
    0: jdbc:hive2://dn02:10000>
    0: jdbc:hive2://dn02:10000>
    0: jdbc:hive2://dn02:10000>
    0: jdbc:hive2://dn02:10000> show databases;
    INFO  : Compiling command(queryId=hive_20180424195757_887d706b-1876-4378-9a85-78bf0c35aae0): show databases
    INFO  : Semantic Analysis Completed
    INFO  : Returning Hive schema: Schema(fieldSchemas:[FieldSchema(name:database_name, type:string, comment:from deserializer)], properties:null)
    INFO  : Completed compiling command(queryId=hive_20180424195757_887d706b-1876-4378-9a85-78bf0c35aae0); Time taken: 0.075 seconds
    INFO  : Executing command(queryId=hive_20180424195757_887d706b-1876-4378-9a85-78bf0c35aae0): show databases
    INFO  : Starting task [Stage-0:DDL] in serial mode
    INFO  : Completed executing command(queryId=hive_20180424195757_887d706b-1876-4378-9a85-78bf0c35aae0); Time taken: 0.032 seconds
    INFO  : OK
    +----------------+--+
    | database_name  |
    +----------------+--+
    | assetdb        |
    | auctiondb      |
    | default        |
    | readb          |
    +----------------+--+
    5 rows selected (0.313 seconds)
    0: jdbc:hive2://dn02:10000> use auctiondb;
    INFO  : Compiling command(queryId=hive_20180424195757_ba8a2651-bead-4e67-b896-3defb715fc4c): use auctiondb
    INFO  : Semantic Analysis Completed
    INFO  : Returning Hive schema: Schema(fieldSchemas:null, properties:null)
    INFO  : Completed compiling command(queryId=hive_20180424195757_ba8a2651-bead-4e67-b896-3defb715fc4c); Time taken: 0.01 seconds
    INFO  : Executing command(queryId=hive_20180424195757_ba8a2651-bead-4e67-b896-3defb715fc4c): use auctiondb
    INFO  : Starting task [Stage-0:DDL] in serial mode
    INFO  : Completed executing command(queryId=hive_20180424195757_ba8a2651-bead-4e67-b896-3defb715fc4c); Time taken: 0.011 seconds
    INFO  : OK
    No rows affected (0.044 seconds)
    0: jdbc:hive2://dn02:10000>
    0: jdbc:hive2://dn02:10000> add jar hdfs:///user/hive/aux_jars/elasticsearch-hadoop-6.2.4.jar;
    INFO  : converting to local hdfs:///user/hive/aux_jars/elasticsearch-hadoop-6.2.4.jar
    INFO  : Added [/tmp/9a6c93cd-6029-4e8a-a95c-4dcbd3600b62_resources/elasticsearch-hadoop-6.2.4.jar] to class path
    INFO  : Added resources: [hdfs:///user/hive/aux_jars/elasticsearch-hadoop-6.2.4.jar]
    No rows affected (0.045 seconds)
    0: jdbc:hive2://dn02:10000> show tables;
    INFO  : Compiling command(queryId=hive_20180424195959_5cf22187-0764-46d2-be35-c1299ae99da5): show tables
    INFO  : Semantic Analysis Completed
    INFO  : Returning Hive schema: Schema(fieldSchemas:[FieldSchema(name:tab_name, type:string, comment:from deserializer)], properties:null)
    INFO  : Completed compiling command(queryId=hive_20180424195959_5cf22187-0764-46d2-be35-c1299ae99da5); Time taken: 0.005 seconds
    INFO  : Executing command(queryId=hive_20180424195959_5cf22187-0764-46d2-be35-c1299ae99da5): show tables
    INFO  : Starting task [Stage-0:DDL] in serial mode
    INFO  : Completed executing command(queryId=hive_20180424195959_5cf22187-0764-46d2-be35-c1299ae99da5); Time taken: 0.015 seconds
    INFO  : OK
    +---------------+--+
    |   tab_name    |
    +---------------+--+
    | ctauinfo      |
    | ctauinfo_out  |
    +---------------+--+
    2 rows selected (0.055 seconds)
    0: jdbc:hive2://dn02:10000>
    0: jdbc:hive2://dn02:10000> desc formatted ctauinfo;
    INFO  : Compiling command(queryId=hive_20180424200101_7ddaa768-d498-4736-9750-c05d67acf1c5): desc formatted ctauinfo
    INFO  : Semantic Analysis Completed
    INFO  : Returning Hive schema: Schema(fieldSchemas:[FieldSchema(name:col_name, type:string, comment:from deserializer), FieldSchema(name:data_type, type:string, comment:from deserializer), FieldSchema(name:comment, type:string, comment:from deserializer)], properties:null)
    INFO  : Completed compiling command(queryId=hive_20180424200101_7ddaa768-d498-4736-9750-c05d67acf1c5); Time taken: 0.098 seconds
    INFO  : Executing command(queryId=hive_20180424200101_7ddaa768-d498-4736-9750-c05d67acf1c5): desc formatted ctauinfo
    INFO  : Starting task [Stage-0:DDL] in serial mode
    INFO  : Completed executing command(queryId=hive_20180424200101_7ddaa768-d498-4736-9750-c05d67acf1c5); Time taken: 0.038 seconds
    INFO  : OK
    +-------------------------------+----------------------------------------------------+-----------------------+--+
    |           col_name            |                     data_type                      |        comment        |
    +-------------------------------+----------------------------------------------------+-----------------------+--+
    | # col_name                    | data_type                                          | comment               |
    |                               | NULL                                               | NULL                  |
    | status                        | string                                             | from deserializer     |
    | auctioncount                  | string                                             | from deserializer     |
    | auctiondate                   | string                                             | from deserializer     |
    | addr                          | string                                             | from deserializer     |
    | addr0                         | string                                             | from deserializer     |
    | addr1                         | string                                             | from deserializer     |
    | addr2                         | string                                             | from deserializer     |
    | addr3                         | string                                             | from deserializer     |
    | court                         | string                                             | from deserializer     |
    | courtcode                     | string                                             | from deserializer     |
    | itemno                        | string                                             | from deserializer     |
    | remark                        | string                                             | from deserializer     |
    | cano                          | string                                             | from deserializer     |
    | pyeong                        | string                                             | from deserializer     |
    | land1                         | string                                             | from deserializer     |
    | land2                         | string                                             | from deserializer     |
    | floor1                        | string                                             | from deserializer     |
    | floor2                        | string                                             | from deserializer     |
    | auctioninfo                   | string                                             | from deserializer     |
    | itemtype                      | string                                             | from deserializer     |
    | appraisedvalue                | string                                             | from deserializer     |
    | minvalue                      | string                                             | from deserializer     |
    | salevalue                     | string                                             | from deserializer     |
    | salerate                      | string                                             | from deserializer     |
    | salecount                     | string                                             | from deserializer     |
    |                               | NULL                                               | NULL                  |
    | # Detailed Table Information  | NULL                                               | NULL                  |
    | Database:                     | auctiondb                                          | NULL                  |
    | Owner:                        | flume                                              | NULL                  |
    | CreateTime:                   | Mon Apr 23 09:06:44 EDT 2018                       | NULL                  |
    | LastAccessTime:               | UNKNOWN                                            | NULL                  |
    | Protect Mode:                 | None                                               | NULL                  |
    | Retention:                    | 0                                                  | NULL                  |
    | Location:                     | hdfs://nn01:8020/flume/data3                       | NULL                  |
    | Table Type:                   | EXTERNAL_TABLE                                     | NULL                  |
    | Table Parameters:             | NULL                                               | NULL                  |
    |                               | COLUMN_STATS_ACCURATE                              | false                 |
    |                               | EXTERNAL                                           | TRUE                  |
    |                               | numFiles                                           | 0                     |
    |                               | numRows                                            | -1                    |
    |                               | rawDataSize                                        | -1                    |
    |                               | totalSize                                          | 0                     |
    |                               | transient_lastDdlTime                              | 1524488804            |
    |                               | NULL                                               | NULL                  |
    | # Storage Information         | NULL                                               | NULL                  |
    | SerDe Library:                | org.apache.hive.hcatalog.data.JsonSerDe            | NULL                  |
    | InputFormat:                  | org.apache.hadoop.mapred.TextInputFormat           | NULL                  |
    | OutputFormat:                 | org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat | NULL                  |
    | Compressed:                   | No                                                 | NULL                  |
    | Num Buckets:                  | -1                                                 | NULL                  |
    | Bucket Columns:               | []                                                 | NULL                  |
    | Sort Columns:                 | []                                                 | NULL                  |
    | Storage Desc Params:          | NULL                                               | NULL                  |
    |                               | serialization.format                               | 1                     |
    +-------------------------------+----------------------------------------------------+-----------------------+--+
    56 rows selected (0.232 seconds)
    0: jdbc:hive2://dn02:10000>
    0: jdbc:hive2://dn02:10000>
    0: jdbc:hive2://dn02:10000> CREATE EXTERNAL TABLE auction_es (
    . . . . . . . . . . . . . >     status          STRING,
    . . . . . . . . . . . . . >     auctionCount    int,
    . . . . . . . . . . . . . >     auctionDate     timestamp,
    . . . . . . . . . . . . . >     addr            STRING,
    . . . . . . . . . . . . . >     addr0           STRING,
    . . . . . . . . . . . . . >     addr1           STRING,
    . . . . . . . . . . . . . >     addr2           STRING,
    . . . . . . . . . . . . . >     addr3           STRING,
    . . . . . . . . . . . . . >     court           STRING,
    . . . . . . . . . . . . . >     courtCode       STRING,
    . . . . . . . . . . . . . >     itemNo          int,
    . . . . . . . . . . . . . >     remark          STRING,
    . . . . . . . . . . . . . >     caNo            STRING,
    . . . . . . . . . . . . . >     pyeong          int,
    . . . . . . . . . . . . . >     land1           float,
    . . . . . . . . . . . . . >     land2           float,
    . . . . . . . . . . . . . >     floor1          float,
    . . . . . . . . . . . . . >     floor2          float,
    . . . . . . . . . . . . . >     auctionInfo     STRING,
    . . . . . . . . . . . . . >     itemType        STRING,
    . . . . . . . . . . . . . >     appraisedValue  bigint,
    . . . . . . . . . . . . . >     minValue        bigint,
    . . . . . . . . . . . . . >     saleValue       bigint,
    . . . . . . . . . . . . . >     saleRate        int,
    . . . . . . . . . . . . . >     saleCount       int)
    . . . . . . . . . . . . . > COMMENT 'Auction ES Table'
    . . . . . . . . . . . . . > STORED BY 'org.elasticsearch.hadoop.hive.EsStorageHandler'
    . . . . . . . . . . . . . > TBLPROPERTIES('es.resource' = 'auction_data/auction',
    . . . . . . . . . . . . . >  'es.nodes'='dn01', 'es.port'='9201' );
    INFO  : Compiling command(queryId=hive_20180424200303_5bc78e21-3952-40b3-9378-caaf52b9b125): CREATE EXTERNAL TABLE auction_es (
    status          STRING,
    auctionCount    int,
    auctionDate     timestamp,
    addr            STRING,
    addr0           STRING,
    addr1           STRING,
    addr2           STRING,
    addr3           STRING,
    court           STRING,
    courtCode       STRING,
    itemNo          int,
    remark          STRING,
    caNo            STRING,
    pyeong          int,
    land1           float,
    land2           float,
    floor1          float,
    floor2          float,
    auctionInfo     STRING,
    itemType        STRING,
    appraisedValue  bigint,
    minValue        bigint,
    saleValue       bigint,
    saleRate        int,
    saleCount       int)
    COMMENT 'Auction ES Table'
    STORED BY 'org.elasticsearch.hadoop.hive.EsStorageHandler'
    TBLPROPERTIES('es.resource' = 'auction_data/auction',
    'es.nodes'='dn01', 'es.port'='9201' )
    INFO  : Semantic Analysis Completed
    INFO  : Returning Hive schema: Schema(fieldSchemas:null, properties:null)
    INFO  : Completed compiling command(queryId=hive_20180424200303_5bc78e21-3952-40b3-9378-caaf52b9b125); Time taken: 0.016 seconds
    INFO  : Executing command(queryId=hive_20180424200303_5bc78e21-3952-40b3-9378-caaf52b9b125): CREATE EXTERNAL TABLE auction_es (
    status          STRING,
    auctionCount    int,
    auctionDate     timestamp,
    addr            STRING,
    addr0           STRING,
    addr1           STRING,
    addr2           STRING,
    addr3           STRING,
    court           STRING,
    courtCode       STRING,
    itemNo          int,
    remark          STRING,
    caNo            STRING,
    pyeong          int,
    land1           float,
    land2           float,
    floor1          float,
    floor2          float,
    auctionInfo     STRING,
    itemType        STRING,
    appraisedValue  bigint,
    minValue        bigint,
    saleValue       bigint,
    saleRate        int,
    saleCount       int)
    COMMENT 'Auction ES Table'
    STORED BY 'org.elasticsearch.hadoop.hive.EsStorageHandler'
    TBLPROPERTIES('es.resource' = 'auction_data/auction',
    'es.nodes'='dn01', 'es.port'='9201' )
    INFO  : Starting task [Stage-0:DDL] in serial mode
    INFO  : Completed executing command(queryId=hive_20180424200303_5bc78e21-3952-40b3-9378-caaf52b9b125); Time taken: 0.235 seconds
    INFO  : OK
    No rows affected (0.297 seconds)
    0: jdbc:hive2://dn02:10000>
    0: jdbc:hive2://dn02:10000>
    0: jdbc:hive2://dn02:10000> desc formatted auction_es;
    INFO  : Compiling command(queryId=hive_20180424200404_4284a6ac-535d-4b87-b81d-a68305be36e9): desc formatted auction_es
    INFO  : Semantic Analysis Completed
    INFO  : Returning Hive schema: Schema(fieldSchemas:[FieldSchema(name:col_name, type:string, comment:from deserializer), FieldSchema(name:data_type, type:string, comment:from deserializer), FieldSchema(name:comment, type:string, comment:from deserializer)], properties:null)
    INFO  : Completed compiling command(queryId=hive_20180424200404_4284a6ac-535d-4b87-b81d-a68305be36e9); Time taken: 0.041 seconds
    INFO  : Executing command(queryId=hive_20180424200404_4284a6ac-535d-4b87-b81d-a68305be36e9): desc formatted auction_es
    INFO  : Starting task [Stage-0:DDL] in serial mode
    INFO  : Completed executing command(queryId=hive_20180424200404_4284a6ac-535d-4b87-b81d-a68305be36e9); Time taken: 0.019 seconds
    INFO  : OK
    +-------------------------------+----------------------------------------------------+-------------------------------------------------+--+
    |           col_name            |                     data_type                      |                     comment                     |
    +-------------------------------+----------------------------------------------------+-------------------------------------------------+--+
    | # col_name                    | data_type                                          | comment                                         |
    |                               | NULL                                               | NULL                                            |
    | status                        | string                                             | from deserializer                               |
    | auctioncount                  | int                                                | from deserializer                               |
    | auctiondate                   | timestamp                                          | from deserializer                               |
    | addr                          | string                                             | from deserializer                               |
    | addr0                         | string                                             | from deserializer                               |
    | addr1                         | string                                             | from deserializer                               |
    | addr2                         | string                                             | from deserializer                               |
    | addr3                         | string                                             | from deserializer                               |
    | court                         | string                                             | from deserializer                               |
    | courtcode                     | string                                             | from deserializer                               |
    | itemno                        | int                                                | from deserializer                               |
    | remark                        | string                                             | from deserializer                               |
    | cano                          | string                                             | from deserializer                               |
    | pyeong                        | int                                                | from deserializer                               |
    | land1                         | float                                              | from deserializer                               |
    | land2                         | float                                              | from deserializer                               |
    | floor1                        | float                                              | from deserializer                               |
    | floor2                        | float                                              | from deserializer                               |
    | auctioninfo                   | string                                             | from deserializer                               |
    | itemtype                      | string                                             | from deserializer                               |
    | appraisedvalue                | bigint                                             | from deserializer                               |
    | minvalue                      | bigint                                             | from deserializer                               |
    | salevalue                     | bigint                                             | from deserializer                               |
    | salerate                      | int                                                | from deserializer                               |
    | salecount                     | int                                                | from deserializer                               |
    |                               | NULL                                               | NULL                                            |
    | # Detailed Table Information  | NULL                                               | NULL                                            |
    | Database:                     | auctiondb                                          | NULL                                            |
    | Owner:                        | hive                                               | NULL                                            |
    | CreateTime:                   | Tue Apr 24 20:03:45 EDT 2018                       | NULL                                            |
    | LastAccessTime:               | UNKNOWN                                            | NULL                                            |
    | Protect Mode:                 | None                                               | NULL                                            |
    | Retention:                    | 0                                                  | NULL                                            |
    | Location:                     | hdfs://nn01:8020/user/hive/warehouse/auctiondb.db/auction_es | NULL                                            |
    | Table Type:                   | EXTERNAL_TABLE                                     | NULL                                            |
    | Table Parameters:             | NULL                                               | NULL                                            |
    |                               | COLUMN_STATS_ACCURATE                              | false                                           |
    |                               | EXTERNAL                                           | TRUE                                            |
    |                               | comment                                            | Auction ES Table                                |
    |                               | es.nodes                                           | dn01                                            |
    |                               | es.port                                            | 9201                                            |
    |                               | es.resource                                        | auction_data/auction                            |
    |                               | numFiles                                           | 0                                               |
    |                               | numRows                                            | -1                                              |
    |                               | rawDataSize                                        | -1                                              |
    |                               | storage_handler                                    | org.elasticsearch.hadoop.hive.EsStorageHandler  |
    |                               | totalSize                                          | 0                                               |
    |                               | transient_lastDdlTime                              | 1524614625                                      |
    |                               | NULL                                               | NULL                                            |
    | # Storage Information         | NULL                                               | NULL                                            |
    | SerDe Library:                | org.elasticsearch.hadoop.hive.EsSerDe              | NULL                                            |
    | InputFormat:                  | null                                               | NULL                                            |
    | OutputFormat:                 | null                                               | NULL                                            |
    | Compressed:                   | No                                                 | NULL                                            |
    | Num Buckets:                  | -1                                                 | NULL                                            |
    | Bucket Columns:               | []                                                 | NULL                                            |
    | Sort Columns:                 | []                                                 | NULL                                            |
    | Storage Desc Params:          | NULL                                               | NULL                                            |
    |                               | serialization.format                               | 1                                               |
    +-------------------------------+----------------------------------------------------+-------------------------------------------------+--+
    61 rows selected (0.153 seconds)
    0: jdbc:hive2://dn02:10000>
    0: jdbc:hive2://dn02:10000> select
    . . . . . . . . . . . . . >     status,
    . . . . . . . . . . . . . >     cast(auctionCount as int),
    . . . . . . . . . . . . . >     cast(case when length(auctionDate) > 10 then substr(auctionDate,length(auctionDate)-9) else auctionDate end  as timestamp),
    . . . . . . . . . . . . . >     addr,
    . . . . . . . . . . . . . >     addr0,
    . . . . . . . . . . . . . >     addr1,
    . . . . . . . . . . . . . >     addr2,
    . . . . . . . . . . . . . >     addr3,
    . . . . . . . . . . . . . >     court,
    . . . . . . . . . . . . . >     courtCode,
    . . . . . . . . . . . . . >     cast(itemNo as int),
    . . . . . . . . . . . . . >     remark,
    . . . . . . . . . . . . . >     caNo,
    . . . . . . . . . . . . . >     cast(pyeong  as int),
    . . . . . . . . . . . . . >     cast(land1  as float),
    . . . . . . . . . . . . . >     cast(land2  as float),
    . . . . . . . . . . . . . >     cast(floor1  as float),
    . . . . . . . . . . . . . >     cast(floor2 as float),
    . . . . . . . . . . . . . >     auctionInfo,
    . . . . . . . . . . . . . >     itemType,
    . . . . . . . . . . . . . >     cast(appraisedValue as bigint),
    . . . . . . . . . . . . . >     cast(minValue  as bigint),
    . . . . . . . . . . . . . >     cast(regexp_replace(saleValue, ',','') as bigint),
    . . . . . . . . . . . . . >     cast(saleRate as int),
    . . . . . . . . . . . . . >     cast(saleCount as int)
    . . . . . . . . . . . . . > from ctauinfo
    . . . . . . . . . . . . . > limit 10;
    INFO  : Compiling command(queryId=hive_20180424200505_ee18d082-f904-4045-a042-de46314f015a): select
    status,
    cast(auctionCount as int),
    cast(case when length(auctionDate) > 10 then substr(auctionDate,length(auctionDate)-9) else auctionDate end  as timestamp),
    addr,
    addr0,
    addr1,
    addr2,
    addr3,
    court,
    courtCode,
    cast(itemNo as int),
    remark,
    caNo,
    cast(pyeong  as int),
    cast(land1  as float),
    cast(land2  as float),
    cast(floor1  as float),
    cast(floor2 as float),
    auctionInfo,
    itemType,
    cast(appraisedValue as bigint),
    cast(minValue  as bigint),
    cast(regexp_replace(saleValue, ',','') as bigint),
    cast(saleRate as int),
    cast(saleCount as int)
    from ctauinfo
    limit 10
    INFO  : Semantic Analysis Completed
    INFO  : Returning Hive schema: Schema(fieldSchemas:[FieldSchema(name:status, type:string, comment:null), FieldSchema(name:auctioncount, type:int, comment:null), FieldSchema(name:_c2, type:timestamp, comment:null), FieldSchema(name:addr, type:string, comment:null), FieldSchema(name:addr0, type:string, comment:null), FieldSchema(name:addr1, type:string, comment:null), FieldSchema(name:addr2, type:string, comment:null), FieldSchema(name:addr3, type:string, comment:null), FieldSchema(name:court, type:string, comment:null), FieldSchema(name:courtcode, type:string, comment:null), FieldSchema(name:itemno, type:int, comment:null), FieldSchema(name:remark, type:string, comment:null), FieldSchema(name:cano, type:string, comment:null), FieldSchema(name:pyeong, type:int, comment:null), FieldSchema(name:land1, type:float, comment:null), FieldSchema(name:land2, type:float, comment:null), FieldSchema(name:floor1, type:float, comment:null), FieldSchema(name:floor2, type:float, comment:null), FieldSchema(name:auctioninfo, type:string, comment:null), FieldSchema(name:itemtype, type:string, comment:null), FieldSchema(name:appraisedvalue, type:bigint, comment:null), FieldSchema(name:minvalue, type:bigint, comment:null), FieldSchema(name:_c22, type:bigint, comment:null), FieldSchema(name:salerate, type:int, comment:null), FieldSchema(name:salecount, type:int, comment:null)], properties:null)
    INFO  : Completed compiling command(queryId=hive_20180424200505_ee18d082-f904-4045-a042-de46314f015a); Time taken: 0.157 seconds
    INFO  : Executing command(queryId=hive_20180424200505_ee18d082-f904-4045-a042-de46314f015a): select
    status,
    cast(auctionCount as int),
    cast(case when length(auctionDate) > 10 then substr(auctionDate,length(auctionDate)-9) else auctionDate end  as timestamp),
    addr,
    addr0,
    addr1,
    addr2,
    addr3,
    court,
    courtCode,
    cast(itemNo as int),
    remark,
    caNo,
    cast(pyeong  as int),
    cast(land1  as float),
    cast(land2  as float),
    cast(floor1  as float),
    cast(floor2 as float),
    auctionInfo,
    itemType,
    cast(appraisedValue as bigint),
    cast(minValue  as bigint),
    cast(regexp_replace(saleValue, ',','') as bigint),
    cast(saleRate as int),
    cast(saleCount as int)
    from ctauinfo
    limit 10
    INFO  : Query ID = hive_20180424200505_ee18d082-f904-4045-a042-de46314f015a
    INFO  : Total jobs = 1
    INFO  : Launching Job 1 out of 1
    INFO  : Starting task [Stage-1:MAPRED] in serial mode
    INFO  : Number of reduce tasks is set to 0 since there's no reduce operator
    INFO  : number of splits:1
    INFO  : Submitting tokens for job: job_1523845385074_0063
    INFO  : The url to track the job: http://nn01:8088/proxy/application_1523845385074_0063/
    INFO  : Starting Job = job_1523845385074_0063, Tracking URL = http://nn01:8088/proxy/application_1523845385074_0063/
    INFO  : Kill Command = /opt/cloudera/parcels/CDH-5.14.2-1.cdh5.14.2.p0.3/lib/hadoop/bin/hadoop job  -kill job_1523845385074_0063
    INFO  : Hadoop job information for Stage-1: number of mappers: 1; number of reducers: 0
    INFO  : 2018-04-24 20:05:56,876 Stage-1 map = 0%,  reduce = 0%
    INFO  : 2018-04-24 20:06:05,664 Stage-1 map = 100%,  reduce = 0%, Cumulative CPU 3.36 sec
    INFO  : MapReduce Total cumulative CPU time: 3 seconds 360 msec
    INFO  : Ended Job = job_1523845385074_0063
    INFO  : MapReduce Jobs Launched:
    INFO  : Stage-Stage-1: Map: 1   Cumulative CPU: 3.36 sec   HDFS Read: 76093 HDFS Write: 4882 SUCCESS
    INFO  : Total MapReduce CPU Time Spent: 3 seconds 360 msec
    INFO  : Completed executing command(queryId=hive_20180424200505_ee18d082-f904-4045-a042-de46314f015a); Time taken: 16.411 seconds
    INFO  : OK
    +---------+---------------+------------------------+--------------------------------------------+--------+--------+--------+--------+---------+------------+---------+---------+--------------+---------+---------------------+---------------------+---------------------+---------------------+----------------------------------------------+-----------+-----------------+-----------+------------+-----------+------------+--+
    | status  | auctioncount  |          _c2           |                    addr                    | addr0  | addr1  | addr2  | addr3  |  court  | courtcode  | itemno  | remark  |     cano     | pyeong  |        land1        |        land2        |       floor1        |       floor2        |                 auctioninfo                  | itemtype  | appraisedvalue  | minvalue  |    _c22    | salerate  | salecount  |
    +---------+---------------+------------------------+--------------------------------------------+--------+--------+--------+--------+---------+------------+---------+---------+--------------+---------+---------------------+---------------------+---------------------+---------------------+----------------------------------------------+-----------+-----------------+-----------+------------+-----------+------------+--+
    | 배당종결    | 2             | 2008-01-25 00:00:00.0  | 부산광역시 동래구 온천동 1444-1궁전아이브 5층 505호          | 부산광역시  | 동래구    | 온천동    |        | 부산지방법원  | B01        | 1       | 관련사건    | 2007타경6344   | 10      | 10.569999694824219  | 3.200000047683716   | 84.54000091552734   | 25.56999969482422   | 35평형,토지 10.57㎡(3.2평),건물 84.54㎡(25.57평)       | 아파트       | 176000000       | NULL      | NULL       | NULL      | NULL       |
    | 배당종결    | 1             | 2008-01-25 00:00:00.0  | 부산광역시 북구 덕천동 250-9덕천한성맨션 2동 1층 112호        | 부산광역시  | 북구     | 덕천동    |        | 부산지방법원  | B01        | 1       |         | 2007타경9220   | 39      | 39.49599838256836   | 11.949999809265137  | 44.72999954223633   | 13.529999732971191  | 16평형,토지 39.496㎡(11.95평),건물 44.73㎡(13.53평)    | 아파트       | 44000000        | NULL      | 36399900   | 83        | 4          |
    | 배당종결    | 1             | 2008-01-25 00:00:00.0  | 부산광역시 연제구 연산동 57-134연산부전타워 101동 2층 2-202호  | 부산광역시  | 연제구    | 연산동    |        | 부산지방법원  | B01        | 1       |         | 2007타경15720  | 20      | 20.049999237060547  | 6.070000171661377   | 59.91999816894531   | 18.1299991607666    | 25평형,토지 20.05㎡(6.07평),건물 59.92㎡(18.13평)      | 아파트       | 76000000        | NULL      | 65999000   | 87        | 2          |
    | 배당종결    | 1             | 2008-01-25 00:00:00.0  | 부산광역시 사하구 장림동 산21-2장림우림그린빌라 101동 9층 907호   | 부산광역시  | 사하구    | 장림동    |        | 부산지방법원  | B01        | 1       |         | 2007타경20951  | 79      | 79.98269653320312   | 24.190000534057617  | 132.5399932861328   | 40.09000015258789   | 50평형,토지 79.9827㎡(24.19평),건물 132.54㎡(40.09평)  | 아파트       | 120000000       | NULL      | 99100000   | 83        | 3          |
    | 배당종결    | 2             | 2008-01-25 00:00:00.0  | 부산광역시 서구 암남동 81-12송도자유비치아파트 3층 307호        | 부산광역시  | 서구     | 암남동    |        | 부산지방법원  | B01        | 1       |         | 2007타경23424  | 17      | 17.540000915527344  | 5.309999942779541   | 48.630001068115234  | 14.710000038146973  | 20평형,토지 17.54㎡(5.31평),건물 48.63㎡(14.71평)      | 아파트       | 58000000        | NULL      | 42850000   | 74        | 2          |
    | 배당종결    | 1             | 2008-01-25 00:00:00.0  | 부산광역시 사하구 다대동 94삼환2차아파트 102동 10층 1005호     | 부산광역시  | 사하구    | 다대동    |        | 부산지방법원  | B01        | 1       |         | 2007타경26645  | 14      | 14.73900032043457   | 4.460000038146973   | 84.98999786376953   | 25.709999084472656  | 32평형,토지 14.739㎡(4.46평),건물 84.99㎡(25.71평)     | 아파트       | 120000000       | NULL      | 102899000  | 86        | 6          |
    | 배당종결    | 1             | 2008-01-25 00:00:00.0  | 부산광역시 부산진구 부전동 450네오스포 20층 2024호           | 부산광역시  | 부산진구   | 부전동    |        | 부산지방법원  | B01        | 1       |         | 2007타경29422  | 12      | 12.92199993133545   | 3.9100000858306885  | 84.6449966430664    | 25.610000610351562  | 38평형,토지 12.922㎡(3.91평),건물 84.645㎡(25.61평)    | 아파트       | 120000000       | NULL      | 102349000  | 85        | 5          |
    | 배당종결    | 1             | 2008-01-25 00:00:00.0  | 부산광역시 사상구 모라동 75모라주공아파트 402동 7층 702호       | 부산광역시  | 사상구    | 모라동    |        | 부산지방법원  | B01        | 1       |         | 2007타경30903  | 55      | 55.0                | 16.639999389648438  | 49.939998626708984  | 15.109999656677246  | 21평형,토지 55㎡(16.64평),건물 49.94㎡(15.11평)        | 아파트       | 62000000        | NULL      | 55290000   | 89        | 4          |
    | 배당종결    | 1             | 2008-01-25 00:00:00.0  | 부산광역시 부산진구 당감동 516주공아파트 307동 15층 1502호     | 부산광역시  | 부산진구   | 당감동    |        | 부산지방법원  | B01        | 1       |         | 2007타경31494  | 51      | 51.75               | 15.649999618530273  | 79.06999969482422   | 23.920000076293945  | 31평형,토지 51.75㎡(15.65평),건물 79.07㎡(23.92평)     | 아파트       | 105000000       | NULL      | 97000000   | 92        | 5          |
    | 배당종결    | 1             | 2008-01-25 00:00:00.0  | 부산광역시 부산진구 범천동 944-1범천경남아파트 101동 3층 307호   | 부산광역시  | 부산진구   | 범천동    |        | 부산지방법원  | B01        | 1       |         | 2007타경31890  | 17      | 17.339500427246094  | 5.25                | 59.942501068115234  | 18.1299991607666    | 24평형,토지 17.3395㎡(5.25평),건물 59.9425㎡(18.13평)  | 아파트       | 90000000        | NULL      | 77450000   | 86        | 3          |
    +---------+---------------+------------------------+--------------------------------------------+--------+--------+--------+--------+---------+------------+---------+---------+--------------+---------+---------------------+---------------------+---------------------+---------------------+----------------------------------------------+-----------+-----------------+-----------+------------+-----------+------------+--+
    10 rows selected (16.742 seconds)
    0: jdbc:hive2://dn02:10000>
    0: jdbc:hive2://dn02:10000>
    0: jdbc:hive2://dn02:10000> INSERT OVERWRITE TABLE auction_es
    . . . . . . . . . . . . . > select
    . . . . . . . . . . . . . >     status,
    . . . . . . . . . . . . . >     cast(auctionCount as int),
    . . . . . . . . . . . . . >     cast(case when length(auctionDate) > 10 then substr(auctionDate,length(auctionDate)-9) else auctionDate end  as timestamp),
    . . . . . . . . . . . . . >     addr,
    . . . . . . . . . . . . . >     addr0,
    . . . . . . . . . . . . . >     addr1,
    . . . . . . . . . . . . . >     addr2,
    . . . . . . . . . . . . . >     addr3,
    . . . . . . . . . . . . . >     court,
    . . . . . . . . . . . . . >     courtCode,
    . . . . . . . . . . . . . >     cast(itemNo as int),
    . . . . . . . . . . . . . >     remark,
    . . . . . . . . . . . . . >     caNo,
    . . . . . . . . . . . . . >     cast(pyeong  as int),
    . . . . . . . . . . . . . >     cast(land1  as float),
    . . . . . . . . . . . . . >     cast(land2  as float),
    . . . . . . . . . . . . . >     cast(floor1  as float),
    . . . . . . . . . . . . . >     cast(floor2 as float),
    . . . . . . . . . . . . . >     auctionInfo,
    . . . . . . . . . . . . . >     itemType,
    . . . . . . . . . . . . . >     cast(appraisedValue as bigint),
    . . . . . . . . . . . . . >     cast(minValue  as bigint),
    . . . . . . . . . . . . . >     cast(regexp_replace(saleValue, ',','') as bigint),
    . . . . . . . . . . . . . >     cast(saleRate as int),
    . . . . . . . . . . . . . >     cast(saleCount as int)
    . . . . . . . . . . . . . > from ctauinfo;
    INFO  : Compiling command(queryId=hive_20180424203636_5b7587ff-ed1c-4aa4-9506-c57a7174f11f): INSERT OVERWRITE TABLE auction_es
    select
    status,
    cast(auctionCount as int),
    cast(case when length(auctionDate) > 10 then substr(auctionDate,length(auctionDate)-9) else auctionDate end  as timestamp),
    addr,
    addr0,
    addr1,
    addr2,
    addr3,
    court,
    courtCode,
    cast(itemNo as int),
    remark,
    caNo,
    cast(pyeong  as int),
    cast(land1  as float),
    cast(land2  as float),
    cast(floor1  as float),
    cast(floor2 as float),
    auctionInfo,
    itemType,
    cast(appraisedValue as bigint),
    cast(minValue  as bigint),
    cast(regexp_replace(saleValue, ',','') as bigint),
    cast(saleRate as int),
    cast(saleCount as int)
    from ctauinfo
    INFO  : Semantic Analysis Completed
    INFO  : Returning Hive schema: Schema(fieldSchemas:[FieldSchema(name:status, type:string, comment:null), FieldSchema(name:auctioncount, type:int, comment:null), FieldSchema(name:_c2, type:timestamp, comment:null), FieldSchema(name:addr, type:string, comment:null), FieldSchema(name:addr0, type:string, comment:null), FieldSchema(name:addr1, type:string, comment:null), FieldSchema(name:addr2, type:string, comment:null), FieldSchema(name:addr3, type:string, comment:null), FieldSchema(name:court, type:string, comment:null), FieldSchema(name:courtcode, type:string, comment:null), FieldSchema(name:itemno, type:int, comment:null), FieldSchema(name:remark, type:string, comment:null), FieldSchema(name:cano, type:string, comment:null), FieldSchema(name:pyeong, type:int, comment:null), FieldSchema(name:land1, type:float, comment:null), FieldSchema(name:land2, type:float, comment:null), FieldSchema(name:floor1, type:float, comment:null), FieldSchema(name:floor2, type:float, comment:null), FieldSchema(name:auctioninfo, type:string, comment:null), FieldSchema(name:itemtype, type:string, comment:null), FieldSchema(name:appraisedvalue, type:bigint, comment:null), FieldSchema(name:minvalue, type:bigint, comment:null), FieldSchema(name:_c22, type:bigint, comment:null), FieldSchema(name:salerate, type:int, comment:null), FieldSchema(name:salecount, type:int, comment:null)], properties:null)
    INFO  : Completed compiling command(queryId=hive_20180424203636_5b7587ff-ed1c-4aa4-9506-c57a7174f11f); Time taken: 0.157 seconds
    INFO  : Executing command(queryId=hive_20180424203636_5b7587ff-ed1c-4aa4-9506-c57a7174f11f): INSERT OVERWRITE TABLE auction_es
    select
    status,
    cast(auctionCount as int),
    cast(case when length(auctionDate) > 10 then substr(auctionDate,length(auctionDate)-9) else auctionDate end  as timestamp),
    addr,
    addr0,
    addr1,
    addr2,
    addr3,
    court,
    courtCode,
    cast(itemNo as int),
    remark,
    caNo,
    cast(pyeong  as int),
    cast(land1  as float),
    cast(land2  as float),
    cast(floor1  as float),
    cast(floor2 as float),
    auctionInfo,
    itemType,
    cast(appraisedValue as bigint),
    cast(minValue  as bigint),
    cast(regexp_replace(saleValue, ',','') as bigint),
    cast(saleRate as int),
    cast(saleCount as int)
    from ctauinfo
    INFO  : Query ID = hive_20180424203636_5b7587ff-ed1c-4aa4-9506-c57a7174f11f
    INFO  : Total jobs = 1
    INFO  : Launching Job 1 out of 1
    INFO  : Starting task [Stage-0:MAPRED] in serial mode
    INFO  : Number of reduce tasks is set to 0 since there's no reduce operator
    INFO  : number of splits:1
    INFO  : Submitting tokens for job: job_1523845385074_0068
    INFO  : The url to track the job: http://nn01:8088/proxy/application_1523845385074_0068/
    INFO  : Starting Job = job_1523845385074_0068, Tracking URL = http://nn01:8088/proxy/application_1523845385074_0068/
    INFO  : Kill Command = /opt/cloudera/parcels/CDH-5.14.2-1.cdh5.14.2.p0.3/lib/hadoop/bin/hadoop job  -kill job_1523845385074_0068
    INFO  : Hadoop job information for Stage-0: number of mappers: 1; number of reducers: 0
    INFO  : 2018-04-24 20:37:06,539 Stage-0 map = 0%,  reduce = 0%
    INFO  : 2018-04-24 20:37:23,773 Stage-0 map = 26%,  reduce = 0%, Cumulative CPU 13.66 sec
    INFO  : 2018-04-24 20:37:29,124 Stage-0 map = 44%,  reduce = 0%, Cumulative CPU 17.37 sec
    INFO  : 2018-04-24 20:37:35,530 Stage-0 map = 63%,  reduce = 0%, Cumulative CPU 21.11 sec
    INFO  : 2018-04-24 20:37:41,941 Stage-0 map = 81%,  reduce = 0%, Cumulative CPU 24.78 sec
    INFO  : 2018-04-24 20:37:47,279 Stage-0 map = 96%,  reduce = 0%, Cumulative CPU 28.43 sec
    INFO  : 2018-04-24 20:37:48,350 Stage-0 map = 100%,  reduce = 0%, Cumulative CPU 28.62 sec
    INFO  : MapReduce Total cumulative CPU time: 28 seconds 620 msec
    INFO  : Ended Job = job_1523845385074_0068
    INFO  : MapReduce Jobs Launched:
    INFO  : Stage-Stage-0: Map: 1   Cumulative CPU: 28.62 sec   HDFS Read: 141856578 HDFS Write: 0 SUCCESS
    INFO  : Total MapReduce CPU Time Spent: 28 seconds 620 msec
    INFO  : Completed executing command(queryId=hive_20180424203636_5b7587ff-ed1c-4aa4-9506-c57a7174f11f); Time taken: 49.646 seconds
    INFO  : OK
    No rows affected (49.895 seconds)
    0: jdbc:hive2://dn02:10000>
    0: jdbc:hive2://dn02:10000>
    0: jdbc:hive2://dn02:10000>
    0: jdbc:hive2://dn02:10000> select status, addr, cano from auction_es limit 10;
    INFO  : Compiling command(queryId=hive_20180424203838_8c92fe0d-c0ac-4187-8ef0-e0137395204d): select status, addr, cano from auction_es limit 10
    INFO  : Semantic Analysis Completed
    INFO  : Returning Hive schema: Schema(fieldSchemas:[FieldSchema(name:status, type:string, comment:null), FieldSchema(name:addr, type:string, comment:null), FieldSchema(name:cano, type:string, comment:null)], properties:null)
    INFO  : Completed compiling command(queryId=hive_20180424203838_8c92fe0d-c0ac-4187-8ef0-e0137395204d); Time taken: 0.096 seconds
    INFO  : Executing command(queryId=hive_20180424203838_8c92fe0d-c0ac-4187-8ef0-e0137395204d): select status, addr, cano from auction_es limit 10
    INFO  : Completed executing command(queryId=hive_20180424203838_8c92fe0d-c0ac-4187-8ef0-e0137395204d); Time taken: 0.002 seconds
    INFO  : OK
    +---------+--------------------------------------------------+--------------+--+
    | status  |                       addr                       |     cano     |
    +---------+--------------------------------------------------+--------------+--+
    | 배당종결    | 경상남도 창녕군 남지읍 남지리 293-1 푸른마을아파트 나동 9층 1008호       | 2007타경7169   |
    | 배당종결    | 경상남도 밀양시 교동 1225 아침해오름아파트 101동 5층 503호           | 2008타경1502   |
    | 취하      | 경상남도 진주시 칠암동 277 현대아파트 나동 1층 101호                | 2008타경16614  |
    | 배당종결    | 광주광역시 북구 동림동 1147-1 동림푸른마을주공3단지아파트 301동 4층 403호  | 2008타경45154  |
    | 취하      | 광주광역시 광산구 도산동 1136-1 호반아파트 101동 12층 1203호        | 2008타경45307  |
    | 배당종결    | 전라북도 진안군 진안읍 군상리 200-1 고향마을아파트 105동 11층 1106호    | 2008타경9384   |
    | 배당종결    | 광주광역시 서구 풍암동 1096 현대삼환아파트 105동 1층 105호           | 2008타경47778  |
    | 배당종결    | 전라북도 김제시 만경읍 몽산리 79-4 만경영광아파트 101동 7층 702호       | 2008타경11097  |
    | 배당종결    | 광주광역시 동구 용산동 147-1 호반아파트 13층 1413호               | 2008타경48245  |
    | 배당종결    | 전라북도 김제시 만경읍 몽산리 79-4 만경영광아파트 102동 3층 302호       | 2008타경11097  |
    +---------+--------------------------------------------------+--------------+--+
    10 rows selected (0.352 seconds)
    0: jdbc:hive2://dn02:10000>
    0: jdbc:hive2://dn02:10000>
    0: jdbc:hive2://dn02:10000> !list
    1 active connection:
    #0  open     jdbc:hive2://dn02:10000
    0: jdbc:hive2://dn02:10000>
    0: jdbc:hive2://dn02:10000> 
    0: jdbc:hive2://dn02:10000> !quit
    Closing: 0: jdbc:hive2://dn02:10000
    [eduuser@dn01 dist]$

참고


MySQL SSH 터널링

  1. MySQL Workbench 설치 후 새로운 연결을 만든다.
    my

  2. 연결 설정에서 Connection Method 를 Standard TCP/IP over SSH 로 설정한다. my

  3. 연결 설정에서 SSH 와 MySQL 연결 정보를 설정하고 각각의 암호를 저장한다. my my my

  4. Test Connection 버튼을 누르고 연결 테스트를 한다. my my

  5. 연결 테스트 정상확인 후 연결하여 데이터를 확인 한다. my my

Published 11 May 2018

속도보다 방향이 중요하다!
nadawoom on Twitter