Defining the SMTP Server

Follow

Set or change the SMTP Server in JAMS:

  1. Start the JAMS Client as an administrator
  2. Click on the Configuration shortcut within the Shortcuts bar.
  3. Enter the name of the desired SMTP server within the SMTP Server configuration setting.
  4. Click the Save and Close button in the Control Bar.
  5. Restart the JAMS Scheduler service to put changes into effect. This will not impact any Jobs in the Schedule, nor any Jobs that are Executing.

Configure Authentication to the SMTP Server:

Users can enable SMTP authentication through two different methods:

  • Editing the JAMSScheduler.exe.config file
    OR
  • Editing the .NET Framework Machine configuration file.

NOTE: Only one of these methods should be utilized in a given environment.

 

Scheduler Configuration

  1. Open the JAMSScheduler.exe.config file, located by default in C:\Program Files\MVPSI\JAMS\Scheduler

  2. Insert the following code directly before the </configuration> tag, edited for the given environment:
      <system.net>
      <mailSettings>
      <smtp deliveryMethod="Network">
      <network defaultCredentials="false" port="25" host="your.host.name.com" userName="me@xyzcom" password="abc123" />
      </smtp>
      </mailSettings>
      </system.net>
  3. The entered information should look similar to the image below
    (image shows code in MS Visual Studio)
    DefiningSMTPUpdatedCode.png
  4. Once complete, restart the JAMS Scheduler service.

 

.NET Configuration

NOTE: SMTP server settings in the .NET Framework Machine.Config file will also apply to all applications on the machine which use the .NET Framework SmtpClient class. (unless overridden)

  1. Open the Machine.config file, located by default in C:\Windows\Microsoft.Net\Framework64\v4.0.30319\Config
  2. Insert the following code directly before the </configuration> tag, edited for the given environment:
      <system.net>
      <mailSettings>
      <smtp deliveryMethod="Network">
      <network defaultCredentials="false" port="25" host="your.host.name.com" userName="me@xyzcom" password="abc123" />
      </smtp>
      </mailSettings>
      </system.net>
  3. The entered information should look similar to the image below
    (image shows code in MS Visual Studio)
    DefiningSMTPUpdatedCode.png
  4. Once complete, restart the machine

 


More information on the .NET Framework Machine configuration can be found here:

https://msdn.microsoft.com/en-us/library/ms164242(v=vs.110).aspx

Have more questions? Submit a request

Comments

  • Avatar
    Rajesh Venkatraman

    office 365 smtp service needs authentication. What is the best method to store the credentials?

  • Avatar
    Gennaro Piccolo

    Hello Rajesh,

    As shown in the example above, the credentials need to be stored in the configuration file.
    They need to reside in the JAMSScheduler.exe.config or in machine.config.
    If those credentials need to be secured, I would limit access to either of those files to specific groups or users in Active Directory so that users cannot access those files specifically. Microsoft does not provide a secure way to store those credentials for authentication to the SMTP server.