'Failed to write tracking files to (eg: D:Users/.m2/repository) caused by java.IOException : There is no enough space on disk
My work is automate CICD using azure app service and jenkins. Jenkins deployed as .WAR in app service site/wwwroot/webapps folder so that i can access jenkins outside. In jenkins I created a job(namely CheckoutandBuild) which is maven based. Duty of this job is to fetch the source code(from the bitbucket) and to execute the maven goal clean compile. To execute the job it required JDK,Git,Maven. So,in jenkins global configuration I configured JDK,Git,Maven maven I have selected the option Install automatically this will configure maven to my job and also created .m2 folder. recently i executed my jenkin job CheckoutandBuild. It has started but after few seconds it is giving below warning and exception in my jenkins console output
[WARNING] Failed to write tracking file D:\Users\Pipeline\.m2\repository\org\codehaus\plexus\plexus-java\0.9.10\plexus-java-0.9.10.jar.lastUpdated
java.io.FileNotFoundException: D:\Users\Pipeline\.m2\repository\org\codehaus\plexus\plexus-java\0.9.10\plexus-java-0.9.10.jar.lastUpdated (There is not enough space on the disk)
[WARNING] Failed to write tracking file D:\Users\Pipeline\.m2\repository\org\ow2\asm\asm\6.2\asm-6.2.jar.lastUpdated
java.io.FileNotFoundException: D:\Users\Pipeline\.m2\repository\org\ow2\asm\asm\6.2\asm-6.2.jar.lastUpdated (There is not enough space on the disk)
Failed to write tracking file D:\Users\Pipeline\.m2\repository\com\thoughtworks\qdox\qdox\2.0-M9\qdox-2.0-M9.jar.lastUpdated
java.io.FileNotFoundException: D:\Users\Pipeline\.m2\repository\com\thoughtworks\qdox\qdox\2.0-M9\qdox-2.0-M9.jar.lastUpdated (There is not enough space on the disk)
Similarly There are many warnings and exception with the above message I tried by configuring Maven manually instead of using install automatically option in jenkins. and also tried by downgrading the maven version currently configured maven 3.8.1. It is showing not enough space on disk my disk space was 4GB I have deleted few unwanted files now space is 2GB still getting this exception in my console.
At last my Build failed
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 15.875 s
[INFO] Finished at: 2022-05-05T13:11:10Z
[INFO] ------------------------------------------------------------------------
Waiting for Jenkins to finish collecting data
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.8.1:compile (default-compile) on project SpringBoot: Execution default-compile of goal org.apache.maven.plugins:maven-compiler-plugin:3.8.1:compile failed: Plugin org.apache.maven.plugins:maven-compiler-plugin:3.8.1 or one of its dependencies could not be resolved: The following artifacts could not be resolved: org.apache.maven:maven-settings:jar:3.0, org.apache.maven:maven-settings-builder:jar:3.0, org.codehaus.plexus:plexus-interpolation:jar:1.14, org.apache.maven.shared:maven-shared-incremental:jar:1.1, org.codehaus.plexus:plexus-java:jar:0.9.10, org.ow2.asm:asm:jar:6.2, com.thoughtworks.qdox:qdox:jar:2.0-M9, org.codehaus.plexus:plexus-compiler-api:jar:2.8.4, org.codehaus.plexus:plexus-compiler-manager:jar:2.8.4, org.codehaus.plexus:plexus-compiler-javac:jar:2.8.4: Could not transfer artifact org.apache.maven:maven-settings:jar:3.0 from/to central (https://repo.maven.apache.org/maven2): GET request of: org/apache/maven/maven-settings/3.0/maven-settings-3.0.jar from central failed: There is not enough space on the disk -> [Help 1]
[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.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginResolutionException.
How to fix this issue? What Im missing ?
Solution 1:[1]
try to delete your .m2 file and update your project in maven, your m2 files will be in same location where your jdk file
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | hsynuls |
