WARNING The requested profile "projectname" could not be activated because it does not exist

benskiiii picture benskiiii · Jul 12, 2013 · Viewed 45.9k times · Source

I get this WARNING when I try to build my maven project. I have searched google but with no luck. This is really annoying since I wanna release my project but it wont work with this warning (I think). The build is successful, but when I try to deploy the war file it doesen't work (no error message). The only warning I can find when I build the project is this:

[WARNING] The requested profile "projectname" could not be activated because it does not exist.

Answer

user3296624 picture user3296624 · Jun 4, 2014

This happens when you have the following in your settings.xml (in your .m2 directory), and no profile with the id projectname.

<activeProfiles>
  <activeProfile>projectname</activeProfile>
</activeProfiles>