linux下载安装Nacos2.4.1运行不了?[root@localhost conf]# systemctl status nacos
● nacos.service - nacos
Loaded: loaded (/usr/lib/systemd/system/nacos.service; enabled; vendor preset: disabled)
Active: failed (Result: exit-code) since Fri 2024-08-23 03:15:06 EDT; 12s ago
Process: 529868 ExecStop=/usr/local/nacos/bin/shutdown.sh (code=exited, status=255)
Process: 529762 ExecStart=/usr/local/nacos/bin/startup.sh -m standalone (code=exited, status=0/SUCCESS)
Main PID: 528304 (code=exited, status=1/FAILURE)
Aug 23 03:15:00 localhost.localdomain systemd[1]: Starting nacos...
Aug 23 03:15:00 localhost.localdomain startup.sh[529762]: /usr/lib/jvm/java-1.8.0-openjdk-1.8.0.422.b05-2.el8.x86_64/bin/java -Djava.ext.dirs=/usr/lib/jvm/java-1.8.0-openjdk-1.8.0.422.b05-2.el8.x86_64/jre/lib/ext:/usr/lib/jvm/java-1.8.0>
Aug 23 03:15:00 localhost.localdomain startup.sh[529762]: nacos is starting with standalone
Aug 23 03:15:00 localhost.localdomain startup.sh[529762]: nacos is starting. you can check the /usr/local/nacos/logs/start.out
Aug 23 03:15:00 localhost.localdomain systemd[1]: Started nacos.
Aug 23 03:15:06 localhost.localdomain shutdown.sh[529868]: No nacosServer running.
Aug 23 03:15:06 localhost.localdomain systemd[1]: nacos.service: Control process exited, code=exited status=255
Aug 23 03:15:06 localhost.localdomain systemd[1]: nacos.service: Failed with result 'exit-code'.
lines 1-15/15 (END) Caused by: java.lang.IllegalArgumentException: The specified key byte array is 0 bits which is not secure enough for any JWT HMAC-SHA algorithm. The JWT JWA Specification (RFC 7518, Section 3.2) states that keys used with HMAC-SHA algorithms MUST have a size >= 256 bits (the key size must be greater than or equal to the hash output size). See https://tools.ietf.org/html/rfc7518#section-3.2 for more information.
at com.alibaba.nacos.plugin.auth.impl.jwt.NacosJwtParser.(NacosJwtParser.java:54)
at com.alibaba.nacos.plugin.auth.impl.token.impl.JwtTokenManager.processProperties(JwtTokenManager.java:76)
... 120 common frames omitted
2024-08-23 03:15:06,260 WARN [ThreadPoolManager] Start destroying ThreadPool
The specified key byte array is 0 bits
看这个提示,说明没有配置鉴权相关的内容和specified key。
在新版的nacos鉴权是必须要开启的。参照https://editor.csdn.net/md/?articleId=128924056 中nacos漏洞修复部分内容。
版权声明:本文内容由阿里云实名注册用户自发贡献,版权归原作者所有,阿里云开发者社区不拥有其著作权,亦不承担相应法律责任。具体规则请查看《阿里云开发者社区用户服务协议》和《阿里云开发者社区知识产权保护指引》。如果您发现本社区中有涉嫌抄袭的内容,填写侵权投诉表单进行举报,一经查实,本社区将立刻删除涉嫌侵权内容。