Yes, I know the subject has been covered many time but I'm facing a strange behaviour of WSO2EMM.
I'm currently installing WSO2EMM on a Linux CentOS 6.5 and it seems to work correctly.
I configured the EMAIL section in emm/config/config.json, replacing smtp.google.com by smtp.gmail.com, as shown below:
"EMAIL": {
"SMTPHOST": "smtp.gmail.com",
"SMTPPORT": "25",
"USERNAME": "renelco.mobility@gmail.com",
"PASSWORD": mypassword,
"SENDERADDRESS": "hellcat@localhost",
"TEMPLATE": "You have been registered to the WSO2 EMM. Below is the link to enroll."
}
While smtp.gmail.com is working correctly when I test it using telnet, wso2emm is completely unable to send an invite and returns me the following error :
[2014-10-06 18:01:44,689] INFO {JAGGERY.modules.common:js} - New connection was taken [2014-10-06 18:02:01,046] INFO {JAGGERY.modules.user:js} - Email sent to -> pascal.curdy@renelco.com [2014-10-06 18:02:01,094] ERROR {JAGGERY.modules.user:js} - org.mozilla.javascript.WrappedException: Wrapped org.jaggeryjs.scriptengine.exceptions.ScriptException: javax.mail.MessagingException: Unknown SMTP host: smtp.google.com; nested exception is: java.net.UnknownHostException: smtp.google.com (/emm/modules/user.js#883) at org.mozilla.javascript.Context.throwAsScriptRuntimeEx(Context.java:1754) at org.mozilla.javascript.MemberBox.invoke(MemberBox.java:148) at org.mozilla.javascript.FunctionObject.call(FunctionObject.java:449) at org.mozilla.javascript.optimizer.OptRuntime.callProp0(OptRuntime.java:85) at org.jaggeryjs.rhino.emm.modules.c7._c_anonymous_38(/emm/modules/user.js:883) at org.jaggeryjs.rhino.emm.modules.c7.call(/emm/modules/user.js) at org.mozilla.javascript.optimizer.OptRuntime.call1(OptRuntime.java:32) at org.jaggeryjs.rhino.emm.api.c0._c_anonymous_17(/emm/api/userRouter.js:192) at org.jaggeryjs.rhino.emm.api.c0.call(/emm/api/userRouter.js) at org.mozilla.javascript.optimizer.OptRuntime.call1(OptRuntime.java:32) at org.jaggeryjs.rhino.emm.modules.c5._c_anonymous_13(/emm/modules/goose.js:174) at org.jaggeryjs.rhino.emm.modules.c5.call(/emm/modules/goose.js) at org.mozilla.javascript.optimizer.OptRuntime.call1(OptRuntime.java:32) at org.jaggeryjs.rhino.emm.modules.c3._c_callAPI_12(/emm/modules/absolute.js:171) at org.jaggeryjs.rhino.emm.modules.c3.call(/emm/modules/absolute.js)
etc, etc ...
Actually, the server doesn't seem to care about the SMTPHOST parameter defined in config.json.
I searched into the file system to see if smtp.google.com was referenced somewhere else, but found nothing.
I performed a hardware reset of my server, but without any effect.
What's wrong with this, did I missed something in the installation guide ?
Thanks in advance for your help.
I just discover what may cause my problems. When I open the emm web console and click Configurations->Settings I have the following settings:
![WSO2EMM Web Console- Configuration][1]
with Host set as smtp.gmail.com
Now, if I open the file emm/config/config.json, I have the following setting: ![WSO2EMM config.json][2]
You can see that the SMTPHOST parameter is set to smtp.google.com which is unknown host.
My question is: Why is there a difference between what I can see in the web console and what I have in config.json ?
Could you tell me where are stored the information entered from the web console ?
Setting smtp.gmail.com from the web console solved my problem ...
Unfortunately, you'll have to read this without the screenshots. Too bad I have not enough good reputation to post images (damned stupid ...)