Bug 44665

Summary: Be kind to laptop users -- don't write to drive all the time
Product: [Retired] Red Hat Linux Reporter: Bryce Nesbitt <bryce>
Component: vixie-cronAssignee: Jason Vas Dias <jvdias>
Status: CLOSED NOTABUG QA Contact: Brock Organ <borgan>
Severity: medium Docs Contact:
Priority: medium    
Version: 7.1CC: bbrinkle
Target Milestone: ---Keywords: FutureFeature
Target Release: ---   
Hardware: i386   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2004-08-10 22:47:47 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 44666    

Description Bryce Nesbitt 2001-06-15 04:57:28 UTC
Hard drives use a lot of power, which is an issue on laptops.  RedHat 7.1
is not ideal on laptops -- the drive never gets a chance to spin down for
very long.  Something writes to the disk.  I've fixed this on my system,
and suggest RedHat does the same by default.

I suggest that RH make two small modifications for a "laptop" install.  The
first is in /etc/syslog,
change:
	cron.*
To 
	cron.warn
The logs you lose are not of any great value.  Anyone who needs
confirmation that cron has woken up can get it another way.

Comment 1 Bryce Nesbitt 2001-06-15 05:01:44 UTC
See also bug 44666

Comment 2 Bill Nottingham 2001-07-09 04:23:42 UTC
Um, vixie-cron never uses WARN messages, if I'm reading the source right. So,
are you suggesting that we dump *all* cron messages?

Comment 3 Bryce Nesbitt 2001-09-17 22:07:10 UTC
No.  I'm only suggesting that a single message be dumped, or maybe two.
Take an idle machine, and tail /var/log/cron.  You'll see a mind-numbing
list of thousands of identical entries:

	Sep 17 17:10:00 hardhat CROND[11435]: (root) CMD (   /sbin/rmmod -as)
	Sep 17 17:20:00 hardhat CROND[11470]: (root) CMD (   /sbin/rmmod -as)
	Sep 17 17:30:00 hardhat CROND[11481]: (root) CMD (   /sbin/rmmod -as)
	Sep 17 17:40:00 hardhat CROND[11780]: (root) CMD (   /sbin/rmmod -as)
	Sep 17 17:50:01 hardhat CROND[12058]: (root) CMD (   /sbin/rmmod -as)
	Sep 17 18:00:00 hardhat CROND[12072]: (root) CMD (   /sbin/rmmod -as)
	Sep 17 18:01:00 hardhat CROND[12079]: (root) CMD (run-parts 
/etc/cron.hourly)

Dump the periodic messages.  Leave any errors or true warnings.
Let the laptop (or desktop) go to sleep.

This is the only periodically written log I found.

Comment 4 Bill Nottingham 2002-03-12 21:36:16 UTC
The modutils cron entry isn't there in 7.2, FWIW.

Comment 5 Bryce Nesbitt 2002-03-13 13:31:54 UTC
Try setting a laptop (or desktop) to spin down the hard drive:
	hdparm -S5 /dev/hda
And see how long it stays spun down

Comment 6 Bryce Nesbitt 2004-01-17 15:23:51 UTC
Still present as of RH 7.3

Comment 7 Bryce Nesbitt 2004-01-17 16:32:37 UTC
It seems that RedHat has compiled cron NOT to use syslogd at all!  Is
there any way to get RedHat cron not to log?

Comment 8 Jens Petersen 2004-01-22 00:59:15 UTC
Do you mean you would prefer it to use syslogd?



Comment 9 Jens Petersen 2004-01-22 01:32:15 UTC
> Is there any way to get RedHat cron not to log?

It is a build option.

Comment 10 Jason Vas Dias 2004-08-10 22:47:47 UTC
vixie-cron-4.1-+ always logs with syslogd 
(by default, this is directed to /var/log/cron).
You can disable cron.* in /etc/syslog - you'll
need also to disable the auth.info messages 
generated from PAM for each cron job. 
You could also disable logging completely 
(don't run syslogd).
These are local configuration choices you can make -
the default configuration does not need to change.