• File system permissions for log files on Debian Apache 2.4

    From Isaac Puch Rojo@21:1/5 to All on Thu Nov 10 02:23:54 2016
    It is a way to tell apache with file permision sould have the logs?

    I have the php-log here: /var/log/php/phperror.log If this file don't exist, apache will be create one with root.root and 644 permisions. The PHP-scripts can't write to this file. I need www-data.www-data and 640.

    What is the best practices mode to do it?

    Regards,
    Isaac Puch

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From I R A Darth Aggie@21:1/5 to 8d64a18e-d314-4ca5-8e07-1a3963e2b32 on Tue Nov 22 17:28:19 2016
    On Thu, 10 Nov 2016 02:23:54 -0800 (PST),
    Isaac Puch Rojo <puchrojo@gmail.com>, in <8d64a18e-d314-4ca5-8e07-1a3963e2b32e@googlegroups.com> wrote:
    It is a way to tell apache with file permision sould have the logs?

    I have the php-log here: /var/log/php/phperror.log If this file
    don't exist, apache will be create one with root.root and 644
    permisions. The PHP-scripts can't write to this file. I need
    www-data.www-data and 640.

    What is the best practices mode to do it?

    I would create an entry in /etc/lograte.d for php-log, probably just
    copy the apache2 file as a basis, and then change

    create 640 root adm
    to
    create 640 www-data www-data

    then manually create your error log with the appropriate
    permissions. Tho you may not need/want the pre and post rotate
    sections. Then you'll get rotating logs, and accesible permissions for
    php-log.

    --
    Consulting Minister for Consultants, DNRC
    I can please only one person per day. Today is not your day. Tomorrow
    isn't looking good, either.
    I am BOFH. Resistance is futile. Your network will be assimilated.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From kienzlebrian3@gmail.com@21:1/5 to Isaac Puch Rojo on Sat May 5 09:05:06 2018
    On Thursday, November 10, 2016 at 2:23:55 AM UTC-8, Isaac Puch Rojo wrote:
    It is a way to tell apache with file permision sould have the logs?

    I have the php-log here: /var/log/php/phperror.log If this file don't exist, apache will be create one with root.root and 644 permisions. The PHP-scripts can't write to this file. I need www-data.www-data and 640.

    What is the best practices mode to do it?

    Regards,
    Isaac Puch



    On Thursday, November 10, 2016 at 2:23:55 AM UTC-8, Isaac Puch Rojo wrote:
    It is a way to tell apache with file permision sould have the logs?

    I have the php-log here: /var/log/php/phperror.log If this file don't exist, apache will be create one with root.root and 644 permisions. The PHP-scripts can't write to this file. I need www-data.www-data and 640.

    What is the best practices mode to do it?

    Regards,
    Isaac Puch




    On Thursday, November 10, 2016 at 2:23:55 AM UTC-8, Isaac Puch Rojo wrote:
    It is a way to tell apache with file permision sould have the logs?

    I have the php-log here: /var/log/php/phperror.log If this file don't exist, apache will be create one with root.root and 644 permisions. The PHP-scripts can't write to this file. I need www-data.www-data and 640.

    What is the best practices mode to do it?

    Regards,
    Isaac Puch

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From friend.seocompany@gmail.com@21:1/5 to Isaac Puch Rojo on Sun Jun 17 20:04:41 2018
    On Thursday, November 10, 2016 at 2:23:55 AM UTC-8, Isaac Puch Rojo wrote:
    It is a way to tell apache with file permision sould have the logs?

    I have the php-log here: /var/log/php/phperror.log If this file don't exist, apache will be create one with root.root and 644 permisions. The PHP-scripts can't write to this file. I need www-data.www-data and 640.

    What is the best practices mode to do it?

    Regards,
    Isaac Puch

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)