一、错误异常
代码链接redis后,运行 "org.springframework.data.redis.RedisSystemException: Error in execution; nested exception is io.lettuce.core.RedisCommandExecutionException: ERR wrong number of arguments for 'info' command...io.lettuce.core.RedisCommandExecutionException: ERR wrong number of arguments for 'info' command"错误异常,详细日志>>
2023-08-13 00:26:02.127 [lettuce-nioEventLoop-4-3] WARN o.s.b.actuate.redis.RedisReactiveHealthIndicator:92 - Redis health check failed@b@org.springframework.data.redis.RedisSystemException: Error in execution; nested exception is io.lettuce.core.RedisCommandExecutionException: ERR wrong number of arguments for 'info' command@b@ at org.springframework.data.redis.connection.lettuce.LettuceExceptionConverter.convert(LettuceExceptionConverter.java:54)@b@ at org.springframework.data.redis.connection.lettuce.LettuceExceptionConverter.convert(LettuceExceptionConverter.java:41)@b@ at org.springframework.data.redis.connection.lettuce.LettuceReactiveRedisConnection.lambda$translateException$0(LettuceReactiveRedisConnection.java:293)@b@ at reactor.core.publisher.Flux.lambda$onErrorMap$28(Flux.java:7070)@b@ at reactor.core.publisher.FluxOnErrorResume$ResumeSubscriber.onError(FluxOnErrorResume.java:94)@b@ at reactor.core.publisher.MonoFlatMapMany$FlatMapManyInner.onError(MonoFlatMapMany.java:255)@b@ at reactor.core.publisher.MonoNext$NextSubscriber.onError(MonoNext.java:93)@b@ at reactor.core.publisher.MonoNext$NextSubscriber.onError(MonoNext.java:93)@b@ at io.lettuce.core.RedisPublisher$ImmediateSubscriber.onError(RedisPublisher.java:891)@b@ at io.lettuce.core.RedisPublisher$State.onError(RedisPublisher.java:712)@b@ at io.lettuce.core.RedisPublisher$RedisSubscription.onError(RedisPublisher.java:357)@b@ at io.lettuce.core.RedisPublisher$SubscriptionCommand.onError(RedisPublisher.java:797)@b@ at io.lettuce.core.RedisPublisher$SubscriptionCommand.doOnComplete(RedisPublisher.java:757)@b@ at io.lettuce.core.protocol.CommandWrapper.complete(CommandWrapper.java:65)@b@ at io.lettuce.core.protocol.CommandWrapper.complete(CommandWrapper.java:63)@b@ at io.lettuce.core.protocol.CommandHandler.complete(CommandHandler.java:747)@b@ at io.lettuce.core.protocol.CommandHandler.decode(CommandHandler.java:682)@b@ at io.lettuce.core.protocol.CommandHandler.channelRead(CommandHandler.java:599)@b@ at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:442)@b@ at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:420)@b@ at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:412)@b@ at io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1410)@b@ at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:440)@b@ at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:420)@b@ at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:919)@b@ at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:166)@b@ at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:788)@b@ at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:724)@b@ at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:650)@b@ at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:562)@b@ at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:997)@b@ at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74)@b@ at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30)@b@ at java.lang.Thread.run(Thread.java:748)@b@Caused by: io.lettuce.core.RedisCommandExecutionException: ERR wrong number of arguments for 'info' command@b@ at io.lettuce.core.internal.ExceptionFactory.createExecutionException(ExceptionFactory.java:147)@b@ at io.lettuce.core.internal.ExceptionFactory.createExecutionException(ExceptionFactory.java:116)@b@ ... 22 common frames omitted
二、解决方法
redis版本过低,重新下载“Redis-x64-3.2.100” 或 “Redis-x64-5.0.14”替换“redis-2.4.2”低版本,即可解决问题