查看存储桶的列表时候报错
我的 Linux 服务器是 Centos07
我的 minio 版本是
minio -version
minio version RELEASE.2023-06-02T23-17-26Z (commit-id=0649aca2195a8d3aef9b946337b4ca6581e23844)
Runtime: go1.19.9 linux/amd64
License: GNU AGPLv3 https://www. gnu.org/licenses/agpl-3.0.html
版权所有:2015-2023 MinIO, Inc.
nginx的配置文件
location / {
proxy_set_header Host $http_host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_connect_timeout 300;
# Default is HTTP/1, keepalive is only enabled in HTTP/1.1
proxy_http_version 1.1;
proxy_set_header Connection "";
chunked_transfer_encoding off;
proxy_pass http://192.168.0.4:9000/; # This uses the upstream directive definitio
n to load balance
}
location / {
proxy_set_header Host $http_host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_set_header X-NginX-Proxy true;
# This is necessary to pass the correct IP to be hashed
real_ip_header X-Real-IP;
proxy_connect_timeout 300;
# To support websocket
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
chunked_transfer_encoding off;
proxy_pass http://192.168.0.4:9100/; # This uses the upstream directive definitio
n to load balance and assumes a static Console port of 9001
}
可以查看桶的列表信息
WebSockets的配置在好好检查下
答案参考Chatgpt Plus
检查权限:确保您具有适当的权限来访问存储桶和其中的对象。您可能需要检查您的访问密钥、IAM角色或存储桶策略,以确保您具有必要的权限。 检查WebSockets配置:如果您的应用程序使用了WebSockets,确保您的WebSockets配置正确。WebSockets是一种用于实现双向通信的协议,但在某些情况下,错误的配置可能会导致问题。请参考相关文档或咨询您的云服务提供商以获取正确的配置信息。 检查网络连接:确保您的网络连接正常工作,并且您可以访问存储桶所在的云服务。检查防火墙设置、网络代理或其他网络配置,确保它们不会阻止对存储桶的访问。
根据提供的信息,您在查看存储桶列表时遇到了报错信息 "Objects List unavailable. Please review your WebSockets configuration and try again"。这个错误可能是由于MinIO服务器的WebSockets配置问题导致的。
您提供的Nginx配置文件显示了代理设置,其中包括对WebSockets的支持。您可以检查以下几点来解决此问题:
proxy_http_version
应设置为1.1,而且 Upgrade
和 Connection
头信息应正确传递。通过仔细检查和调试这些方面,您应该能够解决报错信息 "Objects List unavailable. Please review your WebSockets configuration and try again",并能够成功查看存储桶列表。