title: mvn deploy snapshot to nexus oss failed with return code 500 internal error
body: <p>I use maven to deploy artifact to sonatype nexus,I can perform release action normally,but deploy snapshots failed.</p>
  
  <ul>
  <li>sonatype nexus 2.7.0.5</li>
  <li>Java 1.7</li>
  <li><p>maven 3.0.5</p>
  
  <ol>
  <li>mvn release:prepare;mvn release:perform; successful without any error</li>
  <li>mvn deploy failed with return code 500</li>
  </ol></li>
  </ul>
  
  <pre><code>[INFO] maven-jar-plugin:2.4:jar (default-jar) @ licm 
  [INFO] Building jar: /foo/licm/trunk/target/licm-0.2.9-SNAPSHOT.jar
  [INFO]
  [INFO] maven-install-plugin:2.3.1:install (default-install) @ licm
  [INFO] Installing /foo/licm/trunk/target/licm-0.2.9-SNAPSHOT.jar to /foo/.m2/repository/com/xxx/utils/licm/0.2.9-SNAPSHOT/licm-0.2.9-SNAPSHOT.jar
  [INFO] Installing /foo/licm/trunk/pom.xml to /foo/.m2/repository/com/xxx/utils/licm/0.2.9-SNAPSHOT/licm-0.2.9-SNAPSHOT.pom
  [INFO]
  [INFO] --- maven-deploy-plugin:2.8.1:deploy (default-deploy) @ licm ---
  Downloading: http://xxx.xxx.com:8080/nexus/content/repositories/snapshots/com/xxx/utils/licm/0.2.9-SNAPSHOT/maven-metadata.xml
      [WARNING] Could not transfer metadata com.xxx.utils:licm:0.2.9-SNAPSHOT/maven-metadata.xml 
  from/to Snapshots (http://xxx.xxx.com:8080/nexus/content/repositories/snapshots): Failed to transfer file:
   http://xxx.xxx.com:8080/nexus/content/repositories/snapshots/com/xxx/utils/licm/0.2.9-SNAPSHOT/
  maven-metadata.xml. Return code is: 500 , ReasonPhrase:Internal Server Error.
  
  [INFO] ------------------------------------------------------------------------
  [INFO] BUILD FAILURE
  [INFO] ------------------------------------------------------------------------
  [INFO] Total time: 1.824s
  [INFO] Finished at: Fri Dec 20 01:20:33 CST 2013
  [INFO] Final Memory: 8M/20M
  [INFO] ------------------------------------------------------------------------
  [ERROR] Failed to execute goal org.apache.maven.plugins:maven-deploy-plugin:2.8.1:deploy (default-deploy) on project licm: Failed to retrieve remote metadata com.xxx.utils:licm:0.2.9-SNAPSHOT/maven-metadata.xml: Could not transfer metadata com.xxx.utils:licm:0.2.9-SNAPSHOT/maven-metadata.xml from/to Snapshots (http://xxx.xxx.com:8080/nexus/content/repositories/snapshots): Failed to transfer file: http://xxx.xxx.com:8080/nexus/content/repositories/snapshots/com/xxx/utils/licm/0.2.9-SNAPSHOT/maven-metadata.xml. Return code is: 500 , ReasonPhrase:Internal Server Error. -&gt; [Help 1]"
  </code></pre>
  
  <p>This is my first time to deploy snapshots to remote repository,so there have nothing in snapshot repository on nexus server </p>
  
  <ul>
  <li>settings.xml</li>
  </ul>
  
  <pre class="lang-xml prettyprint-override"><code>   &lt;?xml version="1.0"?&gt;
  &lt;settings&gt;
  &lt;servers&gt;
  &lt;server&gt;
          &lt;id&gt;Releases&lt;/id&gt;
          &lt;username&gt;admin&lt;/username&gt;
          &lt;password&gt;admin123&lt;/password&gt;
  
  &lt;/server&gt;
  &lt;server&gt;
          &lt;id&gt;Snapshots&lt;/id&gt;
          &lt;username&gt;admin&lt;/username&gt;
          &lt;password&gt;admin123&lt;/password&gt;
  &lt;/server&gt;
  &lt;/servers&gt;
  &lt;mirrors&gt;
  &lt;mirror&gt;
          &lt;id&gt;Nexus&lt;/id&gt;
          &lt;name&gt;Nexus Public Mirror&lt;/name&gt;
          &lt;url&gt;http://xxx.xxx.com:8080/nexus/content/groups/public&lt;/url&gt;
          &lt;mirrorOf&gt;*&lt;/mirrorOf&gt;
  &lt;/mirror&gt;
  
  &lt;/mirrors&gt;
  &lt;/settings&gt;
  </code></pre>
  
  <ul>
  <li>pom.xml</li>
  </ul>
  
   <pre class="lang-xml prettyprint-override"><code>&lt;distributionManagement&gt;
      &lt;repository&gt;
        &lt;id&gt;Releases&lt;/id&gt;
        &lt;name&gt;xxx Releases Repositories&lt;/name&gt;
        &lt;url&gt;http://xxx.xxx.com:8080/nexus/content/repositories/releases&lt;/url&gt;
      &lt;/repository&gt;
      &lt;snapshotRepository&gt;
        &lt;id&gt;Snapshots&lt;/id&gt;
        &lt;name&gt;xxx Snapshots Repositories&lt;/name&gt;
        &lt;url&gt;http://xxx.xxx.com:8080/nexus/content/repositories/snapshots&lt;/url&gt;
      &lt;/snapshotRepository&gt;
    &lt;/distributionManagement&gt;
  </code></pre>