The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

php.ini and mail.log file size limit

Discussion in 'General Discussion' started by dzamanakos, Jan 12, 2016.

  1. dzamanakos

    dzamanakos Active Member

    Joined:
    Feb 15, 2014
    Messages:
    25
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    Hi, in order to track scripts that are sending emails through php mail() function, i've read about mail.log directive in php.ini that accepts either a user's home dir file or a path to a server, for example /var/log/php_mail.log

    I'm using suphp so in order to write to a /var/log/php_mail.log i have to set 777 permissions to the file, if i want to have all my users logs to one file. It isn't a good idea for me to use a 777 file.

    The other solution is to use a file like the error_log, inside the users home dir but the problem is that i didnt find any documentation about limiting the file size, so after a while the user's home dir will be over quota.

    Is there a way to limit the file size through php.ini?
    Or any other way to monitor mail() in a file containing all users, but not chmod to 777?

    Thank you,
     
  2. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,854
    Likes Received:
    676
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
Loading...

Share This Page