Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Nacos 2.4.2] docker 版本启动初始化密码登录之后,创建命名空间后看不到并且报错 #13066

Closed
chenzfp opened this issue Jan 23, 2025 · 1 comment
Labels
status/duplicate This issue or pull request already exists

Comments

@chenzfp
Copy link

chenzfp commented Jan 23, 2025

Describe the bug
docker版本nacos-server:v2.4.2启动初始化密码登录之后,创建命名空间后看不到并且报错,如下docker-compose.yaml配置文件,测试了nacos-server:v2.4.1和nacos-server:v2.4.0无此问题

How to Reproduce
Steps to reproduce the behavior:
使用如下docker-compose.yaml 启动服务,然后访问IP:8848/nacos/#/register 初始化密码登录之后,创建namespace

services:
  nacos:
    image: nacos/nacos-server:v2.4.2
    container_name: nacos
    environment:
      - PREFER_HOST_MODE=hostname
      - MODE=standalone
      - JVM_XMX=512m
      - JVM_XMS=512m
      - TOMCAT_ACCESSLOG_ENABLED=false
      - TZ=Asia/Shanghai
      - management.endpoints.enabled-by-default=false
      - nacos.core.auth.enabled=true
      - nacos.core.auth.plugin.nacos.token.secret.key=R169YPpZoShPDiEweA1cClu92rK+AcTpEsJW97obikM=
      - nacos.core.auth.server.identity.key=nacos2025
      - nacos.core.auth.server.identity.value=nacos2025
      - nacos.core.auth.enable.userAgentAuthWhite=false
    volumes:
      # 挂载nacos数据持久化文件
      - ./data:/home/nacos/data
      #- ./logs/nacos:/home/nacos/logs
    ports:
      - 8848:8848
      - 9848:9848
      - 9849:9849
    restart: always
    logging:
      driver: "json-file"
      options:
        max-size: "500m"
        max-file: "3"

创建namespace后不能查询到,且默认public namespace也不能查询到

Image

查询不到namespace数据,但是再次创建的时候报错提示namespace已存在

Image

以为是权限问题,尝试在 权限控制->权限管理中添加权限,发现报错异常,不能正常添加

Image
权限管理页面报错信息如下:

caused: PreparedStatementCallback; bad SQL grammar [SELECT id,quota,`usage`,`max_size`,max_aggr_count,max_aggr_size,tenant_id FROM tenant_capacity WHERE tenant_id = ?]; nested exception is java.sql.SQLSyntaxErrorException: Lexical error at line 1, column 17. Encountered: "`" (96), after : "".;caused: Lexical error at line 1, column 17. Encountered: "`" (96), after : "".;caused: Lexical error at line 1, column 17. Encountered: "`" (96), after : "".;

Desktop (please complete the following information):

  • OS: [Debian]
  • Version [nacos-server 2.4.2]
  • Module [namespace/config]

Additional context
测试了nacos-server:v2.4.1和nacos-server:v2.4.0无此问题,正常截图如下
Image

@KomachiSion
Copy link
Collaborator

KomachiSion commented Jan 24, 2025

升级到2.4.2.1及以上版本

@KomachiSion KomachiSion reopened this Jan 24, 2025
@KomachiSion KomachiSion reopened this Jan 24, 2025
@KomachiSion KomachiSion added the status/duplicate This issue or pull request already exists label Jan 24, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status/duplicate This issue or pull request already exists
Projects
None yet
Development

No branches or pull requests

2 participants