SMTP Server with non-default port configuration

How do I configure TFS and SharePoint Services to use SMTP server with non-default port I tried setting server name to mail.mydomain.com:587, but it does not seem to work. Is it possible at all

Answer this question

SMTP Server with non-default port configuration

  • rxg

    Hi Alex,

    A potential workaround is to specify the port # in <system.net>/<mailSettings> in c:Program Files\Microsoft Visual Studio 2005 Team Foundation Server\Web Services\Services\web.config

    See:

    http://msdn2.microsoft.com/en-us/library/ms164242.aspx

    Could you give that a try

    Thanks,

    - Patrick



  • George Clingerman

    That's good.  I am not an expert in Sharepoint, but found this on the technet.  Hope it will be useful.

     http://www.microsoft.com/technet/prodtechnol/sppt/sharepnt/proddocs/admindoc/owsf01.mspx mfr=true



  • DominicPukallus

    Hi Alex,

    Were you able to find a solution for this

    -Matt



  • Squiddy

    Patrick,

    Thanks, it worked.

    Next is how to configure SharePoint for non-default SMTP port

    Alex


  • Gobi N

    Anyone I need an answer on this one.
  • zion99

    Matt, no, I was not.
  • FPSt

    hey..good question..please do the following steps..

    To configure the Team Foundation Alerts....

    <Drive>:\Program Files\Microsoft Visual Studio 2005 Team Foundation Server\Web Services\Services

    locate web.config and add the following,

    <add key="emailNotificationFromAddress" value="someone@onetouch.com" />
    <add key="smtpServer" value="<IP address of the SMTP server>" />

    and save the config file and reset the IIS.

    To configure Sharepoint Alerts.

    Start -> Administrative Tools -> Share point Central administration -> Server Administration --> Configure default e-mail server settings

    In this Give the <IP address of the SMTP server> for both Outgoing and incoming SMTP server name..and say ok. unicode let it default..

    Then check for the alerts...

    Hope this helps.

    Thanks, Kathir


  • Tarin

    i am sorry yaar...u r correct...the SMTP default port will be 25...correct...if you want to use 587 means..i think you can open the firewall connection for the same ..and use the same...check out.


  • ianpender

    There is no direct way to configure the SMTP server port. The value that you specify in the web.config file for the smtpServer is passed directly to the System.Net.Mail.SmtpClient constructor. While it is possible to use a form of the constructor that takes both the SMTP server name and port, that is not what we do in V1. We have a change request tracking the need for explicit control over the port in a future version.

    A workaround is to leverage IIS SMTP service on the TFS AT as a relay server. You would set up the TFS AT as a an SMTP server on the default port and then have it send mail to your "real" SMTP server. Please see: http://technet2.microsoft.com/WindowsServer/en/library/8ffae10b-01ac-45ad-ab5f-1006b73a68dd1033.mspx mfr=true.


  • xishan shigri

    Hi Alex, you may be able to create a forwarderer on the server to the right port.

    I think the standard V1 environment hardcodes the port, but I hope i'm wrong.

    I'll look into this a bit more for you.

    Thanks,

    John


  • Zach Longren

    Kathir,

    You missed the question. I needto configure SMTP server with non-default port (587 instead of 25).


  • SMTP Server with non-default port configuration