Err:10 https://packages.fluentbit.io/ubuntu/jammy jammy InRelease,onlyoffice协作空间报错
原文地址:https://openobserve.ai/blog/setup-fluent-bit-on-ubuntu-for-efficient-log-forwarding。6.配置 Fluent Bit 发送日志到 OpenObserve 默认配置文件位于:/etc/fluent-bit/fluent-bit.conf,可以使用 vim 编辑该文件。如果有任何错误,您可以使用以下命令检查它们
互联网通不通
wqbboy@onlyofficed:~$ ping www.163.com
PING www.163.com.w.kunluncan.com (120.202.140.229) 56(84) bytes of data.
login as: wqbboy
wqbboy@192.168.43.29's password:
Welcome to Ubuntu 22.04.5 LTS (GNU/Linux 5.15.0-153-generic x86_64)
* Documentation: https://help.ubuntu.com
* Management: https://landscape.canonical.com
* Support: https://ubuntu.com/pro
System information as of Wed Sep 17 01:49:02 AM UTC 2025
System load: 0.1 Processes: 163
Usage of /: 15.4% of 97.87GB Users logged in: 0
Memory usage: 25% IPv4 address for enp0s3: 192.168.43.29
Swap usage: 0%
Expanded Security Maintenance for Applications is not enabled.
59 updates can be applied immediately.
1 of these updates is a standard security update.
To see these additional updates run: apt list --upgradable
14 additional security updates can be applied with ESM Apps.
Learn more about enabling ESM Apps service at https://ubuntu.com/esm
Last login: Wed Sep 17 01:49:03 2025
wqbboy@onlyofficed:~$ cd /opt/
wqbboy@onlyofficed:/opt$ ls
docspace-install.sh
OneClickinstall-Debian_20250912_091602.log
OneClickinstall-Debian_20250912_092439.log
OneClickinstall-Debian_20250912_104410.log
OneClickinstall-Debian_20250915_023706.log
OneClickinstall-Debian_20250915_030437.log
OneClickinstall-Debian_20250915_033527.log
OneClickinstall-Debian_20250915_033808.log
OneClickinstall-Debian_20250915_092442.log
执行安装bash docspace-install.sh package
wqbboy@onlyofficed:/opt$ bash docspace-install.sh package
To perform this action you must be logged in with root rights
wqbboy@onlyofficed:/opt$ sudo bash docspace-install.sh package
[sudo] password for wqbboy:
Hit:2 http://openresty.org/package/ubuntu jammy InRelease
Hit:5 http://repo.mysql.com/apt/ubuntu jammy InRelease
Hit:6 http://download.onlyoffice.com/repo/debian squeeze InRelease
Hit:1 http://mirrors.tuna.tsinghua.edu.cn/ubuntu jammy InRelease
Hit:3 http://mirrors.tuna.tsinghua.edu.cn/ubuntu jammy-updates InRelease
Hit:4 http://mirrors.tuna.tsinghua.edu.cn/ubuntu jammy-backports InRelease
Hit:7 http://security.ubuntu.com/ubuntu jammy-security InRelease
Hit:8 https://deb.nodesource.com/node_18.x nodistro InRelease
Hit:9 https://ppa.launchpadcontent.net/dotnet/backports/ubuntu jammy InRelease
Get:10 https://packages.fluentbit.io/ubuntu/jammy jammy InRelease [7,564 B]
Hit:11 https://packages.redis.io/deb jammy InRelease
Err:10 https://packages.fluentbit.io/ubuntu/jammy jammy InRelease
The following signatures couldn't be verified because the public key is not av ailable: NO_PUBKEY 9F9DDC083888C1CD
Hit:12 https://artifacts.opensearch.org/releases/bundle/opensearch/2.x/apt stabl e InRelease
Hit:13 https://artifacts.opensearch.org/releases/bundle/opensearch-dashboards/2. x/apt stable InRelease
Get:14 https://packages.adoptium.net/artifactory/deb jammy InRelease [7,501 B]
Reading package lists... Done
W: GPG error: https://packages.fluentbit.io/ubuntu/jammy jammy InRelease: The fo llowing signatures couldn't be verified because the public key is not available: NO_PUBKEY 9F9DDC083888C1CD
E: The repository 'https://packages.fluentbit.io/ubuntu/jammy jammy InRelease' i s not signed.
N: Updating from such a repository can't be done securely, and is therefore disa bled by default.
N: See apt-secure(8) manpage for repository creation and user configuration deta ils.
An error occurred while executing the script. Log saved to: OneClickinstall-Debi an_20250917_014948.log
报错**“Err:10 https://packages.fluentbit.io/ubuntu/jammy jammy InRelease
The following signatures couldn’t be verified because the public key is not av ailable: NO_PUBKEY 9F9DDC083888C1CD**”
1、设置服务器GPG密钥
wqbboy@onlyofficed:/opt$ sudo sh -c 'curl https://packages.fluentbit.io/fluentbit.key | gpg --dearmor > /usr/share/keyrings/fluentbit-keyring.gpg'
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 3175 100 3175 0 0 4818 0 --:--:-- --:--:-- --:--:-- 4817
2.导出您的 ubuntu 版本名称
在 Ubuntu 上,您需要将 APT 服务器条目添加到源列表中,请在 /etc/apt/sources.list 文件底部添加以下内容 - 确保将 CODENAME 设置为您的特定 Ubuntu 版本名称(例如 Ubuntu 22.04.2 的 jammy):
首先使用如下命令获取 release name:
wqbboy@onlyofficed:/opt$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 22.04.5 LTS
Release: 22.04
Codename: jammy
或者执行如下命令:
wqbboy@onlyofficed:/opt$ cat /etc/os-release
PRETTY_NAME="Ubuntu 22.04.5 LTS"
NAME="Ubuntu"
VERSION_ID="22.04"
VERSION="22.04.5 LTS (Jammy Jellyfish)"
VERSION_CODENAME=jammy
ID=ubuntu
ID_LIKE=debian
HOME_URL="https://www.ubuntu.com/"
SUPPORT_URL="https://help.ubuntu.com/"
BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/"
PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"
UBUNTU_CODENAME=jammy
让我们将其导出到环境变量中:
wqbboy@onlyofficed:/opt$ export CODENAME="jammy"
3、更新 sources lists
wqbboy@onlyofficed:/opt$ echo "deb [signed-by=/usr/share/keyrings/fluentbit-keyring.gpg] https://packages.fluentbit.io/ubuntu/$CODENAME/ \
$CODENAME main" | sudo tee /etc/apt/sources.list.d/fluentbit.list
输出:
deb [signed-by=/usr/share/keyrings/fluentbit-keyring.gpg] https://packages.fluentbit.io/ubuntu/jammy/ jammy main
安装 Fluent Bit
wqbboy@onlyofficed:/opt$ sudo apt-get update
Hit:2 http://repo.mysql.com/apt/ubuntu jammy InRelease
Hit:1 http://mirrors.tuna.tsinghua.edu.cn/ubuntu jammy InRelease
Hit:5 http://openresty.org/package/ubuntu jammy InRelease
Hit:3 http://mirrors.tuna.tsinghua.edu.cn/ubuntu jammy-updates InRelease
Hit:4 http://mirrors.tuna.tsinghua.edu.cn/ubuntu jammy-backports InRelease
Hit:6 http://download.onlyoffice.com/repo/debian squeeze InRelease
Hit:7 http://security.ubuntu.com/ubuntu jammy-security InRelease
Hit:8 https://packages.redis.io/deb jammy InRelease
Hit:9 https://deb.nodesource.com/node_18.x nodistro InRelease
Hit:10 https://ppa.launchpadcontent.net/dotnet/backports/ubuntu jammy InRelease
Get:11 https://packages.fluentbit.io/ubuntu/jammy jammy InRelease [7,564 B]
Get:12 https://packages.fluentbit.io/ubuntu/jammy jammy/main amd64 Packages [35.8 kB]
Hit:13 https://artifacts.opensearch.org/releases/bundle/opensearch/2.x/apt stable InRelease
Hit:14 https://artifacts.opensearch.org/releases/bundle/opensearch-dashboards/2.x/apt stable InRelease
Get:15 https://packages.adoptium.net/artifactory/deb jammy InRelease [7,501 B]
Fetched 50.9 kB in 3s (15.6 kB/s)
Reading package lists... Done
W: Target Packages (main/binary-amd64/Packages) is configured multiple times in /etc/apt/sources.list.d/fluent-bit.list:1 and /etc/apt/sources.list.d/fluentbit.list:1
W: Target Packages (main/binary-all/Packages) is configured multiple times in /etc/apt/sources.list.d/fluent-bit.list:1 and /etc/apt/sources.list.d/fluentbit.list:1
W: Target Translations (main/i18n/Translation-en_US) is configured multiple times in /etc/apt/sources.list.d/fluent-bit.list:1 and /etc/apt/sources.list.d/fluentbit.list:1
W: Target Translations (main/i18n/Translation-en) is configured multiple times in /etc/apt/sources.list.d/fluent-bit.list:1 and /etc/apt/sources.list.d/fluentbit.list:1
W: Target CNF (main/cnf/Commands-amd64) is configured multiple times in /etc/apt/sources.list.d/fluent-bit.list:1 and /etc/apt/sources.list.d/fluentbit.list:1
W: Target CNF (main/cnf/Commands-all) is configured multiple times in /etc/apt/sources.list.d/fluent-bit.list:1 and /etc/apt/sources.list.d/fluentbit.list:1
W: Target Packages (main/binary-amd64/Packages) is configured multiple times in /etc/apt/sources.list.d/fluent-bit.list:1 and /etc/apt/sources.list.d/fluentbit.list:1
W: Target Packages (main/binary-all/Packages) is configured multiple times in /etc/apt/sources.list.d/fluent-bit.list:1 and /etc/apt/sources.list.d/fluentbit.list:1
W: Target Translations (main/i18n/Translation-en_US) is configured multiple times in /etc/apt/sources.list.d/fluent-bit.list:1 and /etc/apt/sources.list.d/fluentbit.list:1
W: Target Translations (main/i18n/Translation-en) is configured multiple times in /etc/apt/sources.list.d/fluent-bit.list:1 and /etc/apt/sources.list.d/fluentbit.list:1
W: Target CNF (main/cnf/Commands-amd64) is configured multiple times in /etc/apt/sources.list.d/fluent-bit.list:1 and /etc/apt/sources.list.d/fluentbit.list:1
W: Target CNF (main/cnf/Commands-all) is configured multiple times in /etc/apt/sources.list.d/fluent-bit.list:1 and /etc/apt/sources.list.d/fluentbit.list:1
wqbboy@onlyofficed:/opt$
4.安装 Fluent Bit
sudo apt-get install fluent-bit
使用 systemd 启动 Fluent Bit
# Start Fluent Bit
sudo systemctl start fluent-bit
# Enable Fluent Bit to start on boot
sudo systemctl enable fluent-bit
# Check the status of Fluent Bit
sudo systemctl status fluent-bit
6.配置 Fluent Bit 发送日志到 OpenObserve 默认配置文件位于:/etc/fluent-bit/fluent-bit.conf,可以使用 vim 编辑该文件。我们来采集 /var/log 下面的日志,在 fluent-bit.conf 文件中添加如下配置:
[INPUT]
Name tail
Path /var/log/*.log
Parser docker
Tag logs.*
Refresh_Interval 5
Rotate_Wait 5
Mem_Buf_Limit 5MB
Skip_Long_Lines On
配置完了 INPUT 部分,我们来配置 OUTPUT 部分,将日志发送到 OpenObserve:
[OUTPUT]
Name http
Match *
URI /api/justprabhat_organization_1010/default/_json
Host api.openobserve.ai
Port 443
tls On
Format json
Json_date_key _timestamp
Json_date_format iso8601
HTTP_User youremail@yourdomain.com
HTTP_Passwd qatj1wfZ890Q5Sk123k1
compress gzip
OpenObserve 是一个日志监控平台,该产品相对较新,主张把日志存储在 S3 上,类似 Loki,所以成本更低,当然,带来的问题是检索能力不如 ElasticSearch。本文来自 OpenObserve 的作者:Prabhat Sharma,所以有这么一个章节讲解 Fluentbit 推送日志给 OpenObserve。Fluent Bit 在日志采集领域使用广泛,可以转发到 Logstash、Fluentd、ElasticSearch、Kafka 等多种后端。原文地址:https://openobserve.ai/blog/setup-fluent-bit-on-ubuntu-for-efficient-log-forwarding
配置完了 fluent-bit.conf 文件后,重启 Fluent Bit 服务:
sudo systemctl restart fluent-bit
使用以下命令检查服务的状态:
sudo systemctl status fluent-bit
如果有任何错误,您可以使用以下命令检查它们: journalctl -u fluent-bit.service
pgsql启动后执行psql显示报错:
psql: error: connection to server on socket "/var/run/postgresql/.s.PGSQL.5432" failed: No such file or directory
Is the server running locally and accepting connections on that socket?
只需要添加一条软连接:
ln -s /tmp/.s.PGSQL.5432 /var/run/postgresql/.s.PGSQL.5432
更多推荐

所有评论(0)