File tree Expand file tree Collapse file tree 1 file changed +33
-0
lines changed
Expand file tree Collapse file tree 1 file changed +33
-0
lines changed Original file line number Diff line number Diff line change @@ -153,6 +153,39 @@ Caused by: java.io.IOException: invalid constant type: 15
153153
154154http://asm.ow2.org/history.html
155155
156+ ### Java连接redis启动报错Error redis clients jedis HostAndPort cant resolve localhost address
157+
158+ 错误环境:
159+ 本地window开发环境没有问题。上到Linux环境,启动出现问题。
160+ 错误信息:
161+ Error redis clients jedis HostAndPort cant resolve localhost address
162+
163+ 解决办法:
164+
165+ 1 . 查看Linux系统的主机名
166+
167+ ```
168+ # hostname
169+ template
170+ ```
171+
172+ 2 . 查看/etc/hosts文件中是否有127.0.0.1对应主机名,如果没有则添加
173+
174+ ### Resin 容器指定 JDK 1.8
175+
176+ 如果 resin 容器原来版本低于 JDK1.8,运行 JDK 1.8 编译的 web app 时,可能会提示错误:
177+
178+ ```
179+ java.lang.UnsupportedClassVersionError: PR/Sort : Unsupported major.minor version 52.0
180+ ```
181+
182+ 解决方法就是,使用 JDK 1.8 要重新编译一下。然后,我在部署时出现过编译后仍报错的情况,重启一下服务器后,问题解决,不知是什么原因。
183+
184+ ```
185+ ./configure --prefix=/usr/local/resin --with-java=/usr/local/jdk1.8.0_121
186+ make & make install
187+ ```
188+
156189## 资料
157190
158191- [ Compatibility Guide for JDK 8] ( http://www.oracle.com/technetwork/java/javase/8-compatibility-guide-2156366.html )
You can’t perform that action at this time.
0 commit comments