maven 在cmd命令使用mvn help:system报错
问题描述
maven已经下载好了
C:\Users\HQ>mvn -v
Apache Maven 3.5.3 (3383c37e1f9e9b3bc3df5050c29c8aff9f295297; 2018-02-25T03:49:05+08:00)
Maven home: C:\Program Files\Java\maven\apache-maven-3.5.3\bin\..
Java version: 1.8.0_171, vendor: Oracle Corporation
Java home: C:\Program Files\Java\jdk1.8.0_171\jre
Default locale: zh_CN, platform encoding: GBK
OS name: "windows 10", version: "10.0", arch: "amd64", family: "windows"
可是运用到eclipse就报错说文件不存在等问题,后来我就试着在cmd命令下运行 mvn help:system
想导入一些文件进来发现报错一堆,有说文件不存在有说无法访问的
cmd执行命令错误代码:
C:\Users\HQ>mvn help:system
[INFO] Scanning for projects...
Downloading from aliyunMaven: http://maven.aliyun.com/nexus/content/groups/public/org/apache/maven/plugins/maven-clean-plugin/2.5/maven-clean-plugin-2.5.pom
[WARNING] Failed to create parent directories for tracking file C:\Program Files\Java\maven\repository\org\apache\maven\plugins\maven-clean-plugin\2.5\maven-clean-plugin-2.5.pom.lastUpdated
[WARNING] Failed to retrieve plugin descriptor for org.apache.maven.plugins:maven-clean-plugin:2.5: Plugin org.apache.maven.plugins:maven-clean-plugin:2.5 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-clean-plugin:jar:2.5
Downloading from aliyunMaven: http://maven.aliyun.com/nexus/content/groups/public/org/apache/maven/plugins/maven-install-plugin/2.4/maven-install-plugin-2.4.pom
[WARNING] Failed to create parent directories for tracking file C:\Program Files\Java\maven\repository\org\apache\maven\plugins\maven-install-plugin\2.4\maven-install-plugin-2.4.pom.lastUpdated
[WARNING] Failed to retrieve plugin descriptor for org.apache.maven.plugins:maven-install-plugin:2.4: Plugin org.apache.maven.plugins:maven-install-plugin:2.4 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-install-plugin:jar:2.4
Downloading from aliyunMaven: http://maven.aliyun.com/nexus/content/groups/public/org/apache/maven/plugins/maven-deploy-plugin/2.7/maven-deploy-plugin-2.7.pom
[WARNING] Failed to create parent directories for tracking file C:\Program Files\Java\maven\repository\org\apache\maven\plugins\maven-deploy-plugin\2.7\maven-deploy-plugin-2.7.pom.lastUpdated
[WARNING] Failed to retrieve plugin descriptor for org.apache.maven.plugins:maven-deploy-plugin:2.7: Plugin org.apache.maven.plugins:maven-deploy-plugin:2.7 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-deploy-plugin:jar:2.7
Downloading from aliyunMaven: http://maven.aliyun.com/nexus/content/groups/public/org/apache/maven/plugins/maven-site-plugin/3.3/maven-site-plugin-3.3.pom
[WARNING] Failed to create parent directories for tracking file C:\Program Files\Java\maven\repository\org\apache\maven\plugins\maven-site-plugin\3.3\maven-site-plugin-3.3.pom.lastUpdated
[WARNING] Failed to retrieve plugin descriptor for org.apache.maven.plugins:maven-site-plugin:3.3: Plugin org.apache.maven.plugins:maven-site-plugin:3.3 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-site-plugin:jar:3.3
Downloading from aliyunMaven: http://maven.aliyun.com/nexus/content/groups/public/org/apache/maven/plugins/maven-antrun-plugin/1.3/maven-antrun-plugin-1.3.pom
[WARNING] Failed to create parent directories for tracking file C:\Program Files\Java\maven\repository\org\apache\maven\plugins\maven-antrun-plugin\1.3\maven-antrun-plugin-1.3.pom.lastUpdated
[WARNING] Failed to retrieve plugin descriptor for org.apache.maven.plugins:maven-antrun-plugin:1.3: Plugin org.apache.maven.plugins:maven-antrun-plugin:1.3 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-antrun-plugin:jar:1.3
Downloading from aliyunMaven: http://maven.aliyun.com/nexus/content/groups/public/org/apache/maven/plugins/maven-assembly-plugin/2.2-beta-5/maven-assembly-plugin-2.2-beta-5.pom
[WARNING] Failed to create parent directories for tracking file C:\Program Files\Java\maven\repository\org\apache\maven\plugins\maven-assembly-plugin\2.2-beta-5\maven-assembly-plugin-2.2-beta-5.pom.lastUpdated
[WARNING] Failed to retrieve plugin descriptor for org.apache.maven.plugins:maven-assembly-plugin:2.2-beta-5: Plugin org.apache.maven.plugins:maven-assembly-plugin:2.2-beta-5 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-assembly-plugin:jar:2.2-beta-5
Downloading from aliyunMaven: http://maven.aliyun.com/nexus/content/groups/public/org/apache/maven/plugins/maven-dependency-plugin/2.8/maven-dependency-plugin-2.8.pom
[WARNING] Failed to create parent directories for tracking file C:\Program Files\Java\maven\repository\org\apache\maven\plugins\maven-dependency-plugin\2.8\maven-dependency-plugin-2.8.pom.lastUpdated
[WARNING] Failed to retrieve plugin descriptor for org.apache.maven.plugins:maven-dependency-plugin:2.8: Plugin org.apache.maven.plugins:maven-dependency-plugin:2.8 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-dependency-plugin:jar:2.8
Downloading from aliyunMaven: http://maven.aliyun.com/nexus/content/groups/public/org/apache/maven/plugins/maven-release-plugin/2.5.3/maven-release-plugin-2.5.3.pom
[WARNING] Failed to create parent directories for tracking file C:\Program Files\Java\maven\repository\org\apache\maven\plugins\maven-release-plugin\2.5.3\maven-release-plugin-2.5.3.pom.lastUpdated
[WARNING] Failed to retrieve plugin descriptor for org.apache.maven.plugins:maven-release-plugin:2.5.3: Plugin org.apache.maven.plugins:maven-release-plugin:2.5.3 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-release-plugin:jar:2.5.3
Downloading from aliyunMaven: http://maven.aliyun.com/nexus/content/groups/public/org/codehaus/mojo/maven-metadata.xml
Downloading from aliyunMaven: http://maven.aliyun.com/nexus/content/groups/public/org/apache/maven/plugins/maven-metadata.xml
[WARNING] Failed to create parent directories for tracking file C:\Program Files\Java\maven\repository\org\codehaus\mojo\resolver-status.properties
[WARNING] Failed to write tracking file C:\Program Files\Java\maven\repository\org\apache\maven\plugins\resolver-status.properties
java.io.FileNotFoundException: C:\Program Files\Java\maven\repository\org\apache\maven\plugins\resolver-status.properties (拒绝访问。)
at java.io.RandomAccessFile.open0 (Native Method)
at java.io.RandomAccessFile.open (RandomAccessFile.java:316)
at java.io.RandomAccessFile.<init> (RandomAccessFile.java:243)
at org.eclipse.aether.internal.impl.TrackingFileManager.update (TrackingFileManager.java:105)
at org.eclipse.aether.internal.impl.DefaultUpdateCheckManager.write (DefaultUpdateCheckManager.java:615)
at org.eclipse.aether.internal.impl.DefaultUpdateCheckManager.touchMetadata (DefaultUpdateCheckManager.java:582)
at org.eclipse.aether.internal.impl.DefaultMetadataResolver$ResolveTask.run (DefaultMetadataResolver.java:627)
at org.eclipse.aether.util.concurrency.RunnableErrorForwarder$1.run (RunnableErrorForwarder.java:75)
at java.util.concurrent.ThreadPoolExecutor.runWorker (ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run (ThreadPoolExecutor.java:624)
at java.lang.Thread.run (Thread.java:748)
[WARNING] Could not transfer metadata org.apache.maven.plugins/maven-metadata.xml from/to aliyunMaven (http://maven.aliyun.com/nexus/content/groups/public/): C:\Program Files\Java\maven\repository\org\apache\maven\plugins\maven-metadata-aliyunMaven.xml.part.lock (拒绝访问。)
[WARNING] Could not transfer metadata org.codehaus.mojo/maven-metadata.xml from/to aliyunMaven (http://maven.aliyun.com/nexus/content/groups/public/): C:\Program Files\Java\maven\repository\org\codehaus\mojo\maven-metadata-aliyunMaven.xml.part.lock (系统找不到指定的路径。)
Downloading from aliyunMaven: http://maven.aliyun.com/nexus/content/groups/public/org/apache/maven/plugins/maven-metadata.xml
Downloading from aliyunMaven: http://maven.aliyun.com/nexus/content/groups/public/org/codehaus/mojo/maven-metadata.xml
[WARNING] Failed to write tracking file C:\Program Files\Java\maven\repository\org\apache\maven\plugins\resolver-status.properties
[java.io.FileNotFoundException: ExceptiCo:n\ Pirno gtrharme aFdi l"eDse\fJaauvlat\Mmeatvaedna\traeRpeossoiltvoerry-\1o-r:g"\ apache\maven\plugins\resoljvaevra-.sltaantgu.sN.upmrboepreFrotrimeast E(x拒c绝e访p问t。i)on
A F o r inaptut jsatvrai.nigo:. R"a3n1dmo"m
n caet javas.slang.FNuimberFormatException.forInputString(NumberFormatExlec.eopption.java:65)e
e a t( java.lanNga.Itnitveeg eMre.pthaordseInt(In)t
e r.java:580)
o at jaavta. ljang.avIan.teger.<init>(Integer.java:867)i
i Raatn dorg.fusesource.jansi.AnsiPrintStream.filter(AnsiPomAcrcientStrsesam.java:129)F
a ea.t org.fusesource.janospie.nFilter P(rinRtaSntdroemaAmc.cwersistFei(lFei.ljtaevraP:r3i1n6tS)tre
m . j a va:97a)t
i at org.fusesource.jansi.FilterPrintStrejaamv.awrite(FilterPrintStream.java:107).
o .at org.fusesource.jansi.FilterPrintStream.print(FilterPRraintStream.java:156)n
n at org.fusesouormcAec.cjeasnsi.FilterPsrFintStream.println(FilterPrintStream.javilae:.2<31)i
c ta>t org.slf4j.impl.SimpleLogge r(.write(SimpRlaenLodgger.java:o3m18)A
c easts Foirg.sllef.4j.impl.SimpleLogger.log(SimpleLogger.java:295)j
a vaat: 2org.slf4j.impl.SimpleLogger.warn(SimpleLo4g3ge)r.java:522)
at org.eclipse . a etheart.internal.impl.slf4j.Slf4jLoggerFactory$Slf4jLogge ro.warn(Slf4jLoggerrFactory.java:14c6.)e
l iat org.epcslei.paseet.haeert.hienrt.eirnntaelr.niamlp.li.mpTlr.aTcrakcikningFilgeFMainlaegMearn.aupdate(TrackindgeFri.lueManager.java:97)p
c att eorg.ec l(ipse.aether.internal.impl.DefaultUpdTarteCheckManager.write(DefaultUpdateCheckManager.java:615)a
k at org.eclipse.aether.inteinrgnFail.ilmepMl.DefaultUpdateCheckManager.touchMetadata(DefaultaUnpdateCheckManager.ajgaevra.:j58a2v)a:
$ 0a5t org.eclipse.aether.internal.impl.DefaultMetadataResolv)er
o e s o lveTask.runa(DefatultMetadataResolver.java:627)
e ga.te corg.eclipse.aether.util.concurrelnicpy.RunnableErrorForwarder$1.run(RunnableErrorForwarder.sjea.va:75)a
l haet java.util.concurrent.Thrr.eiadPoolExecutor.runWorker(ThreadPoolExecutor.java:1n1t4er9n)a
. iamtp lj.aDveaf.auutill.ctoUnpdacurtreenCth.eTchkrMeaandaPgoeorl.Executor$Worker.run(ThreadPoolExecutor.java:624w)r
j taet java.l a(ng.DTehfraeualdt.Urpudna(tTehCrheeacdk.Mjaanvaag:e7r4.8)
ava:615)
at org.eclipse.aether.internal.impl.DefaultUpdateCheckManager.touchMetadata (DefaultUpdateCheckManager.java:582)
at org.eclipse.aether.internal.impl.DefaultMetadataResolver$ResolveTask.run (DefaultMetadataResolver.java:627)
at org.eclipse.aether.util.concurrency.RunnableErrorForwarder$1.run (RunnableErrorForwarder.java:75)
at java.util.concurrent.ThreadPoolExecutor.runWorker (ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run (ThreadPoolExecutor.java:624)
at java.lang.Thread.run (Thread.java:748)
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1.235 s
[INFO] Finished at: 2018-09-06T17:25:35+08:00
[INFO] ------------------------------------------------------------------------
[ERROR] For input string: "31m"
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
settings.xml文件的配置(我只改了两处):
<localRepository>C:\Program Files\Java\maven\repository</localRepository>
<mirror>
<id>aliyun</id>
<mirrorOf>aliyun</mirrorOf>
<name>aliyun Maven</name>
<url>http://maven.aliyun.com/nexus/content/groups/public/</url>
</mirror>
找了很久不知道怎么办,希望能有大神帮我解决一下,拜托,谢谢大家。
解决了,大致的问题应该是因为我系统是win10的然后对C盘有保护,导致无法导入文件,才报错,我的解决办法是在D盘下重新安装maven不受权限限制,配置也一样,就OK了~~~如果是还想在C盘下存那就去更改权限,因为有点复杂自行百度步骤啊哈哈哈哈哈哈哈哈,就这样谢谢大家了
- 等 最代码怎么获取牛币啊?
- 完 谁来告诉我最代码上线的时间,答对者给5牛币,先来先得
- 等 牛友们,大家好,你们做程序员多久了?现在还好吗?
- 完 在微信打开的页面里进行app下载
- 等 最代码2014年欢乐聚声会
- 完 mysql如何查询表数据并且对3个字段降序的SQL?
- 完 最代码牛币机制改革
- 完 成功的在bae上使用了自定义运行环境 jetty+nginx的组合,大家对jetty+nginx优化有哪些心得?
- 完 进来分享一下各位牛牛是如何加入最代码大家庭的?
- 等 为什么java BufferedImage类处理大图直接抛出内存溢出的异常?
- 等 最代码是否开发手机app客户端?
- 完 java程序员学习哪些java的技术?java有哪些框架?都能做哪方面的开发?
- 等 php格式网页文件怎么运行?
- 等 Java volatile值获取的问题
- 等 前端vue,拦截了登录后台后,返回的token,requests拦截token,但是发送请求的时候,就出现跨越异常
- 等 大专本科计算机科班怎么找到Java工作?
- 等 eclipse怎么把三个java swing游戏项目合成一个项目?
- 完 伙伴们,大家都有什么好的解压方式么,分享一下~
- 完 三四线城市,6、7k,运维工作,索然无味,想去辞职上培训,各位牛牛有什么建议嘛
- 等 jsp页面输入中文变成问号
- 等 JPA在线上运行一段时间后报错Caused by: java.lang.IncompatibleClassChangeError: null
- 等 PHP 这个规则用preg_match_all怎么写
- 等 大佬们,有没有知道Alfresco如何配置LDAP登录呢?
- 等 php的install目录是框架带的吗?
- 等 maven运行一直报错
- 完 为什么java maven项目中依赖的第三方maven项目搜索不到?
- 等 maven为什么找不到spring-boot-starter-web-jdbcjar包?
- 等 maven构建java项目为什么没有想象的好用?
- 等 MyEclipse怎么配置搭建Maven项目?
- 等 maven项目如何依赖另一个项目的配置文件?
- 等 eclipse下maven项目发布到tomcat lib目录没有,哪里有问题
- 完 java开发者在搭建Maven项目开发中有哪些奇葩的问题?是如何解决的?
- 等 导入项目maven后xml,xsd文件为什么报错?
- 完 菜鸟maven问题:maven-project-info-reports-plugin:3.0.0' not found more... 怎么解决
- 完 eclipse用debug调试maven项目,为什么出现source not found的问题?
- 等 多个maven项目整合成一个大的项目,比如dao,service,cotroller分开,会不会对系统的性能有所提升?