CentOS 8 安装 Tableau Server 2022.3 指南

在 CentOS 8 从零安装 Tableau Server 2022.3:rpm 下载校验、initialize-tsm 引导、注册与本地身份存储配置、试用许可激活、初始化启动与 tabcmd 安装,附全程实测命令输出与常见报错修复。

TableauTableauBILinux2026/10/13

CentOS 8 安装 Tableau Server 2022.3 指南

目标:在 CentOS 8(x86_64)服务器上从零完成 Tableau Server 2022.3 的安装与启动,覆盖安装包下载与校验、rpm 安装、initialize-tsm 引导、产品注册与本地身份存储配置、试用许可激活、服务器初始化启动以及 tabcmd 命令行工具安装。全文命令与回显均在 CentOS 8(x86_64)实测通过。

一、环境信息与前置要求

  • 操作系统:CentOS 8(x86_64,最小化安装亦可,按第四章补齐前置)
  • Tableau Server:2022.3 系列最终维护版 2022.3.24(内部版本 20223.24.0423.1447)。官方下载链接按 2022.3.16 命名,实际交付 2022.3 线最后一个维护版本,属官方别名机制
  • 内存:官方最低要求 64 GB,安装程序有硬性校验(实测报错见 FAQ 11.3);本文测试环境 12 核 / 32 GB 内存,以 -f 参数跳过校验完成全流程验证,生产环境务必满足 64 GB
  • 磁盘:主程序安装约 10+ GB(/opt/tableau),另需为数据目录 /var/opt/tableau 预留 50 GB 以上
  • 端口:TSM 管理界面 8850(HTTPS);Tableau Server 网关 80(配置键 gateway.public.port 默认 80,实测确认)
  • 账户规划:安装以 root 执行;TSM 授权用户使用普通账户 tabadmin(TSM 禁止 root,见 FAQ 11.2);初始管理员账户 admin 在初始化完成后用 tabcmd 创建(见 8.2)
  • 示例主机名:tableau-01(输出中的 URL/主机名以实际服务器名为准)

二、获取安装包

2.1 在线下载(服务器可出外网)

Tableau 官方下载站点 downloads.tableau.com 前置 Akamai CDN,对 User-Agent 有拦截规则:curl 默认方式可直接下载;UA 为 Wget、浏览器 Mozilla 串或空值一律返回 403。因此使用 curl 且不加任何 UA 改写参数:

curl -O https://downloads.tableau.com/esdalt/2022.3.16/tableau-server-2022-3-16.x86_64.rpm

下载约 2.66 GiB(2,854,319,044 字节),耗时取决于带宽。完成后文件落位于当前目录:

ls -la /opt/tableau-server-2022-3-16.x86_64.rpm
-rw-r--r-- 1 root root 2854319044 Oct 12 15:11 /opt/tableau-server-2022-3-16.x86_64.rpm

2.2 SHA256 校验

sha256sum /opt/tableau-server-2022-3-16.x86_64.rpm
e2be0c30211f78a058692e9f38c58211155c8e596216abfe0caf18dc43b7241a  /opt/tableau-server-2022-3-16.x86_64.rpm

再确认 rpm 自身的版本信息,验证实际交付版本:

rpm -qp --qf "VER=%{VERSION} REL=%{RELEASE}\n" /opt/tableau-server-2022-3-16.x86_64.rpm
VER=20223 REL=24.0423.1447

2.3 离线导入(内网服务器)

在可联网机器上执行与 2.1 相同的 curl 下载,然后拷贝到内网服务器同一路径:

scp tableau-server-2022-3-16.x86_64.rpm root@192.168.1.10:/opt/

💡 说明:192.168.1.10 为示例内网服务器地址,请替换为实际目标机 IP。

三、安装主程序

使用 yum 安装本地 rpm,依赖会自动解析补装:

yum install -y /opt/tableau-server-2022-3-16.x86_64.rpm

输出节选(自动补装约 30 个依赖包,节选首尾):

Installed:
  tableau-server-20223.24.0423.1447-20223-24.0423.1447.x86_64

Dependencies Installed:
  libatomic_ops mesa-libEGL mesa-libGL net-tools nss python3-dbus which tzdata-java lua

Complete!

安装完成后确认 rpm 与目录结构:

rpm -qa | grep tableau
tableau-server-20223.24.0423.1447-20223-24.0423.1447.x86_64
ls /opt/tableau/tableau_server/
packages
  • 主程序安装目录:/opt/tableau/tableau_server/(各组件位于 packages/*.20223.24.0423.1447 子目录)
  • 数据目录(initialize-tsm 后创建):/var/opt/tableau/tableau_server

四、系统前置检查与修正

最小化安装的 CentOS 8 常缺以下三项,initialize-tsm 之前逐一检查修正,可避免第五章中途报错(各项对应的原始报错见 FAQ)。

4.1 补齐英文语言包

initialize-tsm 会校验 en_US.UTF-8 locale:

dnf install -y glibc-langpack-en
locale -a | grep en_US
en_US
en_US.iso88591
en_US.iso885915
en_US.utf8

4.2 补齐 file 命令

FNP 许可服务的安装脚本 install_fnp.sh 依赖 file 命令判断二进制位数,缺失会导致许可服务安装到错误目录(详见 FAQ 11.6):

dnf install -y file
file --version | head -1
file-5.33

4.3 检查 systemd-logind 状态

极简裁剪的系统中 systemd-logind 可能处于 masked 状态,initialize-tsm 启用用户 linger 时会中止:

systemctl is-enabled systemd-logind
static

若返回 masked,执行以下两条命令解除并启动(单独执行):

systemctl unmask systemd-logind
systemctl start systemd-logind

五、运行 initialize-tsm 引导 TSM

5.1 执行引导脚本

脚本位于 packages/scripts.<版本>/ 目录。创建 TSM 授权用户 tabadmin(密码 q1w2e3r4,示例环境统一口令):

useradd -m tabadmin
passwd tabadmin
Changing password for user tabadmin.
New password:
Retype new password:
passwd: all authentication tokens updated successfully.

执行 initialize-tsm。参数说明:--accepteula 接受 EULA(注意拼写,无中间连字符);-a tabadmin 指定 TSM 授权用户;-f 跳过最低内存校验(仅测试机使用,生产 64 GB 内存机器无需此参数)。若当前 shell 未加载英文 locale,需显式前缀:

LANG=en_US.UTF-8 LC_ALL=en_US.UTF-8 /opt/tableau/tableau_server/packages/scripts.20223.24.0423.1447/initialize-tsm --accepteula -a tabadmin -f

成功输出(实测全文):

Creating 'tsmadmin' group for TSM admin authorization
Creating 'tableau' unprivileged user account
Creating environment file...
Creating directories and setting permissions...
Using '/var/opt/tableau/tableau_server' as the data directory.
Adding user 'tabadmin' to group 'tableau'...
Adding user 'tabadmin' to group 'tsmadmin'...
Added. Note: These group membership changes do not take effect in shells already open. ...
Starting TSM services...
Updating repository version in Tableau Server Coordination Service.
TSM services started successfully
Use the 'tsm' command to continue setting up Tableau Server.
>> Tableau binary directory will be added to PATH for new shells. To get the
>> updated path, either start a new session, or for bash users run:
>> source /etc/profile.d/tableau_server.sh
The TSM administrative web interface (and REST API) is now available at
https://tableau-01:8850
You can continue the configuration and initialization of Tableau server using either the TSM command line interface,
or the web interface.
You will be prompted to authenticate, or can log in using the username 'tabadmin', with the same password you used to log into this session. ...
Done.

5.2 加载环境变量并验证

按提示重新加载环境脚本:

source /etc/profile.d/tableau_server.sh
tsm version
Tableau Services Manager command line version 20223.24.0423.1447.
Tableau Server version 20223.24.0423.1447.

5.3 登录 TSM

tsm login -u tabadmin -p q1w2e3r4

无输出即登录成功。此时服务器尚未初始化,状态为 STOPPED:

tsm status
Status: STOPPED

六、注册与身份存储配置

tsm initialize 有两项强制前置:产品注册、身份存储设置。任一缺失都会被拒绝(报错原文见 FAQ 11.9)。

6.1 产品注册

先生成注册模板:

tsm register --template > /opt/registration.json

模板包含 14 个字段:zip、country、city、last_name、industry、eula、title、company_employees、phone、company、state、opt_in、department、first_name、email。填写示例:

{
  "zip": "100000",
  "country": "China",
  "city": "Beijing",
  "last_name": "User",
  "industry": "Technology",
  "eula": true,
  "title": "Ops",
  "company_employees": "100",
  "phone": "010-00000000",
  "company": "Example Inc",
  "state": "Beijing",
  "opt_in": true,
  "department": "IT",
  "first_name": "Admin",
  "email": "admin@example.com"
}

提交注册:

tsm register --file /opt/registration.json
Registration complete.

6.2 设置本地身份存储

2022.3 的 tsm CLI 不提供 tsm user-identity-store set 子命令(仅有 set-connection/set-*-mappings/verify/list),本地身份存储需通过配置导入完成。创建身份存储定义文件:

cat > /opt/identity.json << 'EOF'
{
  "configEntities": {
    "identityStore": {
      "_type": "identityStoreType",
      "type": "local"
    }
  }
}
EOF

导入配置:

tsm settings import -f /opt/identity.json
Configuration file read from /opt/identity.json. The configuration file does not include the runas username and password. After importing, these values must be set explicitly.

查看待应用变更:

tsm pending-changes list
Key: wgserver.authenticate  New Value: local

应用变更(拓扑无变化,仅配置部署,约 1 分钟):

tsm pending-changes apply --ignore-prompt

进度节选(实测首尾):

Job id is '0', timeout is 30 minutes.
9% - Validating that there are no pending changes.
100% - Successfully deployed nodes with updated configuration and topology version.

验证身份存储类型:

tsm user-identity-store list
Type: local

七、激活许可(试用)

初始化前即可激活。生产环境使用正式产品密钥(tsm licenses activate -k <PRODUCT_KEY>),测试环境可激活 14 天试用:

tsm licenses activate -t
Trial activated.
tsm licenses list
Number of product keys: 1
KEY                       TYPE         CREATOR      EXPLORER     VIEWER       DATA MANAGEMENT           GUEST ACCESS LIC EXP      MAINT EXP    UPDATABLE    LBLM         ADVANCED MANAGEMENT
trial                     Term         25           0            0            true                      false        10/26/26     6/13/25      false        false        true

试用许可为 Term 类型,含 25 个 Creator 席位,有效期至 10/26/26。

八、初始化并启动 Tableau Server

8.1 执行初始化

-r(--start-server)参数表示初始化完成后立即启动服务器;--request-timeout 建议 7200 秒——初始化期间要生成全套 SSL 证书/密钥、跑数据库迁移、初始化活动仓库与索引服务,低配机器 30 分钟默认超时不够用(实测教训见 FAQ 11.8):

tsm initialize -r --request-timeout 7200

初始化为异步 Job,CLI 实时展示进度。实测完整进度(关键阶段):

2% - Checking control plane services.
4% - Validating that there are no pending changes.
7% - Removing services.
9% - Generating passwords.
12% - Generating secret keys.
14% - Generating apigateway mutual SSL certificates.
17% - Generating Apache Gateway Internal mutual SSL certificates.
19% - Generating Unique Cluster Identifier.
21% - Generating Search Server SSL certificate.
24% - Generating Index And Search Server SSL certificate.
26% - Generating ActiveMQ Server SSL certificate.
29% - Generating internal Metadata API mutual SSL certificates.
31% - Generating key store.
34% - Generating Hyper SSL certificate.
36% - Generating TSIG logs service SSL certificate.
39% - Promoting configuration.
41% - Waiting for services to reconfigure.
43% - Initializing the topology.
46% - Waiting for the maintenance app to start.
48% - Initializing the temporary database instance.
51% - Starting the temporary database instance.
53% - Creating roles and databases.
56% - Running migrations.
58% - Localizing the default projects.
60% - Stopping the temporary database instance.
63% - Making the temporary database default.
65% - Initializing the next active repository.
68% - Enabling services needed for server initialization.
70% - Connecting to the Backup/Restore service.
73% - Saving asset key metadata.
75% - Configuring search server.
78% - Connecting to the Backup/Restore service.
80% - Initializing Index And Search Server.
82% - Finalizing the topology.
85% - Connecting to Vizportal Maintenance.
87% - Rebuilding the search index.
100% - Finalizing the initialization.

Server was initialized successfully.

8.2 创建初始管理员

tsm initialize -r 完成后不会创建管理员账户(32 GB 内存机器整个流程约 40 分钟)。首次登录前需用 tabcmd 创建初始管理员:

tabcmd initialuser --server http://localhost -u admin -p q1w2e3r4
===== redirecting to http://localhost/auth
===== Signed out
===== Creating new session
=====     Server:   http://localhost
=====     Username: admin
===== Connecting to the server...
===== Signing in...
===== Succeeded

⚠️ 在创建初始管理员之前直接登录(Web 或 tabcmd)都会报 Invalid username or password. (errorCode=16),属预期现象。此时也不要执行 tsm reset——它只用于"已有初始管理员需要重建"的场景,无初始用户时执行会报 TApplicationException 失败。

8.3 验证服务状态

tsm status -v
node1: localhost
        Status: RUNNING
        'Tableau Server Gateway 0' is running.
        'Tableau Server Application Server 0' is running.
        'Tableau Server Interactive Microservice Container 0' is running.
                'MessageBus Microservice 0' is running.
                'Relationship Query Microservice 0' is running.
                'Credentials Service 0' is running.
        'Tableau Server VizQL Server 0' is running.
        'Tableau Server Cache Server 0' is running.
        'Tableau Server Coordination Service 0' is running.
        'Tableau Server Cluster Controller 0' is running.
        'Tableau Server Search And Browse 0' is running.
        'Tableau Server Backgrounder 0' is running.
        'Tableau Server Non-Interactive Microservice Container 0' is running.
        'Tableau Server Data Server 0' is running.
        'Tableau Server Data Engine 0' is running.
        'Tableau Server File Store 0' is running.
        'Tableau Server Repository 0' is running (Active Repository).
        'Tableau Server Tableau Prep Conductor 0' is running.
        'Tableau Server Tableau Prep Flow Authoring 0' is running.
        'Tableau Server Tableau Prep Minerva Service 0' is running.
        'Tableau Server Index And Search Server 0' is running.
        'Tableau Server Ask Data 0' is running.
        'Tableau Server Administration Agent 0' is running.
        'Tableau Server Administration Controller 0' is running.
        'Tableau Server License Manager 0' is running.
        'Tableau Server Activation Service 0' is running.
        'Tableau Server Client File Service 0' is running.
        'Tableau Server Database Maintenance 0' is stopped.
        'Tableau Server Backup/Restore 0' is stopped.
        'Tableau Server Site Import/Export 0' is stopped.
        'Tableau Server SAML Service 0' is stopped.
        'Tableau Server Collections Service 0' is running.
        'Tableau Server Content Exploration Service 0' is running.
        'Tableau Server Webhooks 0' is running.
        'Tableau Server Authentication 0' is running.
        'Tableau Server API Gateway 0' is running.
        'Tableau Server Analytics Extensions Microservice 0' is running.
        'Tableau Server Messaging Service 0' is running.
        'Tableau Server Data Source Properties Service 0' is running.
        'Tableau Server Internal Data Source Properties Service 0' is running.
        'Tableau Server Virtual Connections Service 0' is running.
        'Tableau Server Metrics Service 0' is running.
        'Tableau Server Query Gateway Service 0' is running.
        'Tableau Server Query Policy Service 0' is running.
        'Tableau Server Tableau Minerva Service 0' is running.
        'Tableau Server Extract Service 0' is running.
        'Tableau Server Data Profiling Service 0' is running.
        'Tableau Server Resource Limits Manager 0' is running.
        'Tableau Server Tableau Statistical Service 0' is running.

💡 Database Maintenance、Backup/Restore、Site Import/Export、SAML Service 四个服务显示 stopped 属正常——它们是按需启停的服务,仅在备份/恢复/站点导入导出时运行。

九、安装 tabcmd

tabcmd 是独立于主程序的命令行内容管理工具,同样提供 rpm 包:

curl -O https://downloads.tableau.com/esdalt/2022.3.16/tableau-tabcmd-2022-3-16.noarch.rpm
sha256sum /opt/tableau-tabcmd-2022-3-16.noarch.rpm
f63f80886eec0cbee91549dcba238e0bf4c164e38996ba1ad95dad9a27dd700f  /opt/tableau-tabcmd-2022-3-16.noarch.rpm
yum install -y /opt/tableau-tabcmd-2022-3-16.noarch.rpm

安装位置为 /opt/tableau/tabcmd/。tabcmd 首次执行必须先接受 EULA(--accepteula):

tabcmd --accepteula version
Tableau Server Command Line Utility -- 20223.24.0423.1447

💡 tabcmd 的完整命令体系与登录实测见《Tableau Server 2022.3 tsm 与 tabcmd 命令详解》。

十、安装验证

逐项确认:

tsm version
Tableau Services Manager command line version 20223.24.0423.1447.
Tableau Server version 20223.24.0423.1447.
curl -s -o /dev/null -w "%{http_code}" http://localhost/
200
curl -sk -o /dev/null -w "%{http_code}" https://localhost:8850/
200

浏览器访问 http://<服务器IP>/,以初始管理员 admin 登录即可进入 Tableau Server Web 控制台;访问 https://<服务器IP>:8850/ 可进入 TSM 管理界面(使用 tabadmin 登录)。

十一、常见问题

11.1 initialize-tsm 报 Unknown or malformed command line option

EULA 参数拼写错误所致。正确拼写是 --accepteula(一个连字符、无中间分隔),误写成 --accept-eula 会直接报错:

Unknown or malformed command line option '--accept-eula'

11.2 TSM does not allow root as a TSM-authorized user

TSM 禁止 root 作为授权用户:

TSM does not allow root as a TSM-authorized user

解决:创建普通用户并在 initialize-tsm 用 -a <用户名> 指定,或以普通用户配合 sudo 执行。

11.3 内存不足 64 GB 硬校验失败

Tableau Server requires at least 64 GB memory to run, but found only 32 GB

生产环境应扩容至 64 GB 以上;测试环境可在 initialize-tsm 追加 -f 跳过校验。32 GB 内存机器虽能完成初始化,但应用服务(Application Server/Backgrounder/Data Server 等)在默认进程配置下内存压力大,初始化耗时长且个别服务易进入 Error 状态。

11.4 Locale 'en_US.UTF-8' is not found on your system

缺少英文语言包:

dnf install -y glibc-langpack-en

或执行 initialize-tsm 时加 LANG=en_US.UTF-8 LC_ALL=en_US.UTF-8 前缀(二者配合使用最稳妥)。

11.5 Could not enable linger: Unit systemd-logind.service is masked

裁剪系统的 systemd-logind 被禁用导致 initialize-tsm 中止:

systemctl unmask systemd-logind
systemctl start systemd-logind

11.6 FNPLicensingService 启动失败 status=203/EXEC

initialize-tsm 完成后,tsm status -v 中 fnplicenseservice_0.service 反复启动失败,journalctl 显示 status=203/EXEC。根因:系统缺 file 命令时,许可服务安装脚本 install_fnp.sh 的 file ${service} | grep "ELF 64" 判定失败,把 FNPLicensingService 误装到 32 位路径 /usr/local/share/FNP/service/11.19.2/,而 unit 文件要求 service64/11.19.2/。

修复三步(单独执行):

dnf install -y file
cd /opt/tableau/tableau_server/packages/bin.20223.24.0423.1447
./install_fnp.sh ./FNPLicensingService

修复后确认二进制落位 64 位目录(权限 4755 setuid root),再重跑 initialize-tsm:

ls -la /usr/local/share/FNP/service64/11.19.2/FNPLicensingService
-rwsr-xr-x 1 root root 1320264 FNPLicensingService

11.7 Unable to determine what username is running this script

非登录 shell 环境无法推断当前用户名所致。解决:改用可登录的 shell 会话,或显式加 -a tabadmin 指定 TSM 授权用户。

11.8 tsm initialize 超时失败后如何重跑

默认请求超时 1800 秒对低配机器太短,实测在 "Initializing Index And Search Server" 阶段超时:

Server initialization was unsuccessful. This job timed out after '1800' seconds.

此时 tsm status -v 呈 DEGRADED(多数服务 running、个别应用服务 Error)。直接以更长超时重跑即可,服务端会清理上一次未完成的 InitializeServerJob:

tsm initialize -r --request-timeout 7200

重跑开始时的提示:

The previous InitializeServerJob did not succeed after running for 30 minute(s).
Job id is '2', timeout is 120 minutes.

重跑会重复证书生成/服务清理/仓库初始化全流程,耐心等待至 100% 即可;若仍失败,优先核查内存与 swap(free -g),必要时扩容内存后重试。

11.9 initialize 被拒绝:必须先注册并设置身份存储

Invalid Initialization Request: The server must be registered before initialization.
Invalid Initialization Request: The identity store must be set before initialization.

按第六章顺序先完成 tsm register 与 tsm settings import(identityStore)再执行初始化。

11.10 tabcmd 登录报 Invalid username or password (errorCode=16)

初始化完成后服务器还没有管理员账户(tsm initialize -r 不创建管理员),先执行:

tabcmd initialuser --server http://localhost -u admin -p q1w2e3r4

创建完成后再登录。若误在无初始用户状态下执行了 tsm reset,会以 TApplicationException 失败——reset 仅用于重建已有初始管理员的场景,此时跳过 reset 直接 initialuser 即可。

十二、参考链接

  1. Tableau Server 官方安装指南(TSM):https://help.tableau.com/current/server-linux/en-us/install_and_admin.htm
  2. TSM 命令行参考:https://help.tableau.com/current/server-linux/en-us/tsm.htm
  3. tabcmd 命令行参考:https://help.tableau.com/current/server-linux/en-us/tabcmd_cmd.htm
  4. Tableau 产品下载站:https://www.tableau.com/support/releases