电竞比分网-中国电竞赛事及体育赛事平台

分享

華為GuassDB 200輕量化單節(jié)點模式部署指南

 印度阿三17 2019-10-23

對于集群環(huán)境的安裝,可以參照之前寫的《FusionInsight LibrA V100R002C80SPC300安裝指南》。

1、環(huán)境信息

華為GuassDB 200輕量化單節(jié)點模式部署指南
其中50G的是操作系統(tǒng)盤,其他三個100G的用于GuassDB。

2、配置軟件包

  • 軟件包準備
    從官方網(wǎng)站下載如下軟件包,并上傳至/opt目錄:
    [root@hd06 ~]# cd /opt/
    [root@hd06 opt]# ls
    FusionInsight_BASE_6.5.1_RHEL.tar.gz     FusionInsight_SetupTool_6.5.1.tar.gz
    FusionInsight_Manager_6.5.1_RHEL.tar.gz  GaussDB_200_6.5.1_RHEL.tar.gz

    然后解壓下面三個軟件包:

    [root@hd06 opt]# tar -xzf FusionInsight_Manager_6.5.1_RHEL.tar.gz 
    [root@hd06 opt]# tar -xzf FusionInsight_SetupTool_6.5.1.tar.gz 
    [root@hd06 opt]# tar -xzf GaussDB_200_6.5.1_RHEL.tar.gz 

    解壓完成后,分別將除Manager外的其他部件包拷貝至“/opt/FusionInsight_Manager/software/packs”路徑下(如同時安裝其他部件,需要一起拷貝):

    [root@hd06 opt]# cp FusionInsight_BASE_6.5.1_RHEL.tar.gz FusionInsight_MPPDB_6.5.1_RHEL.tar.gz FusionInsight_Manager/software/packs/
  • 掛載操作系統(tǒng)鏡像
    [root@hd06 opt]# mount /dev/sr0 /media/
  • 確認操作系統(tǒng)編碼
    操作系統(tǒng)的編碼必須為“en_US.UTF-8”或“POSIX”。
  • 拷貝預(yù)配置文件夾
    將要安裝GaussDB 200的節(jié)點上的“/opt/FusionInsight_SetupTool/preset”文件夾拷貝至節(jié)點的“/opt”目錄下并在所有節(jié)點上執(zhí)行sh /opt/preset/preset.sh命令。
    [root@hd06 opt]# cp -r /opt/FusionInsight_SetupTool/preset .
    [root@hd06 opt]# sh preset/preset.sh 
    start to preSet
    success to preSet.
  • 修改/opt/FusionInsight_Manager和/opt/FusionInsight_SetupTool屬主
    [root@hd06 opt]# chown omm: /opt/FusionInsight_Manager/ -R
    [root@hd06 opt]# chown omm: /opt/FusionInsight_SetupTool -R

    3、修改操作系統(tǒng)配置文件

    節(jié)點的操作系統(tǒng)配置文件包含操作系統(tǒng)配置文件(“preinstall.ini”)、節(jié)點的分區(qū)配置文件(“host0.ini”),根據(jù)樣例手動生成各文件,修改相應(yīng)參數(shù),并上傳到各節(jié)點相應(yīng)位置。

  • 修改preinstall.ini文件
    [root@hd06 opt]# cd FusionInsight_SetupTool/preinstall
    [root@hd06 preinstall]# vi preinstall.ini
    g_hosts="192.168.120.31"
    g_parted=2
    g_parted_conf="192.168.120.31:host0.ini;"
    g_hostname_conf="192.168.120.31:192.168.120.31:hd06;"
    g_add_pkg=1
    g_pkgs_dir="centos-7.4:/media/"
    g_swap_off=1
    g_user_name="root"
    g_port=22
    g_log_file="/tmp/fi-preinstall.log"
    g_check=1
    g_debug=0
    g_wce_conf=0
    g_platform="x86_64"
    g_optimize="default"
    g_kms_conf=0
    g_core_dump=0
    g_core_dump_dir="/var/log/core"
  • 創(chuàng)建host0.ini文件
    [root@hd06 preinstall]# vi partition/ini/host0.ini 
    #mount               required    care    condition
    dbdata_om.conf       y           y       n                 
    backup_om.conf       y           y       n                  
    mppdb1.conf          y           y       n          

    以上參數(shù)的具體意義,請參考官方文檔。此步驟執(zhí)行完成后,會掛載相應(yīng)的分區(qū),如下圖:
    華為GuassDB 200輕量化單節(jié)點模式部署指南

    4、執(zhí)行preinstall

    進入preinstall執(zhí)行目錄,并執(zhí)行preinstall腳本,此時需要輸入用戶密碼。

[root@hd06 preinstall]# cd ..
[root@hd06 FusionInsight_SetupTool]# ./setuptool.sh preinstall -n
Please enter cluster SSH password for root: 
**FusionInsight PreInstall is starting...
**********************************
*****FusionInsight Preinstall***** 
********************************** 
***** Time:66s 
***** Running:0 
***** Success:1 
***** Failure:0 
***** Total:1 
***** Schedule:100%

You can get more information about the preinstall from /tmp/fi-preinstall.log and /tmp/diskmgt/autopart.log

5、安裝單機Manager

  • 修改install.ini文件
    [root@hd06 ~]# cd /opt/FusionInsight_Manager/software
    [root@hd06 software]# vi install.ini
    [HA]
    ha_mode=single
    local_ip1=192.168.120.31
    local_ip2=
    local_ip3=
    local_ip4=
    peer_ip1=
    peer_ip2=
    peer_ip3=
    peer_ip4=
    ws_float_ip=
    ws_float_ip_interface=
    ws_float_ip_netmask=
    ws_gateway=
    om_float_ip=
    om_float_ip_interface=
    om_float_ip_netmask=
    om_gateway=
    ntp_server_ip=
    om_mediator_ip=
    sso_ip=
    sso_port=
    bigdata_home=/opt/huawei/Bigdata
    bigdata_data_home=/srv/BigData
    cluster_nodes_scale=
    tls_protocol_min=
    realm_parse_ip=
    kerberos_realm=
    [/HA]

    ha_mode默認值為double,這里改為single;
    local_ip1為本機的ip;
    bigdata_home為集群安裝目錄,可自定義;
    bigdata_data_home為集群數(shù)據(jù)目錄,可自定義。

  • 執(zhí)行安裝
    [root@hd06 software]# ./install.sh -f /opt/FusionInsight_Manager/software/install.ini
    =================================== Welcome ===================================
    === STEP 1 Checking the parameters.
    === STEP 2 Preparing for installation components.                         [done]
    === STEP 3 Installing the manager.                                                 [done]
    === STEP 4 Installing the packs.                                                      [done]
    === STEP 5 Starting the OMS.                                                         [done]
    === STEP 6 Waiting for ntp to startup.                                              [done]
    === STEP 7 Configuring and starting agent.                                     [done]
    ============================= Install Successfully ============================
    Please visit http://192.168.120.31:8080/web/ to continue cluster installation.
    Installation is successful. 

    6、執(zhí)行單機版配置腳本

    GaussDB 200默認部署方案至少需要3個節(jié)點,如需部署單機版需要在安裝集群前,運行單機版配置腳本,將各服務(wù)實例的最小配置實例數(shù)改為1。執(zhí)行單機版配置腳本后,需要重啟controller生效。

    [root@hd06 ~]# su - omm
    Last login: Wed Oct 23 11:08:25 CST 2019
    [omm@hd06 ~]$ sh ${BIGDATA_HOME}/om-server/om/sbin/enable_single_host_cluster.sh
    [omm@hd06 ~]$ sh ${BIGDATA_HOME}/om-server/om/sbin/restart-controller.sh
    Restarting controller service using configuration /opt/huawei/Bigdata/om-server/om/sbin/../etc/om
    Enter into stop-controller.sh
    End into stop-controller.sh
    Enter into start-controller.sh
    Controller start with process id 11163.
    End into start-controller.sh
    [omm@hd06 ~]$ 

    7、安裝單節(jié)點GaussDB 200

    使用第5步生成的訪問地址登陸到FusionInsight Manager系統(tǒng),初次登陸需要更改admin密碼,初始密碼為Admin@123。點擊"創(chuàng)建集群",如下圖:
    華為GuassDB 200輕量化單節(jié)點模式部署指南
    華為GuassDB 200輕量化單節(jié)點模式部署指南
    集群的名稱可以自定義,產(chǎn)品類型為默認,認證模式模式為安全模式。
    華為GuassDB 200輕量化單節(jié)點模式部署指南
    輸入本機的IP信息,以及root密碼,點擊查找。
    華為GuassDB 200輕量化單節(jié)點模式部署指南
    華為GuassDB 200輕量化單節(jié)點模式部署指南
    華為GuassDB 200輕量化單節(jié)點模式部署指南
    選中MPPDB,下一步。
    華為GuassDB 200輕量化單節(jié)點模式部署指南
    勾選上所有角色,下一步。
    華為GuassDB 200輕量化單節(jié)點模式部署指南
    華為GuassDB 200輕量化單節(jié)點模式部署指南
    華為GuassDB 200輕量化單節(jié)點模式部署指南
    華為GuassDB 200輕量化單節(jié)點模式部署指南

8、安裝后檢查

  • 檢查集群狀態(tài)
    登錄FusionInsight Manager系統(tǒng),檢查服務(wù)的狀態(tài)。選擇“集群 > 待操作的集群名稱 > 服務(wù)”,各服務(wù)的“運行狀態(tài)”為“良好”。如下圖:
    華為GuassDB 200輕量化單節(jié)點模式部署指南
    檢查節(jié)點狀態(tài)。在FusionInsight Manager頁面單擊“主機”,各節(jié)點的“運行狀態(tài)”為“良好”。如下圖:
    華為GuassDB 200輕量化單節(jié)點模式部署指南

使用命令檢查,如下:

[omm@hd06 ~]$ source ${BIGDATA_HOME}/mppdb/.mppdbgs_profile
[omm@hd06 ~]$ gs_om -t status --detail
[  CMServer State   ]

node    node_ip         instance                                    state
---------------------------------------------------------------------------
1  hd06 192.168.120.31  1    /opt/huawei/Bigdata/mppdb/cm/cm_server Primary

[   Cluster State   ]

cluster_state   : Normal
redistributing  : No
balanced        : Yes

[ Coordinator State ]

node    node_ip         instance                                  state
-------------------------------------------------------------------------
1  hd06 192.168.120.31  5001 /srv/BigData/mppdb/data1/coordinator Normal

[ Central Coordinator State ]

node    node_ip         instance                                  state
-------------------------------------------------------------------------
1  hd06 192.168.120.31  5001 /srv/BigData/mppdb/data1/coordinator Normal

[     GTM State     ]

node    node_ip         instance                           state     
---------------------------------------------------------------------
1  hd06 192.168.120.31  1001 /opt/huawei/Bigdata/mppdb/gtm P Primary 
[  Datanode State   ]

node    node_ip         instance                              state
---------------------------------------------------------------------------------
1  hd06 192.168.120.31  6001 /srv/BigData/mppdb/data1/master1 P Primary Normal
1  hd06 192.168.120.31  6002 /srv/BigData/mppdb/data1/master2 P Primary Normal
1  hd06 192.168.120.31  6003 /srv/BigData/mppdb/data1/master3 P Primary Normal
1  hd06 192.168.120.31  6004 /srv/BigData/mppdb/data1/master4 P Primary Normal
1  hd06 192.168.120.31  6005 /srv/BigData/mppdb/data1/master5 P Primary Normal
1  hd06 192.168.120.31  6006 /srv/BigData/mppdb/data1/master6 P Primary Normal
[omm@hd06 ~]$ 
  • 執(zhí)行健康檢查
    選擇“集群 > 待操作的集群名稱” > 選擇“更多 > 健康檢查”。
    華為GuassDB 200輕量化單節(jié)點模式部署指南
來源:https://www./content-4-515251.html

    本站是提供個人知識管理的網(wǎng)絡(luò)存儲空間,所有內(nèi)容均由用戶發(fā)布,不代表本站觀點。請注意甄別內(nèi)容中的聯(lián)系方式、誘導(dǎo)購買等信息,謹防詐騙。如發(fā)現(xiàn)有害或侵權(quán)內(nèi)容,請點擊一鍵舉報。
    轉(zhuǎn)藏 分享 獻花(0

    0條評論

    發(fā)表

    請遵守用戶 評論公約

    類似文章 更多