The tag has no usage guidance.

learn more… | top users | synonyms

0
votes
1answer
33 views

Nginx Log Rotation Doesn't Seem to Be Working Correctly

I discovered that my partition mounted as /var had filled up. In tracking down the disk usage, I found that my Nginx log file is huge, and it doesn't seem to be writing to the correct file. ls -ltr ...
0
votes
0answers
39 views

logrotate works when run manually, doesn't when run with cron

This is on Ubuntu Server 14.04, but I think it's applicable to all OSes. I'm running logrotate as a cron job, cron settings are the defaults (logrotate exists in /etc/cron.daily). I'm running a ...
-1
votes
1answer
29 views

logrotate : size mentioned 2000M in connf still logs size is more than 2000M

My /etc/logrotate.conf : # see "man logrotate" for details # rotate log files weekly weekly # keep 4 weeks worth of backlogs rotate 4 # create new (empty) log files after rotating old ones create ...
1
vote
1answer
41 views

log compression using logrotate

I was trying to set compression for jboss log files. The log files I want to compress are console.log and server.log. Compression for console.log is working fine, but server.log I am seeing issues. I ...
1
vote
2answers
79 views

logrotate not working

I want to set up daily logrotate for my Tomcat server' catalina.out log file but it's not working - I haven't seen the rotated log files created. To troubleshoot, I ran logrotate -d ...
1
vote
1answer
62 views

logrotate fails to rotate logs: error setting owner

Recently I've noticed that logrotate does not rotate my logs. user1@host:~$ /usr/sbin/logrotate /home/user1/logrotate.conf -v gives me an error: error: error setting owner of /home/logs/mylog.log.1 ...
1
vote
1answer
28 views

handle large number of same log using cron or logrotate

We have an app deployed in a server, which, under some scenarios, generates some logs in the below format. process_name.hostname.common_text.log.{error/info/warning}.date.time Now, due to this ...
2
votes
1answer
24 views

What is the most recent log file in logrotate utility

I have multiple log files abc-log,abc-log.1, and abc-log.2 rotated by logrotate utility. Among these rotated log files which is the log file which contains the recent logs? Is it abc-log or abc-log.1? ...
0
votes
1answer
59 views

logrotate doesn't respect rotate parameter

I've been having some trouble with logrotate, it seemingly does not do what I'm telling it to do. Environment: Centos 6.4 logrotate 3.7.8 My /etc/logrotate.conf file has the following: # rotate ...
0
votes
0answers
25 views

is it possible to increase the xorg log backup level in ubuntu?

I thought it was 3 before. But right now it only keeps Xorg.0.log and Xorg.0.log.old. Can I increase it to 10 or some other value? It seems the logrotate does not affect the Xorg.0.log at all. ...
0
votes
1answer
28 views

Logrotate: Message in log configuration file for rotation

I am trying to make a configuration file for rotation in /etc/logrotate.d/ I did this: sudo cat > service /var/log/service/service.log { rotate 6 compress size=120M missingok create 0777 ...
1
vote
0answers
23 views

What is the max value of the rotate parameter of a logrotate configuration file?

I would just like to make sure I can put in a relatively large value like 730 for two years without having something unexpected happen.
2
votes
3answers
519 views

how to implement logrotate in shell script

test.sh #!/bin/bash echo "Hello World" test2.sh #!/bin/bash while true do sh test.sh >> /script_logs/test.log & done I want to implement logrotate to control the log file size, so ...
0
votes
1answer
92 views

Delete files only with logrotate

I have an application which rotates its own log files on an hourly basis. Each hour I want to remove all of the files more then n days old. I have to use logrotate to do this because of business ...
0
votes
0answers
62 views

After logrotate my tomcat logs all all zero

I've a problem rotating my tomcat logs. I've the following logrotate-file for tomcat8 (/etc/logrotate.d/tomcat8): /var/log/tomcat8/catalina.out { copytruncate weekly rotate 8 compress ...
0
votes
1answer
29 views

logrotate create group not working

cat /etc/issue Welcome to SUSE Linux Enterprise Server 11 SP1 for VMware (x86_64) - Kernel \r (\l). rpm -qf /etc/logrotate.conf logrotate-3.7.7-10.22 tail -n15 /etc/logrotate.d/syslog ...
0
votes
1answer
72 views

logrotate not compressing files as expected

With the logrotate config. below I was expecting the program to start compressing log files after creating the first backup file. Instead I am seeing this: [root@host ~]# ll /var/log total 1.2M ...
0
votes
2answers
134 views

Troubleshooting Logrotate

The Problem I have several identical servers all running identical logrotate configurations rotating a custom log file. On at least one of the servers my logs are not getting rotated correctly. I ...
1
vote
1answer
124 views

Rotating catalina.out with timestamp format using logrotate. like catalina.$date.out

I am using logrotate to rotate catalina.out, but after rotation the filename is like catalina.out.1.gz. I want it to rotate the file with a timestamp in its name, like: ...
0
votes
0answers
24 views

Move files that are 7 days or older, cronjob [duplicate]

I want to move some log files that are 7 days or older to another folder and then delete those files after another week. I'm using logrotate to create a new log file every 2 hours in a folder. I ...
1
vote
1answer
249 views

logrotate every 2 hours

I'm trying to make httpry logs every 2 hours. I added this to my logrotate.conf file: /var/log/httpry/*.log { rotate 1 weekly create 640 root admin missingok notifempty } I ...
0
votes
1answer
193 views

Run logrotate as specific user

I am using log rotate to rotate logs for a daemon I have running (A web service). The log rotate is as follows: /var/log/deamon/error.log { daily rotate 20 compress delaycompress ...
1
vote
0answers
98 views

logadm permission issue in Solaris

Facing the following issue in a solaris box while using logadm tool . It is showing me permission denied error . -> logadm -w princelog /html/web/www.log -C 3 -s 500m -z 0 logadm: Error: ...
1
vote
1answer
555 views

What is rotating Tomcat log files?

One of our servers has Alfresco installed, and this is the content of /opt/alfresco/tomcat/logs: -rw-r--r-- 1 root root 4.1K Jun 29 10:41 catalina.2015-06-29.log -rw-r--r-- 1 root root 352 Jul 1 ...
1
vote
1answer
82 views

logrotate :: How to delete old logs in a logfile after logfile size reaches 1M size

How can I keep log file size limited to 1M? I want to delete old log entries in a log file after log file size reaches 1M size. I do not want to delete the log file itself.
2
votes
3answers
1k views

nginx logrotate error on cron job

I'm running Ubuntu 14.04 LTS and nginx on a Digital Ocean VPS and occasionally receive these emails about a failed cron job: Subject Cron test -x /usr/sbin/anacron || ( cd / && run-parts ...
0
votes
1answer
28 views

Longer term logrotate

Does anyone know what the config would be for keeping log files for 8 months but compressing them every day? I got this: /500Gb/wireshark/log/* { rotate 240 daily size 1000M ...
-1
votes
1answer
121 views

Who was the original author of logrotate and what year was it written?

The question started as an internal team debate. But we realized we couldn't find any information about when the original version of logrotate was authored and who wrote it.Do you have idea?
2
votes
0answers
242 views

Logrotate archive old log files which has date extention

Everyday a log file is created in my directory. But with time, there tend to be a lot of log files. I want to keep the latest 4 log files in .log format, and compress the rest and copy the compressed ...
2
votes
1answer
432 views

Why does logrotate zip a file before it is closed

I'm using logrotate to rotate mysql output. When cron runs logrotate, I get frequently get an e-mail with the following content: error: Compressing program wrote following message to stderr when ...
0
votes
0answers
27 views

logrotate logs in special dir format

I have my log file in this format in /var/log//YYYYMMDD/app[1-5].log I would like the following: On the 3rd of each month, move the directory /var/log//YYYYMMDD where MM is the previous month to ...
0
votes
0answers
134 views

Rsyslog logs retransmitted after log rotation

I have config setup on all my CentOS servers to forward all syslog messages to a Graylog server via rsyslog. In Graylog I have then configured streams to alert on the occurrence of certain message ...
1
vote
1answer
118 views

Create new syslog file on boot

I want to create a new syslog file each time the system boots and save the old data in another file so that I can detect abnormal behavior on the current boot if any. Is there any configuration for ...
0
votes
1answer
667 views

OpenVPN client log not `logrotate`ing as expected

summary: I want to keep an OpenVPN client's main log from filling its filesystem, but I also need to keep a fairly high debug level (at least for now). My attempt to logrotate is currently not ...
1
vote
1answer
356 views

What exactly does logrotate do to apache log files? (apache 2.4 - ubuntu 14.04)

Other than a couple of basic VHOST's, I have default apache and apache logging configuration. Whenever I try to view my apache log files (error.log, access.log) I see that these files keep getting ...
2
votes
1answer
656 views

SELinux + logrotate + prerotate = Permission Denied

I have what (should) be a fairly straightforward task: Migrate a set of custom log files to a database at night. I use logrotate (cron.daily) with a simple prerotate task /var/log/myapplog/*.log { ...
1
vote
1answer
229 views

Logrotate: scp rotated file to different location

I have a log file, which is supposed to rotate after reaching a particular size (say 50MB). After the rotation, it should be compressed and date has to be appended to the rotated file name. Now, the ...
1
vote
2answers
623 views

Logrotate: Log file not being rotated

I am trying to rotate a log file using logrorate. Following is the configuration: /etc/logrotate.conf: /var/log/test.log { size 1M rotate 6 create dateext ...
0
votes
1answer
597 views

Logrotate files with timestamps in the names

Seems like it should work: "/usr/local/tomcat/logs/" { daily compress delaycompress copytruncate rotate 1 prerotate /usr/bin/find /usr/local/tomcat/logs/ -name stupidLogWithTimestamp* -size -10k ...
1
vote
0answers
86 views

Logrotate or scripting to manipulate log file

I want to make sure that a certain log file gets empty when it reaches a specific size. I first used logrotate since the man page says: It will not modify a log multiple times in one day unless ...
1
vote
0answers
60 views

How to set one job to run at precise time with anacron without losing config at next upgrade?

I want logrotate to run at a precise time daily. Currently it is set to run at some random time using anacron and I don't want to change the randomness factor for all the other jobs. I have ...
1
vote
1answer
949 views

Log rotation in Linux

Whenever I execute ls command in /var/log directory, I could find log files, e.g. messages, and their rotated versions, e.g. messages.1.gz. Even though I am not using any utility like logrotate, how ...
1
vote
1answer
6k views

dateformat use in logrotate

cat /etc/logrotate.d/syslog ... /var/log/messages { daily compress dateext dateformat "-%Y%m%d-%s" maxage 90 rotate 90 missingok notifempty size +4096k create ...
0
votes
1answer
190 views

Logrotate doesn't rotate logs

I'm new to Linux, and I want to use logrorate. The logs are written to /var/log/curLog/log.log. As mentioned in the documentation, I create a new file in /etc/logrotate.d/ with name currentLog. The ...
3
votes
1answer
388 views

“tail -f” show old file after file has been rotated [duplicate]

I have a script running continuously, reading tail -f /var/log/daemon.log The problem is, when the file /var/log/daemon.log gets rotated by logrotate, tail still has "file handle" for the old ...
2
votes
0answers
277 views

Logrotate no longer reads symlinked configuration file due to non-root ownership

We are currently upgrading from Ubuntu 12.04 LTS to 14.04 LTS on our ruby on rails application servers, and have noticed that the log files are no longer rotating. On both machines we have a file ...
6
votes
1answer
839 views

Rotating log files while process still running

I have a process running that writes standard output and standard error to a log file /var/log/dragonturtle.log. Is there anyway to rotate the log file, and have the process continuing to write to the ...
2
votes
0answers
591 views

Permission denied when running logrotate with anacron

I am trying to figure out what is causing anacron to send me the following error message: /etc/cron.daily/logrotate: /var/log/mariadb/mariadb.log-20140710.gz: Permission denied error: error running ...
1
vote
0answers
268 views

logrotate error “error: error opening /home/web/logs/dev.log.10: No such file or directory”

In a run, sometimes I get such type of errors for any of the log file. Below is my configuration: /home/web/logs/*.log.* { missingok copytruncate olddir rotate rotate 5000 compress ...
2
votes
1answer
58 views

appendable and greppable archive on CentOS to hold many log files (logrotate on steroids)

I have a bunch of applications on a CentOS 6.3 box, which generate daily logs (text files with a very similar content) in this vein: /data/logs/app/my-2014-06-29.log ...