Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

Custom exim_mainlog for certain domains

Discussion in 'E-mail Discussion' started by sh4ka, Jan 26, 2009.

  1. sh4ka

    sh4ka Well-Known Member

    Joined:
    May 12, 2005
    Messages:
    444
    Likes Received:
    0
    Trophy Points:
    166
    Location:
    Uruguay
    cPanel Access Level:
    DataCenter Provider
    Hello,

    I was wondering... is there a way, or is it possible to set a custom exim_mainlog that logs incoming and outgoing emails, only for certain domains? (not all domains, as the exim_mainlog works actually in cPanel servers).

    Such as.. /var/log/domain.com_exim_mainlog

    Thanks.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  2. sh4ka

    sh4ka Well-Known Member

    Joined:
    May 12, 2005
    Messages:
    444
    Likes Received:
    0
    Trophy Points:
    166
    Location:
    Uruguay
    cPanel Access Level:
    DataCenter Provider
    Any ideas please?
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  3. Alejandro P

    Alejandro P Well-Known Member

    Joined:
    Apr 6, 2007
    Messages:
    51
    Likes Received:
    0
    Trophy Points:
    156
    cPanel Access Level:
    Root Administrator
    You might do this by batch processing over the exim logs, something like this

    $mydomain = 'xdomain.com';
    $date = '2009-01-26';
    foreach(qx(grep $mydomain /var/log/exim_mainlog|grep $date|/bin/awk '{print \$3}' )) {
    chomp;
    $localips{$_} = $_;
    print qx(grep $_ /var/log/exim_mainlog );
    print $_."\n";
    }
     
Loading...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice