---
title: "myeclipse中tomcat里部署，发生“Undefined exploded archive location”问题"
author: "macrabbit"
date: "2011-06-24T14:40:02Z"
tags: []
categories: ["企业架构"]
slug: "myeclipse-tomcat-undefined-exploded-archive-location"
draft: false
lastmod: "2011-06-24T14:40:02Z"
id: 1103722
url: "https://macrabbit.iteye.com/blog/1103722"
---

解决方法：  
  1.在工程目录下的.mymetadata文件中可能webrootdir被改无效了(把下面内容拷到你的.mymetadate文件中的相应位置上)；或者有可能少了这context-root这个属性；添加上这个属性即可，内容如下：  
  context-root="/project name"  
  2.关掉Eclipse，再启动Eclipse，接着发布工程，发布成功！

.mymetadata文件  
&lt;?xml version="1.0" encoding="UTF-8"?&gt;  
&lt;project-module  
  type="WEB"  
  name="myweb"  
  id="myeclipse.1202968712015"  
 context-root="/yourproject" j2ee-spec="1.4"  
  archive="personnel.war"&gt;  
  &lt;attributes&gt;  
  &lt;attribute name="webrootdir" value="WebRoot" /&gt;  
  &lt;/attributes&gt;  
&lt;/project-module&gt;