Accepted answer

in eclipse you need to go like this.

window-> preference -> java -> installed jres -> edit

in the edit default vm arguments you need to put

if you already set the maven home.



i had the same problem with intellij 14, i tried out different solutions provided at forums but not worked out. what i did is i completely uninstall intellij and installed intellij 15.0.1 and import the same project then all works fine.


to set the maven.multimoduleprojectdirectory property permanently in maven, i've added a default activated profile which initializes the property with the maven_home environment variable in the settings.xml file. or you could also alternatively use the m2_home environment variable.



if you want to try a second way, you can try to download a path from

open help>install new software and download from url above. this way solved my problem.


i encountered the same issue with maven 3.3 and 3.2 versions, so i decided to downgrade it to version 3.0.5 and it worked just fine.


go to run configuration, create new maven build launch configuration where in the first tab you fill the base directory and the goal, then, go to jre tab and add to the vm args this config:


where m2_home is an environment variable pointing to the base directory of your maven installation


in case you have this error message on your commandline, please verify if your path variable points to the same maven installation apache-maven-3.x.x/bin folder as your m2_home variable. in my case i was mixing up two versions which resulted in this error.


define like this in the jvm options:



this was filed as a bug with m2e in eclipse at , due to the changes in maven 3.3.1.

this is fixed in m2e 1.5.2 as of 2015-04-13. this is an available release that can be installed from .

(no more changing jvm arguments for the entire workspace or for specific launch configurations required.)


in intellij you can set this option in vm options field that you can find in the next configuration view:

preferences/build, execution, deployment/build tools/maven/runner

enter image description here

Related Query

More Query from same tag