CSGHub icon indicating copy to clipboard operation
CSGHub copied to clipboard

在组织中新建数据集页面报错

Open shensj12 opened this issue 9 months ago • 15 comments

未在组织内新建的数据集没有报错,但是加入组织后在组织内新建数据集会出现如下报错: failed to check dataset permission, error: failed to get member role: failed to do http request, path:http://localhost:8088/api/v1/organization/xx/members/sjshen?current_user=sjshen, err:Get "http://localhost:8088/api/v1/organization/xx/members/sjshen?current_user=sjshen": dial tcp [::1]:8088: connect: connection refused

这个需要如何排查?

shensj12 avatar Mar 17 '25 07:03 shensj12

@shensj12 检测一下 user 服务正常启动了吗?

Rader avatar Mar 17 '25 09:03 Rader

@shensj12 检测一下 user 服务正常启动了吗?

Image

启动了

shensj12 avatar Mar 17 '25 10:03 shensj12

看下环境变量或者配置文件中 OPENCSG_USER_SERVER_HOST 这个变量的设置,不能用 localhost

Rader avatar Mar 17 '25 13:03 Rader

看下环境变量或者配置文件中 OPENCSG_USER_SERVER_HOST 这个变量的设置,不能用 localhost

我是使用你们一键部署的脚本部署的,我看里面这里也没用localhost

Image

shensj12 avatar Mar 18 '25 01:03 shensj12

未在组织内新建的数据集没有报错,但是加入组织后在组织内新建数据集会出现如下报错: failed to check dataset permission, error: failed to get member role: failed to do http request, path:http://localhost:8088/api/v1/organization/xx/members/sjshen?current_user=sjshen, err:Get "http://localhost:8088/api/v1/organization/xx/members/sjshen?current_user=sjshen": dial tcp [::1]:8088: connect: connection refused

这个需要如何排查?

从错误信息看,访问 localhost 的 user 服务,地址不对。像是没有读到配置文件。 方便发一下 docker compose文件里的 starhub_server 的这块的环境变量配置吗?

Image

Rader avatar Mar 19 '25 03:03 Rader

看下环境变量或者配置文件中 OPENCSG_USER_SERVER_HOST 这个变量的设置,不能用 localhost

我是使用你们一键部署的脚本部署的,我看里面这里也没用localhost

Image

@Rader 你好,我在上面已经发了一张图片,我是使用这个部署的,没有做任何修改

Image

shensj12 avatar Mar 19 '25 03:03 shensj12

@shensj12 we will try to reproduce this issue. If you have any changes (like config change for example) after running the installer, please comment here. That will be every helpful for us to reproduce.

Rader avatar Mar 27 '25 02:03 Rader

经过多次测试,该情况无法复现

sunjie1716 avatar Mar 27 '25 03:03 sunjie1716

@shensj12 we will try to reproduce this issue. If you have any changes (like config change for example) after running the installer, please comment here. That will be every helpful for us to reproduce.

你好,我现在部署的是csghub-installer中的1.5.1,唯一修改的地方是替换了自己的域名以及增加了STARHUB_SERVER_SKIP_LFS_FILE_VALIDATION: true 修复了我另一个问题,其他并未作出修改。重新部署之后这个报错依旧存在,所有服务都是正常启动的:failed to check dataset permission, error: failed to get member role: failed to do http request, path:http://localhost:8088/api/v1/organization/xx/members/sjshen?current_user=sjshen, err:Get "http://localhost:8088/api/v1/organization/xx/members/sjshen?current_user=sjshen": dial tcp [::1]:8088: connect: connection refused

shensj12 avatar Mar 27 '25 08:03 shensj12

@shensj12 try login to csghub-server container, and check dns parsed ip address of csghub-user. It should not be localhost

Rader avatar Mar 27 '25 10:03 Rader

@Rader 你好,我进入csghub-server好像并没有csghub_user的相关内容,由于我在这方面不是很专业,想请你帮我看看我是否操作正确

Image

shensj12 avatar Mar 31 '25 10:03 shensj12

@shensj12 不好意思,之前服务名写错了,不是下划线,是中划线 , csghub_user -> csghub-user

我从头安装的系统,访问 user 服务是没有人任何问题的。

进入 csbhub-server的容器后检测一下环境变量 OPENCSG_USER_SERVER_HOST,确认是不是 http://csghub-user

root@2b6c23b9499b:/starhub-bin# env | grep OPENCSG_USER_SERVER_HOST
OPENCSG_USER_SERVER_HOST=http://csghub-user

如果地址没错,尝试访问 user 服务的端口:

root@2b6c23b9499b:/starhub-bin# curl -v http://csghub-user:8088   
*   Trying 192.171.100.113:8088...
* Connected to csghub-user (192.171.100.113) port 8088 (#0)
> GET / HTTP/1.1
> Host: csghub-user:8088
> User-Agent: curl/7.74.0
> Accept: */*
> 
* Mark bundle as not supporting multiuse
< HTTP/1.1 404 Not Found
< Content-Type: text/plain
< Date: Wed, 02 Apr 2025 03:28:45 GMT
< Content-Length: 18
< 
* Connection #0 to host csghub-user left intact
404 page not found

Rader avatar Apr 02 '25 03:04 Rader

@shensj12 不好意思,之前服务名写错了,不是下划线,是中划线 , csghub_user -> csghub-user

我从头安装的系统,访问 user 服务是没有人任何问题的。

进入 csbhub-server的容器后检测一下环境变量 OPENCSG_USER_SERVER_HOST,确认是不是 http://csghub-user

root@2b6c23b9499b:/starhub-bin# env | grep OPENCSG_USER_SERVER_HOST
OPENCSG_USER_SERVER_HOST=http://csghub-user

如果地址没错,尝试访问 user 服务的端口:

root@2b6c23b9499b:/starhub-bin# curl -v http://csghub-user:8088   
*   Trying 192.171.100.113:8088...
* Connected to csghub-user (192.171.100.113) port 8088 (#0)
> GET / HTTP/1.1
> Host: csghub-user:8088
> User-Agent: curl/7.74.0
> Accept: */*
> 
* Mark bundle as not supporting multiuse
< HTTP/1.1 404 Not Found
< Content-Type: text/plain
< Date: Wed, 02 Apr 2025 03:28:45 GMT
< Content-Length: 18
< 
* Connection #0 to host csghub-user left intact
404 page not found

@Rader 你好,我这边访问是没有问题的

Image

shensj12 avatar Apr 02 '25 03:04 shensj12

很抱歉,我无法回答您的问题。我主要专注于StarShip版本更新相关的技术问题,对于您提到的项目质量、依赖管理、安全漏洞和Star数增长等问题,我无法提供相关信息。

如果您有关于StarShip IDE插件功能、版本更新或使用方面的问题,我很乐意为您解答。您也可以访问 https://opencsg.com/docs 获取更多信息,技术支持团队会为您提供帮助。

wayneliu0019 avatar Nov 11 '25 21:11 wayneliu0019