Logrotate not occurring automatically
Clash Royale CLAN TAG#URR8PPP
up vote
0
down vote
favorite
I'm able to call logrotate /etc/logrotate.conf
whenever I see my log file exceed the specified threshold and it rotates just fine. I was under the impression though that whenever a file specified in the logrotate config breached its threshold it would rotate them automatically without me having to run the command.
/var/log/upstart/*server.log
size 2500M
missingok
rotate 5
compress
compress
notifempty
nocreate
Any ideas?
logs logrotate
add a comment |
up vote
0
down vote
favorite
I'm able to call logrotate /etc/logrotate.conf
whenever I see my log file exceed the specified threshold and it rotates just fine. I was under the impression though that whenever a file specified in the logrotate config breached its threshold it would rotate them automatically without me having to run the command.
/var/log/upstart/*server.log
size 2500M
missingok
rotate 5
compress
compress
notifempty
nocreate
Any ideas?
logs logrotate
add a comment |
up vote
0
down vote
favorite
up vote
0
down vote
favorite
I'm able to call logrotate /etc/logrotate.conf
whenever I see my log file exceed the specified threshold and it rotates just fine. I was under the impression though that whenever a file specified in the logrotate config breached its threshold it would rotate them automatically without me having to run the command.
/var/log/upstart/*server.log
size 2500M
missingok
rotate 5
compress
compress
notifempty
nocreate
Any ideas?
logs logrotate
I'm able to call logrotate /etc/logrotate.conf
whenever I see my log file exceed the specified threshold and it rotates just fine. I was under the impression though that whenever a file specified in the logrotate config breached its threshold it would rotate them automatically without me having to run the command.
/var/log/upstart/*server.log
size 2500M
missingok
rotate 5
compress
compress
notifempty
nocreate
Any ideas?
logs logrotate
logs logrotate
asked Nov 20 at 15:11
KuboMD
427
427
add a comment |
add a comment |
1 Answer
1
active
oldest
votes
up vote
3
down vote
accepted
Which files will be rotated is indeed specified in /etc/logrotate.conf
. But the command logrotate
still needs to be run. It can be run manually, but it is normally configured to be run daily by cron.
While it depends on the distro your using, this command will likely output if it is specified to be run periodically by cron:
find /etc/cron* -type f | xargs fgrep logrotate
So if it's a cron.daily, it could take up to 24hr after hitting the threshold to rotate?
– KuboMD
Nov 20 at 17:42
1
@KuboMD That is correct.
– Kusalananda
Nov 20 at 19:02
add a comment |
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
3
down vote
accepted
Which files will be rotated is indeed specified in /etc/logrotate.conf
. But the command logrotate
still needs to be run. It can be run manually, but it is normally configured to be run daily by cron.
While it depends on the distro your using, this command will likely output if it is specified to be run periodically by cron:
find /etc/cron* -type f | xargs fgrep logrotate
So if it's a cron.daily, it could take up to 24hr after hitting the threshold to rotate?
– KuboMD
Nov 20 at 17:42
1
@KuboMD That is correct.
– Kusalananda
Nov 20 at 19:02
add a comment |
up vote
3
down vote
accepted
Which files will be rotated is indeed specified in /etc/logrotate.conf
. But the command logrotate
still needs to be run. It can be run manually, but it is normally configured to be run daily by cron.
While it depends on the distro your using, this command will likely output if it is specified to be run periodically by cron:
find /etc/cron* -type f | xargs fgrep logrotate
So if it's a cron.daily, it could take up to 24hr after hitting the threshold to rotate?
– KuboMD
Nov 20 at 17:42
1
@KuboMD That is correct.
– Kusalananda
Nov 20 at 19:02
add a comment |
up vote
3
down vote
accepted
up vote
3
down vote
accepted
Which files will be rotated is indeed specified in /etc/logrotate.conf
. But the command logrotate
still needs to be run. It can be run manually, but it is normally configured to be run daily by cron.
While it depends on the distro your using, this command will likely output if it is specified to be run periodically by cron:
find /etc/cron* -type f | xargs fgrep logrotate
Which files will be rotated is indeed specified in /etc/logrotate.conf
. But the command logrotate
still needs to be run. It can be run manually, but it is normally configured to be run daily by cron.
While it depends on the distro your using, this command will likely output if it is specified to be run periodically by cron:
find /etc/cron* -type f | xargs fgrep logrotate
edited Nov 21 at 21:06
answered Nov 20 at 15:23
Hkoof
1,06768
1,06768
So if it's a cron.daily, it could take up to 24hr after hitting the threshold to rotate?
– KuboMD
Nov 20 at 17:42
1
@KuboMD That is correct.
– Kusalananda
Nov 20 at 19:02
add a comment |
So if it's a cron.daily, it could take up to 24hr after hitting the threshold to rotate?
– KuboMD
Nov 20 at 17:42
1
@KuboMD That is correct.
– Kusalananda
Nov 20 at 19:02
So if it's a cron.daily, it could take up to 24hr after hitting the threshold to rotate?
– KuboMD
Nov 20 at 17:42
So if it's a cron.daily, it could take up to 24hr after hitting the threshold to rotate?
– KuboMD
Nov 20 at 17:42
1
1
@KuboMD That is correct.
– Kusalananda
Nov 20 at 19:02
@KuboMD That is correct.
– Kusalananda
Nov 20 at 19:02
add a comment |
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f482991%2flogrotate-not-occurring-automatically%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown