java.net.SocketException: Unexpected end of file from server 异常解决
来源:互联网 发布:知远战略与防务网站 编辑:程序博客网 时间:2024/06/11 03:48
java.net.SocketException: Unexpected end of file from server
at sun.net.www.http.HttpClient.parseHTTPHeader(HttpClient.java:806)
at sun.net.www.http.HttpClient.parseHTTP(HttpClient.java:665)
at sun.net.www.http.HttpClient.parseHTTPHeader(HttpClient.java:803)
at sun.net.www.http.HttpClient.parseHTTP(HttpClient.java:665)
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1230)
........
........
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:103)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:293)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:861)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:606)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:489)
at java.lang.Thread.run(Thread.java:761)
这个问题头疼了两天,参考了网上大量资料,但都没有解决,唯一一个接近问题的帖子,只是说了一句网络配置问题。当时真想打这个人,写都写了,为什么不写清楚点,于是,我决定开个帖子写清楚,痛定思痛。
刚开始,这个问题在我本地跑起来没有一点问题,一部署到服务器就出错。经过排查,代码没问题。然后开始考虑是部署环境问题。
本地是windows系统,服务器是aix操作系统,有可能是aix操作系统的问题,看了几个帖子也觉得是操作系统问题。但是对于aix真是不太了解,网上可查资料很少。
然后换了一个Linux服务器测试,结果没问题。
开始分析错误。错误说遇到了一个意外的文件而结束。
这个时候试着修改了一下要获取的文件,还是一样的错误。
后来看到一个帖子,就是那个说可能是网络配置的问题。
询问了硬件部门,说aix系统没有什么特殊配置,然后就想到了之前遇到的一个问题(关于dns的),将域名改为了ip地址。
访问成功。
其实很简单,但是真的废了好大功夫。明明自己本地没有问题,放到服务器就是出错。对于我这个还在菜鸟蹉跎的人,真心是无法言语了。
特意重新开了博客,在此记录自己的问题。
在此贴几个链接,都是在解决问题中有些帮助的,其中将javaweb 应用从 windows移植到aix时需要注意的问题,可以看看。
https://www.ibm.com/developerworks/cn/aix/library/au-aix-javatraps/
这个没什么用,可以看看,毕竟还是有说一点的http://www.blogjava.net/anchor110/articles/348867.html
这个帖子里面提到过域名换ip。我也试了不知道为什么没试成功,第二天将文件改了之后成功了,以为是文件问题,谁知道把文件恢复,还是成功了,把ip换成域名,又不行了,然后联想dns才确定的问题。https://www.v2ex.com/t/182859。
虽然写的我自己都看不下去,但是就这样吧。以后遇到也是个记录
- java.net.SocketException: Unexpected end of file from server 异常解决
- java.net.SocketException: Unexpected end of file from server
- java.net.SocketException: Unexpected end of file from server
- SocketException: Unexpected end of file from server 问题解决
- java微信退款unexpected end of file from server
- 在研究百度手写功能时遇到Unexpected end of file from server错误,为什么?
- unexpected end of file
- java.net.ProtocolException: unexpected end of stream
- 解决shell错误:syntax error: unexpected end of file
- 配置NDK syntax error: unexpected end of file 解决
- Resin#unexpected end of file in utf8 character解决过程
- syntax error : unexpected end of file 问题的解决
- unexpected end of file found
- bash: unexpected end of file
- unexpected end of file found
- Linux unexpected end of file ,`xxxx' unexpected
- unexpected end of subtree异常
- java.io.EOFException: Unexpected end of ZLIB input stream解决
- 延迟加载(Lazyload)三种实现方式
- VUE组件之间的通信
- opencv对遥感图像基本操作
- mysql-5.7.20-winx64.zip 安装
- Struts2(八)---通用标签&表单标签
- java.net.SocketException: Unexpected end of file from server 异常解决
- 安装使用chardet插件
- mysql explain 执行计划详解
- 软考之计算机网络
- NOIP 2016 D1T3换教室
- ceph-deploy的入口函数
- Educational Codeforces Round 31 题解
- 内存分析工具
- 51nod1615 跳跃的杰克