Welcome Email to FBA Users

We are using FBA pack for SharePoint 2013 Foundation and now we don't see Welcome Email going out to user when we create user. When we add permission to user Welcome Email doesnt goes out.


Any ideas??
It likely has to do with your email setup. Make sure that outgoing mail is setup properly in SharePoint. Another common issue is that the email is going to external email addresses (gmail.com, hotmail.com...) and SharePoint hasn't been given permissions to relay through the smtp server.

If the email settings are setup properly in SharePoint, any errors the smtp server returns (can't relay etc...) will be in your SharePoint log file.
Thank you for the reply. Here Telnet test works fine. If you set up an alert for user that also works. Only welcome Email fails.
When we check SQL database we see user created with Email address. In inetpub folder we dont see any activity of Email being sent by SharePoint. In Logs we do see errors like some ". " character missing.
There won't be anything related to the email in inetpub. In your SharePoint logs there should be a relevant error message - search it for "fba" and there should be lines that show the actual email sending exception message.
Hi,
Thanks for the info.
Below is what we see in the Log, This happens with every FBA site.Welcome Email doesn't goes out. If we use site using NTLM authetication Welcome Email goes out for Windows User.

PRequest.SendMail: UserPrincipalName=i:0#.f|mp|admin, AppPrincipalName= ,bstrUrl=http://wwwinvest.com ,bstrFrom=no-reply@.dataon.net ,bstrTo=dhasal@gmail.com ,bstrSubject=Welcome ,bstrContentType=text/html ,bstrCc=<null> ,bstrBcc=<null> ,bIncludeFooter=False ,bstrHTMLBody=Test 30235b9c-1b54-10d4-af91-5c99ab95a0bf
11/28/2013 13:43:54.40 w3wp.exe (0x658C) 0x4BD8 SharePoint Foundation General ai1wu Medium System.Runtime.InteropServices.COMException: Cannot complete this action. Please try again., StackTrace: at Microsoft.SharePoint.Utilities.SPUtility.SendEmail(SPWeb web, StringDictionary messageHeaders, String messageBody, Boolean appendFooter) at Visigo.Sharepoint.FormsBasedAuthentication.UserNew.OnSubmit(Object sender, EventArgs e) at System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) at System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) at System.Web.UI.Page.ProcessRequest() at System.Web.UI.Page.ProcessRequest(HttpContext context) at System.Web.HttpApplicat... 30235b9c-1b54-10d4-af91-5c99ab95a0bf
11/28/2013 13:43:54.40* w3wp.exe (0x658C) 0x4BD8 SharePoint Foundation General ai1wu Medium ...ion.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) at System.Web.HttpApplication.PipelineStepManager.ResumeSteps(Exception error) at System.Web.HttpApplication.BeginProcessRequestNotification(HttpContext context, AsyncCallback cb) at System.Web.HttpRuntime.ProcessRequestNotificationPrivate(IIS7WorkerRequest wr, HttpContext context) at System.Web.Hosting.PipelineRuntime.ProcessRequestNotificationHelper(IntPtr rootedObjectsPointer, IntPtr nativeRequestContext, IntPtr moduleData, Int32 flags) at System.Web.Hosting.PipelineRuntime.ProcessRequestNotification(IntPtr rootedObjectsPointer, IntPtr nativeRequestContext, IntPtr moduleData, Int32 flags) ... 30235b9c-1b54-10d4-af91-5c99ab95a0bf
11/28/2013 13:43:54.40* w3wp.exe (0x658C) 0x4BD8 SharePoint Foundation General ai1wu Medium ... at System.Web.Hosting.UnsafeIISMethods.MgdIndicateCompletion(IntPtr pHandler, RequestNotificationStatus& notificationStatus) at System.Web.Hosting.UnsafeIISMethods.MgdIndicateCompletion(IntPtr pHandler, RequestNotificationStatus& notificationStatus) at System.Web.Hosting.PipelineRuntime.ProcessRequestNotificationHelper(IntPtr rootedObjectsPointer, IntPtr nativeRequestContext, IntPtr moduleData, Int32 flags) at System.Web.Hosting.PipelineRuntime.ProcessRequestNotification(IntPtr rootedObjectsPointer, IntPtr nativeRequestContext, IntPtr moduleData, Int32 flags) 30235b9c-1b54-10d4-af91-5c99ab95a0bf
11/28/2013 13:43:54.40 w3wp.exe (0x658C) 0x4BD8 SharePoint Foundation General ajrjd High SPUtility.SendEmail: Unmanaged SPRequest.SendMail failed 30235b9c-1b54-10d4-af91-5c99ab95a0bf
11/28/2013 13:43:54.46 w3wp.exe (0x658C) 0x4BD8 SharePoint Foundation Topology ahg9p High [Forced due to logging gap, cached @ 11/28/2013 13:43:54.43, Original Level: Verbose] Completed deserializing the type named {0} and with id {1}. 30235b9c-1b54-10d4-af91-5c99ab95a0bf
11/28/2013 13:43:54.46 w3wp.exe (0x658C) 0x4BD8 SharePoint Foundation Database 8acb High [Forced due to logging gap, Original Level: VerboseEx] Reverting to process identity 30235b9c-1b54-10d4-af91-5c99ab95a0bf
I can't say i've seen this before. According to the error message, SharePoint's SendEmail method is crashing - but it doesn't say why. You mention it works if you're logged in as a windows user - so maybe it's some type of permission issue.

When it crashes is the web part on an standard SharePoint page in a document library with anonymous access turned on and nobody logged in? Or are you using an Application Page set to allow anonymous access?
There is an update on this. We set this up on new Server Farm where it works. Welcome Emails are being sent correctly on new Server.
Password Reset Email also coming through. Can you provide any recommendation to stop crash of "Send Email method?

We are trying to add some more resources on Server to see if this can make any difference. Any suggestions in this would be greatly appreciated.

Thanks!
The crash is probably from some misconfiguration in SharePoint, but could be a windows issue too, given the comexception - it could be that whatever SendEmail is calling is crashing.

I'd probably try and narrow down under what circumstances it crashes. You mention it works if you're a logged in windows user, which to me points to some type of permission issue. Maybe also try creating a new SharePoint web application on the server and see if it works under the different web application, or if you experience the same thing.

Another thing you can maybe try is turning on logging on the smtp server, and see if any connection attempt is made/see how far it gets before it dies. That might also offer you a clue to what is happening.