在Starrocks存算一体模式的安装方式中,官方只提供两种部署文件,一种是二进制安装介质,StarRocks 二进制包的名称格式为 StarRocks-version.tar.gz,这种部署文件只适合CentOS 7.9操作系统安装。另外一种是StarRocks Docker 镜像,可以从 StarRocks Docker Hub 下载下载,这种部署文件适合Ubuntu 22.04和使用ARM架构CPU的操作系统上。见官方文档http://docs.mirrorship.cn/zh/docs/deployment/prepare_deployment_files/。

以下延时使用docker方式安装Starrocks,过程包括在Ubuntu 22.04安装docker engine。
--Ubuntu 22.04安装docker engine

root@startestdb01:~# apt-get updateHit:1 http://mirrors.cloud.aliyuncs.com/ubuntu jammy InReleaseHit:2 http://mirrors.cloud.aliyuncs.com/ubuntu jammy-updates InReleaseHit:3 http://mirrors.cloud.aliyuncs.com/ubuntu jammy-backports InReleaseHit:4 http://mirrors.cloud.aliyuncs.com/ubuntu jammy-security InReleaseReading package lists... Doneroot@startestdb01:~#root@startestdb01:~#root@startestdb01:~#root@startestdb01:~#root@startestdb01:~#root@startestdb01:~# sudo apt-get install apt-transport-https ca-certificates curl gnupg-agent software-properties-commonReading package lists... DoneBuilding dependency tree... DoneReading state information... Doneca-certificates is already the newest version (20230311ubuntu0.22.04.1).ca-certificates set to manually installed.curl is already the newest version (7.81.0-1ubuntu1.15).software-properties-common is already the newest version (0.99.22.9).software-properties-common set to manually installed.The following NEW packages will be installed:apt-transport-https gnupg-agent0 upgraded, 2 newly installed, 0 to remove and 53 not upgraded.Need to get 6,994 B of archives.After this operation, 217 kB of additional disk space will be used.Do you want to continue? [Y/n] yGet:1 http://mirrors.cloud.aliyuncs.com/ubuntu jammy-updates/universe amd64 apt-transport-https all 2.4.11 [1,510 B]Get:2 http://mirrors.cloud.aliyuncs.com/ubuntu jammy-updates/universe amd64 gnupg-agent all 2.2.27-3ubuntu2.1 [5,484 B]Fetched 6,994 B in 0s (47.1 kB/s)Selecting previously unselected package apt-transport-https.(Reading database ... 82223 files and directories currently installed.)Preparing to unpack .../apt-transport-https_2.4.11_all.deb ...Unpacking apt-transport-https (2.4.11) ...Selecting previously unselected package gnupg-agent.Preparing to unpack .../gnupg-agent_2.2.27-3ubuntu2.1_all.deb ...Unpacking gnupg-agent (2.2.27-3ubuntu2.1) ...Setting up apt-transport-https (2.4.11) ...Setting up gnupg-agent (2.2.27-3ubuntu2.1) ...Scanning processes...Scanning linux images...Running kernel seems to be up-to-date.No services need to be restarted.No containers need to be restarted.No user sessions are running outdated binaries.No VM guests are running outdated hypervisor (qemu) binaries on this host.root@startestdb01:~#root@startestdb01:~#root@startestdb01:~#root@startestdb01:~#root@startestdb01:~# curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -Warning: apt-key is deprecated. Manage keyring files in trusted.gpg.d instead (see apt-key(8)).OKroot@startestdb01:~#root@startestdb01:~#root@startestdb01:~#root@startestdb01:~# sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb\_release -cs) stable"Repository: 'deb [arch=amd64] https://download.docker.com/linux/ubuntu jammy stable'Description:Archive for codename: jammy components: stableMore info: https://download.docker.com/linux/ubuntuAdding repository.Press [ENTER] to continue or Ctrl-c to cancel.Adding deb entry to etc/apt/sources.list.d/archive_uri-https_download_docker_com_linux_ubuntu-jammy.listAdding disabled deb-src entry to etc/apt/sources.list.d/archive_uri-https_download_docker_com_linux_ubuntu-jammy.listHit:1 http://mirrors.cloud.aliyuncs.com/ubuntu jammy InReleaseHit:2 http://mirrors.cloud.aliyuncs.com/ubuntu jammy-updates InReleaseHit:3 http://mirrors.cloud.aliyuncs.com/ubuntu jammy-backports InReleaseHit:4 http://mirrors.cloud.aliyuncs.com/ubuntu jammy-security InRelease0% [Connecting to download.docker.com (108.139.10.9)]0% [Connecting to download.docker.com (108.139.10.9)]Get:5 https://download.docker.com/linux/ubuntu jammy InRelease [48.8 kB]Get:6 https://download.docker.com/linux/ubuntu jammy/stable amd64 Packages [27.6 kB]Fetched 76.4 kB in 1s (58.2 kB/s)Reading package lists... DoneW: https://download.docker.com/linux/ubuntu/dists/jammy/InRelease: Key is stored in legacy trusted.gpg keyring (/etc/apt/trusted.gpg), see the DEPRECATION section in apt-key(8) for details.root@startestdb01:~#root@startestdb01:~#root@startestdb01:~#root@startestdb01:~#root@startestdb01:~# sudo apt-get updateHit:1 http://mirrors.cloud.aliyuncs.com/ubuntu jammy InReleaseHit:2 http://mirrors.cloud.aliyuncs.com/ubuntu jammy-updates InReleaseHit:3 http://mirrors.cloud.aliyuncs.com/ubuntu jammy-backports InReleaseHit:4 http://mirrors.cloud.aliyuncs.com/ubuntu jammy-security InReleaseHit:5 https://download.docker.com/linux/ubuntu jammy InReleaseReading package lists... DoneW: https://download.docker.com/linux/ubuntu/dists/jammy/InRelease: Key is stored in legacy trusted.gpg keyring (/etc/apt/trusted.gpg), see the DEPRECATION section in apt-key(8) for details.root@startestdb01:~#root@startestdb01:~#root@startestdb01:~#root@startestdb01:~# sudo apt-get install docker-ce docker-ce-cli containerd.ioReading package lists... DoneBuilding dependency tree... DoneReading state information... DoneThe following additional packages will be installed:docker-buildx-plugin docker-ce-rootless-extras docker-compose-plugin libslirp0 pigz slirp4netnsSuggested packages:aufs-tools cgroupfs-mount | cgroup-liteThe following NEW packages will be installed:containerd.io docker-buildx-plugin docker-ce docker-ce-cli docker-ce-rootless-extras docker-compose-plugin libslirp0 pigz slirp4netns0 upgraded, 9 newly installed, 0 to remove and 53 not upgraded.Need to get 119 MB of archives.After this operation, 424 MB of additional disk space will be used.Do you want to continue? [Y/n] yGet:1 http://mirrors.cloud.aliyuncs.com/ubuntu jammy/universe amd64 pigz amd64 2.6-1 [63.6 kB]Get:2 http://mirrors.cloud.aliyuncs.com/ubuntu jammy/main amd64 libslirp0 amd64 4.6.1-1build1 [61.5 kB]Get:3 http://mirrors.cloud.aliyuncs.com/ubuntu jammy/universe amd64 slirp4netns amd64 1.0.1-2 [28.2 kB]Get:4 https://download.docker.com/linux/ubuntu jammy/stable amd64 containerd.io amd64 1.6.28-1 [29.6 MB]Get:5 https://download.docker.com/linux/ubuntu jammy/stable amd64 docker-buildx-plugin amd64 0.13.0-1~ubuntu.22.04~jammy [29.5 MB]Get:6 https://download.docker.com/linux/ubuntu jammy/stable amd64 docker-ce-cli amd64 5:25.0.4-1~ubuntu.22.04~jammy [13.7 MB]Get:7 https://download.docker.com/linux/ubuntu jammy/stable amd64 docker-ce amd64 5:25.0.4-1~ubuntu.22.04~jammy [24.3 MB]Get:8 https://download.docker.com/linux/ubuntu jammy/stable amd64 docker-ce-rootless-extras amd64 5:25.0.4-1~ubuntu.22.04~jammy [9,320 kB]Get:9 https://download.docker.com/linux/ubuntu jammy/stable amd64 docker-compose-plugin amd64 2.24.7-1~ubuntu.22.04~jammy [12.1 MB]Fetched 119 MB in 11s (11.2 MB/s)Selecting previously unselected package pigz.(Reading database ... 82231 files and directories currently installed.)Preparing to unpack .../0-pigz_2.6-1_amd64.deb ...Unpacking pigz (2.6-1) ...Selecting previously unselected package containerd.io.Preparing to unpack .../1-containerd.io_1.6.28-1_amd64.deb ...Unpacking containerd.io (1.6.28-1) ...Selecting previously unselected package docker-buildx-plugin.Preparing to unpack .../2-docker-buildx-plugin_0.13.0-1~ubuntu.22.04~jammy_amd64.deb ...Unpacking docker-buildx-plugin (0.13.0-1~ubuntu.22.04~jammy) ...Selecting previously unselected package docker-ce-cli.Preparing to unpack .../3-docker-ce-cli_5%3a25.0.4-1~ubuntu.22.04~jammy_amd64.deb ...Unpacking docker-ce-cli (5:25.0.4-1~ubuntu.22.04~jammy) ...Selecting previously unselected package docker-ce.Preparing to unpack .../4-docker-ce_5%3a25.0.4-1~ubuntu.22.04~jammy_amd64.deb ...Unpacking docker-ce (5:25.0.4-1~ubuntu.22.04~jammy) ...Selecting previously unselected package docker-ce-rootless-extras.Preparing to unpack .../5-docker-ce-rootless-extras_5%3a25.0.4-1~ubuntu.22.04~jammy_amd64.deb ...Unpacking docker-ce-rootless-extras (5:25.0.4-1~ubuntu.22.04~jammy) ...Selecting previously unselected package docker-compose-plugin.Preparing to unpack .../6-docker-compose-plugin_2.24.7-1~ubuntu.22.04~jammy_amd64.deb ...Unpacking docker-compose-plugin (2.24.7-1~ubuntu.22.04~jammy) ...Selecting previously unselected package libslirp0:amd64.Preparing to unpack .../7-libslirp0_4.6.1-1build1_amd64.deb ...Unpacking libslirp0:amd64 (4.6.1-1build1) ...Selecting previously unselected package slirp4netns.Preparing to unpack .../8-slirp4netns_1.0.1-2_amd64.deb ...Unpacking slirp4netns (1.0.1-2) ...Setting up docker-buildx-plugin (0.13.0-1~ubuntu.22.04~jammy) ...Setting up containerd.io (1.6.28-1) ...Created symlink etc/systemd/system/multi-user.target.wants/containerd.service → lib/systemd/system/containerd.service.Setting up docker-compose-plugin (2.24.7-1~ubuntu.22.04~jammy) ...Setting up docker-ce-cli (5:25.0.4-1~ubuntu.22.04~jammy) ...Setting up libslirp0:amd64 (4.6.1-1build1) ...Setting up pigz (2.6-1) ...Setting up docker-ce-rootless-extras (5:25.0.4-1~ubuntu.22.04~jammy) ...Setting up slirp4netns (1.0.1-2) ...Setting up docker-ce (5:25.0.4-1~ubuntu.22.04~jammy) ...Created symlink etc/systemd/system/multi-user.target.wants/docker.service → lib/systemd/system/docker.service.Created symlink etc/systemd/system/sockets.target.wants/docker.socket → lib/systemd/system/docker.socket.Processing triggers for man-db (2.10.2-1) ...Processing triggers for libc-bin (2.35-0ubuntu3.6) ...Scanning processes...Scanning linux images...Running kernel seems to be up-to-date.No services need to be restarted.No containers need to be restarted.No user sessions are running outdated binaries.No VM guests are running outdated hypervisor (qemu) binaries on this host.root@startestdb01:~#root@startestdb01:~# sudo systemctl start dockerroot@startestdb01:~#root@startestdb01:~# docker --versionDocker version 25.0.4, build 1a576c5root@startestdb01:~#
--docker容器部署Starrocks

Welcome to Ubuntu 22.04.3 LTS (GNU/Linux 5.15.0-92-generic x86_64)* Documentation: https://help.ubuntu.com* Management: https://landscape.canonical.com* Support: https://ubuntu.com/proSystem information as of Mon Mar 18 07:16:54 PM CST 2024System load: 0.05126953125 Processes: 120Usage of : 7.0% of 48.85GB Users logged in: 1Memory usage: 20% IPv4 address for docker0: 172.18.0.1Swap usage: 0% IPv4 address for eth0: 172.17.7.11* Strictly confined Kubernetes makes edge and IoT secure. Learn how MicroK8sjust raised the bar for easy, resilient and secure K8s cluster deployment.https://ubuntu.com/engage/secure-kubernetes-at-the-edgeExpanded Security Maintenance for Applications is not enabled.53 updates can be applied immediately.26 of these updates are standard security updates.To see these additional updates run: apt list --upgradable2 additional security updates can be applied with ESM Apps.Learn more about enabling ESM Apps service at https://ubuntu.com/esmWelcome to Alibaba Cloud Elastic Compute Service !Last login: Mon Mar 18 18:03:56 2024 from 223.104.63.35root@startestdb01:~#root@startestdb01:~# docker search starrocksNAME DESCRIPTION STARS OFFICIALstarrocks/fe-ubuntu 3starrocks/operator 1starrocks/allin1-ubuntu 5starrocks/be-ubuntu 4starrocks/cn-ubuntu 0starrocks/dev-env-centos7 7starrocks/dev-env-ubuntu 0starrocks/toolchains-centos7 0starrocks/allin1-ubi 0starrocks/artifacts-ubuntu 0starrocks/starlet-artifacts-centos7 0starrocks/toolchains-ubuntu 0starrocks/starlet-artifacts-ubuntu22 0starrocks/artifacts-centos7 0d87904488/starrocks-starter StarRocks docker images for starter, learnin… 0starrocks/be-ubi 0starrocks/fe-ubi 0starrocks/cn-ubi 0starrocks/static-debian11 0starrocks/destination-starrocks 0screnwei/starrocks-computenodegroup 0starrocks/starlet-dev-env-ubuntu22 0starrocks/starlet-dev-env-centos7 0d87904488/starrocks-docker-dev One-click StarRocks Docker development envir… 0landnow/starrocks-computenodegroup [wx:landnow]Kubernetes image, starrocks-comp… 0root@startestdb01:~#root@startestdb01:~#root@startestdb01:~#root@startestdb01:~#root@startestdb01:~#root@startestdb01:~#root@startestdb01:~#root@startestdb01:~#root@startestdb01:~# docker pull starrocks/starrocks:v3.2.1Error response from daemon: pull access denied for starrocks/starrocks, repository does not exist or may require 'docker login': denied: requested access to the resource is deniedroot@startestdb01:~#root@startestdb01:~#root@startestdb01:~#root@startestdb01:~#root@startestdb01:~# docker run -p 9030:9030 -p 8030:8030 -p 8040:8040 -itd starrocks.docker.scarf.sh/starrocks/allin1-ubuntuUnable to find image 'starrocks.docker.scarf.sh/starrocks/allin1-ubuntu:latest' locallylatest: Pulling from starrocks/allin1-ubuntubccd10f490ab: Pull complete72309d075652: Pull completefeaff302b015: Pull complete3880565b2b14: Pull complete3609cd502a5d: Pull complete9bdc47d07866: Downloading [=============> ] 345.9MB/1.283GB50ae5afe7959: Download completede7586a7c43f: Download completed6b64f21c2f5: Download completeea1dc9afb074: Download completeDigest: sha256:13e15f455a09c11f07d6fdda567197e8ae9dfffae407f457c8a8309c9da57610Status: Downloaded newer image for starrocks.docker.scarf.sh/starrocks/allin1-ubuntu:latest2ecaa8cab9efdf40d69e82af4e80c11a2f7a1dde67896c432f52eb01059ccbedroot@sroot@startestdb01:~# apt install mysql-client-core-8.0Reading package lists... DoneBuilding dependency tree... DoneReading state information... DoneThe following NEW packages will be installed:mysql-client-core-8.00 upgraded, 1 newly installed, 0 to remove and 53 not upgraded.Need to get 2,692 kB of archives.After this operation, 62.0 MB of additional disk space will be used.Get:1 http://mirrors.cloud.aliyuncs.com/ubuntu jammy-updates/main amd64 mysql-client-core-8.0 amd64 8.0.36-0ubuntu0.22.04.1 [2,692 kB]Fetched 2,692 kB in 0s (18.8 MB/s)Selecting previously unselected package mysql-client-core-8.0.(Reading database ... 82490 files and directories currently installed.)Preparing to unpack .../mysql-client-core-8.0_8.0.36-0ubuntu0.22.04.1_amd64.deb ...Unpacking mysql-client-core-8.0 (8.0.36-0ubuntu0.22.04.1) ...Setting up mysql-client-core-8.0 (8.0.36-0ubuntu0.22.04.1) ...Processing triggers for man-db (2.10.2-1) ...Scanning processes...Scanning linux images...Running kernel seems to be up-to-date.No services need to be restarted.No containers need to be restarted.No user sessions are running outdated binaries.No VM guests are running outdated hypervisor (qemu) binaries on this host.root@startestdb01:~#root@startestdb01:~#root@startestdb01:~#root@startestdb01:~#root@startestdb01:~# mysql -P9030 -h127.0.0.1 -uroot --prompt="StarRocks > "Welcome to the MySQL monitor. Commands end with ; or \g.Your MySQL connection id is 10Server version: 5.1.0 3.2.4-613f0b5Copyright (c) 2000, 2024, Oracle and/or its affiliates.Oracle is a registered trademark of Oracle Corporation and/or itsaffiliates. Other names may be trademarks of their respectiveowners.Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.StarRocks >StarRocks >StarRocks > SELECT version();+-----------+| version() |+-----------+| 5.1.0 |+-----------+1 row in set (0.10 sec)StarRocks >StarRocks > exitByeroot@startestdb01:~# tartestdb01:~# docker psCONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES2ecaa8cab9ef starrocks.docker.scarf.sh/starrocks/allin1-ubuntu "/bin/sh -c ./entryp…" 48 minutes ago Up 48 minutes 0.0.0.0:8030->8030/tcp, :::8030->8030/tcp, 0.0.0.0:8040->8040/tcp, :::8040->8040/tcp, 0.0.0.0:9030->9030/tcp, :::9030->9030/tcp gallant_tharp
--从docker容器tar打包starrocks安装包并复制到宿主机上

root@startestdb01:~# docker exec -it 2ecaa8cab9ef sh### pwd/data/deploy# lsbanner.txt entrypoint.sh starrocks# ls -lrttotal 2088-rw-rw-r-- 1 root root 10234 Feb 2 10:47 LICENSE.txt-rw-r--r-- 1 root root 2088768 Mar 11 12:19 NOTICE.txtdrwxr-xr-x 1 root root 4096 Mar 18 12:30 apache_hdfs_brokerdrwxrwxr-x 1 root root 4096 Mar 18 12:30 supervisordrwxrwxr-x 1 root root 4096 Mar 18 12:30 feproxydrwxr-xr-x 1 root root 4096 Mar 18 12:30 bedrwxr-xr-x 1 root root 4096 Mar 18 12:31 fedrwxrwxr-x 1 root root 4096 Mar 18 12:31 director## tar -zcvf starRocks.tar.gz starRocks/starRocks/starRocks/apache_hdfs_broker/starRocks/apache_hdfs_broker/log/starRocks/apache_hdfs_broker/log/apache_hdfs_broker.logstarRocks/apache_hdfs_broker/log/apache_hdfs_broker.outstarRocks/apache_hdfs_broker/lib/starRocks/apache_hdfs_broker/lib/okio-2.8.0.jarstarRocks/apache_hdfs_broker/lib/netty-codec-dns-4.1.89.Final.jarstarRocks/apache_hdfs_broker/lib/jersey-servlet-1.19.4.jarstarRocks/apache_hdfs_broker/lib/netty-all-4.1.89.Final.jarstarRocks/apache_hdfs_broker/lib/javax.servlet-api-3.1.0.jarstarRocks/apache_hdfs_broker/lib/netty-resolver-dns-4.1.89.Final.jarstarRocks/apache_hdfs_broker/lib/netty-codec-xml-4.1.89.Final.jarstarRocks/apache_hdfs_broker/lib/kerb-identity-1.0.1.jar... ...starRocks/fe/spark-dpp/spark-dpp-1.0.0-jar-with-dependencies.jarstarRocks/fe/bin/starRocks/fe/bin/build/starRocks/fe/bin/build/converter.jarstarRocks/fe/bin/build/async-profiler.jarstarRocks/fe/bin/build/fdtransferstarRocks/fe/bin/build/libasyncProfiler.sostarRocks/fe/bin/build/jattachstarRocks/fe/bin/profiler.shstarRocks/fe/bin/common.shstarRocks/fe/bin/show_fe_version.shstarRocks/fe/bin/stop_fe.shstarRocks/fe/bin/fe.pidstarRocks/fe/bin/start_fe.sh## pwd/data/deploy# lsbanner.txt entrypoint.sh starRocks starRocks.tar.gz starrocks# exitroot@startestdb01:~#root@startestdb01:~#root@startestdb01:~# docker cp 2ecaa8cab9ef:/data/deploy/starRocks.tar.gz /usr/local/Copying from container - 0B24.8MB50.1MB65.7MB73MB79.3MB82.8MB87.7MB91.8MB91.9MB94root@startestdb01:/usr/local# ls -lrttotal 3244788drwxr-xr-x 2 root root 4096 Apr 21 2022 srclrwxrwxrwx 1 root root 9 Apr 21 2022 man -> share/mandrwxr-xr-x 2 root root 4096 Apr 21 2022 includedrwxr-xr-x 2 root root 4096 Apr 21 2022 gamesdrwxr-xr-x 2 root root 4096 Apr 21 2022 etcdrwxr-xr-x 2 root root 4096 Apr 21 2022 bindrwxr-xr-x 2 root root 4096 Apr 21 2022 sbindrwxr-xr-x 3 root root 4096 Apr 21 2022 lib-rw-rw-r-- 1 root root 10234 Feb 2 18:47 LICENSE.txt-rw-r--r-- 1 root root 2088768 Mar 11 20:19 NOTICE.txtdrwxr-xr-x 7 root root 4096 Mar 18 17:17 sharedrwxr-xr-x 9 root root 4096 Mar 18 18:03 aegis-rw-r--r-- 1 root root 3320520221 Mar 18 22:14 starRocks.tar.gzroot@startestdb01:/usr/local#root@startestdb01:/usr/local#
文章转载自skylines,如果涉嫌侵权,请发送邮件至:contact@modb.pro进行举报,并提供相关证据,一经查实,墨天轮将立刻删除相关内容。




