On Fri, Oct 29, 2004 at 04:29:52AM -0500, Tommy Trussell wrote: > I'm running Debian kernel 2.6.8-powerpc, on a 1998 PowerBook G3 Series > "Wallstreet / PDQ." > > I've been trying to figure out why the hard drive would spin > constantly, regardless of what I do with the laptop-mode.conf > settings. Based on advice I read somewhere I installed metalog, > removed sysklogd and klogd, put the noatime parameter in /etc/fstab, > and tweaked my pbbuttonsd & laptop-mode settings.
Metalog by default doesn't instantly flush files out onto disk, the same effect can be achieved with syslog by by prepending a minus before the filename in /etc/syslog.conf. For debugging laptop-mode you can set /proc/sys/vm/block_dump to 1, which will ask the kernel to log which applications flushes out data so you can see in the log which application is spinning up the disk. > Even after all that, the drive never spun down AT ALL. At some point I > manually restarted /etc/init.d/laptop-mode, and after a delay, the > drive spun down. SO on a whim I changed the order they start up in > /etc/rc2.d by renaming S20laptop-mode to S21laptop-mode. This makes > S20pbbuttonsd start first and THEN S21laptop-mode. AFAIK pbbuttonsd still uses it's own version of laptop-mode (see /etc/power/pmcs-config), pbuttonsd uses scripts and configs files from /etc/power, it's actually another little init-script like system, with ac connected/battery mode instead of runlevels. Check out the README in that dir to learn how pbbuttonsd does stuff. > Now my drive spins down! Great! Except I don't understand why... it > seems like the loading order should be the other way around. > > I've also noticed that it doesn't seem to matter what spindown values > I put into laptop-mode.conf -- I have to manually set hdparm -S to > adjust the default spindown time. > I have it working better now, but I'd like to be sure I have it right. > Could another script or daemon override laptop-mode settings, or do I > have something broken? I think pbbuttonsd overrides those setting, try setting the variable *HDTimeOff in /etc/power/pmcs-config/ for the hdparm -S value. > Furthermore, I have apm_emu in /etc/modules and lsmod says something > is using it, though I was under the impression that pbbuttonsd does > not need it. What is using it? Pbuttonsd doesn't need apm emulation, maybe some (gnome) dock panel uses it, try fuser/lsof on the file to see which process uses it. > [I started to attach the contents of my /etc/rc2.d/ directory, output > from lsmod, and the contents of /etc/modules, > /etc/laptop-mode/laptop-mode.conf, and /etc/pbbuttonsd.conf -- but I > decided I would hold off on the listings until someone asked for > something more specific!] Johannes -- 3. The most fun you can have with your clothes on.
signature.asc
Description: Digital signature