Forum Discussion

Bryan_A's avatar
Bryan_A
Icon for Altostratus rankAltostratus
Oct 15, 2014

LTM 11.5 how to change ssmtp root email destination

Hello, We have LTM v11.5.0 and would like to change the destination for root's email. I found a solution for v10.x that would allow you to edit /etc/aliases, but my understanding is that ssmtp (which is used in v11) does not read this file. I was tempted to change the "root=postmaster" line in /etc/ssmtp/ssmtp.conf but I wasn't sure if that was supported/would persist since typically you would want to change this kind of parameter with a "tmsh modify sys" command. Thanks for any guidance.

 

4 Replies

  • Hey Bryan. I'm not aware of a tmsh command. As far as I know; to configure email delivery of alerts edit the /etc/ssmtp/ssmtp.conf file and enter the hostname or IP address of a suitable SMTP server as the mailhub= variable value.

     

  • Thanks for the replies. I've got the smtp server set and that is working fine but the issue is that email destined for "root" is being sent to "postmaster@hostname". I'm looking for the equivalent functionality that is achieved by editing the /etc/aliases file and changing the "root: " line. It seems odd to need an iRule to do this, and looking at it, I don't think it's what I'm looking for.

     

  • Hello All,

     

    ;). Just put some magic in the alias file like this:

     

    echo "root:root.host1@example.com:smtp.example.com" >> /etc/ssmtp/revaliases

     

    and test it with

     

    echo "ssmtp test mail" | mail -vs "Lalalal this is my lalala song" someEmail@example.com