# Maven build problem

**URL:** <https://discuss.elastic.co/t/maven-build-problem/4130>\
**Category:** Elasticsearch\
**Created:** [March 19, 2011, 12:54am UTC](https://discuss.elastic.co/t/maven-build-problem/4130 "2011-03-19T00:54:31Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![jason](https://avatars.discourse-cdn.com/v4/letter/j/dc4da7/32.png) [@jason](https://discuss.elastic.co/u/jason)\
**Post date:** [March 19, 2011, 12:54am UTC](https://discuss.elastic.co/t/maven-build-problem/4130/1 "2011-03-19T00:54:31Z")

</div>

Hi everybody,

I am not sure what is wrong with my pom.xml file, but I am getting  
the following error when I execute "mvn clean install" from the  
command line.

Project ID: org.elasticsearch:elasticsearch

Reason: Error getting POM for 'org.elasticsearch:elasticsearch' from  
the reposit  
ory: Unable to read local copy of metadata: Cannot read metadata from  
'C:.m2\re  
pository\org\elasticsearch\elasticsearch\0.16.0-SNAPSHOT\maven-  
metadata-sonatype  
-snapshots.xml': expected START\_TAG or END\_TAG not TEXT (position:  
TEXT seen ...  
javadoc\</... @14:30)  
org.elasticsearch:elasticsearch:pom:0.16.0-SNAPSHOT

for project org.elasticsearch:elasticsearch

Here are my dependency and repository for elastic search:

................................... org.elasticsearch elasticsearch 0.16.0-SNAPSHOT 

```
<repositories>
	<repository>
		<id>oss.sonatype.org</id>
		<name>OSS Sonatype</name>
		<releases>
			<enabled>true</enabled>
		</releases>
		<snapshots>
			<enabled>false</enabled>
		</snapshots>
		<url>https://oss.sonatype.org/content/repositories/releases/</url>
	</repository>
	<repository>
		<id>sonatype-snapshots</id>
        <name>Sonatype Snapshots Repository</name>
        <url>http://oss.sonatype.org/content/repositories/snapshots/</

```

url\>  
  
true  
  
  
  
[maven2-repository.dev.java.net](http://maven2-repository.dev.java.net)  
[Java.net](http://Java.net) Repository for Maven  
[http://download.java.net/maven/2/](http://download.java.net/maven/2/)  
default

```
</repositories>

```

Could anyone please help me resolve that error, if you have seen it  
before?

Thank you,  
Eugene.

---

<div class="post-metadata">

**Author:** ![jason](https://avatars.discourse-cdn.com/v4/letter/j/dc4da7/32.png) [@jason](https://discuss.elastic.co/u/jason)\
**Post date:** [March 19, 2011, 1:20am UTC](https://discuss.elastic.co/t/maven-build-problem/4130/2 "2011-03-19T01:20:59Z")

</div>

I found a workaround by removing snapshotVersions tag from "'C:  
.m2\repository\org\elasticsearch\elasticsearch\0.16.0-SNAPSHOT\maven-  
metadata sonatype-snapshots.xml" file. If anyone in this group ever  
runs into that problem, please follow this link:

[http://www.e-programmers.com/63988-maven-build-problem-ldquounable-to-read-local-copy-of-metadatardquo.html](http://www.e-programmers.com/63988-maven-build-problem-ldquounable-to-read-local-copy-of-metadatardquo.html)

I hope it helps. If you know any other solution, please feel free to  
share.

Thanks,  
Eugene.

On Mar 18, 5:54 pm, eugene [efur...@gmail.com](mailto:efur...@gmail.com) wrote:

> Hi everybody,
> 
> I am not sure what is wrong with my pom.xml file, but I am getting  
> the following error when I execute "mvn clean install" from the  
> command line.
> 
> Project ID: org.elasticsearch:elasticsearch
> 
> Reason: Error getting POM for 'org.elasticsearch:elasticsearch' from  
> the reposit  
> ory: Unable to read local copy of metadata: Cannot read metadata from  
> 'C:.m2\re  
> pository\org\elasticsearch\elasticsearch\0.16.0-SNAPSHOT\maven-  
> metadata-sonatype  
> -snapshots.xml': expected START\_TAG or END\_TAG not TEXT (position:  
> TEXT seen ...  
> javadoc\</... @14:30)  
> org.elasticsearch:elasticsearch:pom:0.16.0-SNAPSHOT
> 
> for project org.elasticsearch:elasticsearch
> 
> Here are my dependency and repository for Elasticsearch:
> 
> ................................... org.elasticsearch elasticsearch 0.16.0-SNAPSHOT 
> 
> ```
> <repositories>
> <repository>
> <id>oss.sonatype.org</id>
> <name>OSS Sonatype</name>
> <releases>
> <enabled>true</enabled>
> </releases>
> <snapshots>
> <enabled>false</enabled>
> </snapshots>
> <url>https://oss.sonatype.org/content/repositories/releases/</url>
> </repository>
> <repository>
> <id>sonatype-snapshots</id>
> <name>Sonatype Snapshots Repository</name>
> <url>http://oss.sonatype.org/content/repositories/snapshots/</
> 
> ```
> 
> url\>  
>   
> true  
>   
>   
>   
> [maven2-repository.dev.java.net](http://maven2-repository.dev.java.net)  
> [Java.net](http://Java.net) Repository for Maven  
> [http://download.java.net/maven/2/](http://download.java.net/maven/2/)  
> default
> 
> ```
> </repositories>
> 
> ```
> 
> Could anyone please help me resolve that error, if you have seen it  
> before?
> 
> Thank you,  
> Eugene.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 6, 2017, 4:09am UTC](https://discuss.elastic.co/t/maven-build-problem/4130/3 "2017-07-06T04:09:36Z")

</div>


