windows下eclipse跑junit报错:CreateProcess error=206
from:http://isuifengfei.iteye.com/blog/1684262
windows下,eclipse中运行junit出现错误提示:
Exception occurred executing command line.
Cannot run program "D:\Program Files\Java\jdk1.6.0_30\bin\javaw.exe" (in directory "D:\work\mywork\20120829_159367_2\biz\product"): CreateProcess error=206, ÎļþÃû»ò)չÃû
原因是在Windows下命令行支持的字符串长度是有限制的,
在计算机上运行 Microsoft Windows XP 或更高版本,可以在命令提示符下使用的字符串的最大的长度 8191 个字符。
在运行 Microsoft Windows 2000 或 Windows NT 4.0 的计算机上, 将最大长度可以在命令提示符下使用的字符串的为 2047 个字符。
(参照微软官方文档:http://support.microsoft.com/kb/830473/zh-cn)
这个是eclipse的bug,参考:https://bugs.eclipse.org/bugs/show_bug.cgi?id=327193
解决办法:
(1)下载修复包:https://bugs.eclipse.org/bugs/attachment.cgi?id=219900
(2)把本地eclipse的eclipse/plugins/org.eclipse.jdt.launching_3.4.*.jar复制到一个安全的地方,便于恢复。
- copy your eclipse/plugins/org.eclipse.jdt.launching_3.4.*.jar to a safe place outside of the plugins folder, so that you always have a way to revert
- close Eclipse
(3)把jar重命名为zip
- rename the *.jar to *.zip
(4)打开zip包,拷贝下载的修复包里面的四个class文件到org\eclipse\jdt\internal\launching里面
- open the zip file and copy the 4 class files from the attachment to org\eclipse\jdt\internal\launching (replace existing files)
(5)进入META-INF目录,删除除了MANIFEST.MF以外的所有的文件
- go to META-INF in the zip file and delete all files except MANIFEST.MF
(6)解压MANIFEST.MF,删除以 "NAME:"开头的所有的entry(两行是一个entry)
- extract MANIFEST.MF to your disk and edit it with a text editor
- remove everything starting from the first "NAME:" entry
(7)保证MANIFEST.MF文件的结尾有两个空行
- make sure you leave *two* (2) line break characters at the end of the file!
(8)保存MANIFEST.MF进zip包
- save the MANIFEST.MF and copy it back into the zip file
(9)zip包重命名为jar
- rename the *.zip back to *.jar
(10)放到eclipse下面,替换之前的jar
- enjoy
高版本的eclipse(4.3 M1)已经修复这个bug了。
修改以后的jar包下载:http://download.csdn.net/download/goldenfish1919/6244901
windows下eclipse跑junit报错:CreateProcess error=206的更多相关文章
- Github上LeakCanary编译报错CreateProcess error=2的解决方法
现象说明: 从github上拉下LeakCanary编译时报错 CreateProcess error=2, ϵͳÕҲ»µ½ָ¶ 原因分析: 该现象是由于Windows中Gradle调用命令未加cmd ...
- linux下unzip解压报错“symlink error: File name too long”怎么办?提供解决方案。
点击上方↑↑↑蓝字[协议分析与还原]关注我们 " 分享unzip工具的一个bug." 最近在研究菠菜站,中间用到了Spidermonkey,碰到一些小波折,在这里分享出来,以便大家 ...
- ubuntu 下安装 mysql 启动报错:ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)
环境: ubuntu LTS 18.04.1 mysql Ver 14.14 Distrib 5.7.29, for Linux (x86_64) 初探 linux,按照如下安装完mysql sudo ...
- Windows下pip安装包报错:Microsoft Visual C++ 9.0 is required Unable to find vcvarsall.bat
刚在机器上windows环境下装上pip方便以后安装包的时候使用,谁知道第一次使用pip安装asyncio的时候就报错. 在Windows7x64下使用pip安装包的时候提示报错:Microsoft ...
- Windows下安装模块mysqlclient报错处理
Windows环境下使用pip命令安装Python模块mysqlclientpip install mysqlclient安装过程报错 [error] Microsoft Visual C++ 14 ...
- 【python】 Windows下pip安装包报错:Microsoft Visual C++ 9.0 is required Unable to find vcvarsall.bat
刚在机器上windows环境下装上pip方便以后安装包的时候使用,谁知道第一次使用pip安装asyncio的时候就报错. 在Windows7x64下使用pip安装包的时候提示报错:Microsoft ...
- (转)Windows下pip安装包报错:Microsoft Visual C++ 9.0 is required Unable to find vcvarsall.bat
刚在机器上windows环境下装上pip方便以后安装包的时候使用,谁知道第一次使用pip安装asyncio的时候就报错. 在Windows7x64下使用pip安装包的时候提示报错:Microsoft ...
- windows 下使用github客户端报错:Failed to publish this branch
在windows系统下使用github客户端同步的时候报错“Failed to publish this branch”,查找原因,发现结果是安装vscode的时候没有检查到git,然后安装git后库 ...
- [python]解决Windows下安装第三方插件报错:UnicodeDecodeError: 'ascii' codec can't decode byte 0xcb in position 0:
系统:win7IDE:pycharm Python版本:2.7 安装第三方插件是报错: 报错原因与编码有关,pip把下载的临时文件存放在了用户临时文件中,这个目录一般是C:\Users\用户名\Ap ...
随机推荐
- 腾讯QQ:异地登陆也被封号,你们是怎么决策的???
此文我想放到首页,让很多其它的人看到,更期待有人能解释一下.希望管理员给开绿灯. 今天真是费解,我的手机号是青岛的.可是我在武汉工作,因为是3G的卡,全国没有漫游,打电话也没多少钱,所以就没换号. 谁 ...
- Unity3d 网络编程(二)(Unity3d内建网络各项參数介绍)
这里是全部Unity3d在网络中能用到相关的类及方法.纵观參数功能, Unity3d来写一个手游是不二的选择: RPC 能够传递的參数 int float string NetworkPlayer N ...
- 【iOS】用Layer创建一个三维模型以及拖动
关于CALayer的介绍以及基本属性,在这篇博客中有交代:CoreAnimation —— CALayer 这篇博客讲述简单的通过对layer的transform属性的设置一个CATransform3 ...
- java--多线程之Runnable
引读: 上一篇博文中讲了Thread的继承,存在一个问题就是,如果类本身已经继承了某个父类,又要继承Thread,导致多重继承. [但是我们知道接口是实现多重继承的重要方式].java提供了Runna ...
- gethostbyname() -- 用域名或主机名获取IP地址
#include <netdb.h> #include <sys/socket.h> struct hostent *gethostbyname(const char * ...
- CCIE路由实验(8) -- QoS
1.查看端口缺省的队列机制2.配置CB-WFQ3.配置CB-LLQ4.配置CB-Shapping在以太接口下5.配置CB-Shapping在FR接口下6.配置帧中继流量整形FRTS7.配置CB-Pol ...
- Offer_1
#include <iostream> #include <cstring> using namespace std; class CMyString { public: CM ...
- 超级坑人的Couchbase数据库问题!!!
官网:http://www.couchbase.com/ 版本:1.8版 问题描述: 某次服务器因意外断电重启后,就进入不了Couchbase控制台,显示 "无法显示该页" 的错误 ...
- C# - 接口的继承
代码: using System; using System.Collections.Generic; using System.Linq; using System.Text; using Syst ...
- BZOJ 3173: [Tjoi2013]最长上升子序列( BST + LIS )
因为是从1~n插入的, 慢插入的对之前的没有影响, 所以我们可以用平衡树维护, 弄出最后的序列然后跑LIS就OK了 O(nlogn) --------------------------------- ...