logrotate执行切割的时候出现because parent directory has insecure permissions (It's world writable or writable by group which is not "root") Set "su" directive in config file to tell logrotate which user/group should be used for rotation错误的解决办法

作者在 2019-06-03 17:46:14 发布以下内容

vi /etc/logrotate.d/down.bccn.net


/var/sitepath/log/host.access.log{
    su root list
    missingok
    notifempty
    compress
    olddir /var/sitepath/log/access/
    daily
    copytruncate
    rotate 30
}

/var/sitepath/log/error.log{
    su root list
    missingok
    notifempty
    compress
    olddir /var/sitepath/log/error/
    daily
    copytruncate
    rotate 30
}
Linux | 阅读 4969 次
文章评论,共0条
游客请输入验证码
浏览2797439次
文章归档