• We’re currently investigating an issue related to the forum theme and styling that is impacting page layout and visual formatting. The problem has been identified, and we are actively working on a resolution. There is no impact to user data or functionality, this is strictly a front-end display issue. We’ll post an update once the fix has been deployed. Thanks for your patience while we get this sorted.

Linux power saving and mouse

Cerb

Elite Member
Is there a general way to (a) adjust the power saving used, and (b) a way to make activity from any input device wake it up (only mouse now, but as soon as I isolate that I'll want something else to work, too 😉)?

Preferably, I would like to adjust this without using GUI tools, as I find myself as plain-text terminals more and more often, and just keep getting more comfortable with VIM and Nano all the time.

My Googling thus far has been fruitless for this.
 
Which kind of power saving? Device power saving (D-states) or system power saving (S-states)?

Sometimes you can adjust ACPI wakeup settings in the BIOS. Otherwise, the only thing I can point you at is the file /proc/acpi/wakeup. I know that reports ACPI wakeup events, but I don't know if it can change them, and if so, I don't know the format for doing so.
 
As bersl2 said you can put the whole system into different ACPI states and have the firmware wake the system up on certain device activity. You might be able to power down some devices manually via some file in /sys, but I don't know how off the top of my head.
 
Originally posted by: bersl2
Which kind of power saving? Device power saving (D-states) or system power saving (S-states)?
I don't know. The monitor goes to a blank screen (but not standby, which Windowsd does). HDD power-off is disabled.
Sometimes you can adjust ACPI wakeup settings in the BIOS. Otherwise, the only thing I can point you at is the file /proc/acpi/wakeup. I know that reports ACPI wakeup events, but I don't know if it can change them, and if so, I don't know the format for doing so.
The BIOS hasn't seemed to work for that. It's set to wake on USB in the BIOS, but that doesn't seem to do it.

The behavior is the same in Debian Sarge (2.6.?) and SMGL (2.6.16.3). I'll tail /proc/acpi/wakeup and see what I can get.
 
I don't know. The monitor goes to a blank screen (but not standby, which Windowsd does). HDD power-off is disabled.

Those can be fixed fairly easily. First make sure DPMS is enabled in the monitor section of xorg.conf and set the various timeouts in xscreensaver. The hard disk spindown time can be set with 'hdparm -S <timeout> /dev/blah'. The only issue with that is the filesystem will probably keep the drive spun up, for example ext3 flushes metadata changes every 5s IIRC. Take a look at the laptop-mode package, it should calm down any filesystem activity.

 
HDD: power down is disabled in the BIOS, so I don't know if it is trying or not; should that have any effect on attempting to find what I'm looking for.
X: no X. Debian doesn't have it, and I manage to break stuff in SMGL regularly, and end up spending lots of time outside of it (currently, it's just the newest E17 segfaulting all over the place, and my being too lazy to build and configure a XFCE desktop 🙂). Due to a paper due monday, I probably won't boot into either Linux install until tomorrow night to check out /proc/acpi/*.
 
Originally posted by: Nothinman
I don't know. The monitor goes to a blank screen (but not standby, which Windowsd does). HDD power-off is disabled.

Those can be fixed fairly easily. First make sure DPMS is enabled in the monitor section of xorg.conf and set the various timeouts in xscreensaver. The hard disk spindown time can be set with 'hdparm -S <timeout> /dev/blah'. The only issue with that is the filesystem will probably keep the drive spun up, for example ext3 flushes metadata changes every 5s IIRC. Take a look at the laptop-mode package, it should calm down any filesystem activity.

One correction: hdparm -S interprets its parameter as a multiplier for 5 sec., except for some of the higher values, which alter the multiplier, and 254 is a vendor-defined period of time longer than the 253 setting. Or not.

From hdparm(8):
The encoding of the timeout value is somewhat peculiar. A value of zero means "timeouts are disabled": the device will not automatically enter standby mode. Values from 1 to 240 specify multiples of 5 seconds, yielding timeouts from 5 seconds to 20 minutes. Values from 241 to 251 specify from 1 to 11 units of 30 minutes, yielding time-outs from 30 minutes to 5.5 hours. A value of 252 signifies a timeout of 21 minutes. A value of 253 sets a vendor-defined timeout period between 8 and 12 hours, and the value 254 is reserved. 255 is interpreted as 21 minutes plus 15 seconds. Note that some older drives may have very different interpretations of these values.
 
HDD: power down is disabled in the BIOS, so I don't know if it is trying or not; should that have any effect on attempting to find what I'm looking for.

By default Linux won't set your drives to power down, the BIOS setting has no effect on this AFAIK.

One correction: hdparm -S interprets its parameter as a multiplier for 5 sec., except for some of the higher values, which alter the multiplier, and 254 is a vendor-defined period of time longer than the 253 setting. Or not.

To be pedantic I said timeout, not seconds. =)
 
My problem is much more not knowing what I'm really looking for (I know the effect I want, but nothing that causes it), and have no real knowledge of how any power saving works. Details like multiples of 5 seconds are why there are man pages and --help screens.

BTW, while I haven't tested anything yet, "/proc/acpi" has given some potentially good hits from Google (I'll need to hop over to the other OSes to be sure).
 
Think you need the acpi deamon to really play arround with it
Laptop-mode-utils are good for messing with harddrive spindown
To play arround with processor scaling, you need an application... there are lots not sure about which ones are good.
 
Think you need the acpi deamon to really play arround with it

The acpid daemon is only there to react to ACPI events, like hitting the power button, shutting the lid, etc.

To play arround with processor scaling, you need an application... there are lots not sure about which ones are good.

Not really, there are cpufreq modules like cpufreq_ondemand that will scale the processor for you without any application's help. You only need a daemon if you want to be able to take things like CPU load into account when scaling the CPU, AFAIK the kernel modules only take into account whether or not the CPU is wanted by something 'now'.
 
Originally posted by: Nothinman
To play arround with processor scaling, you need an application... there are lots not sure about which ones are good.

Not really, there are cpufreq modules like cpufreq_ondemand that will scale the processor for you without any application's help. You only need a daemon if you want to be able to take things like CPU load into account when scaling the CPU, AFAIK the kernel modules only take into account whether or not the CPU is wanted by something 'now'.

I thought he meant to control it manually, a lot of laptops will do some scaling even if the OS doesnt support, albiet not very efficiently. I thought he meant to force it into a higher power state, btw how the hell do I do that with XP? It'd be nice to stop it from scaling sometimes.
 
Nope. It's a desktop. I'm used to waking it up with the mouse, and just want that to work in BASH like it works when X is running, and works in Windows.
 
I thought he meant to control it manually, a lot of laptops will do some scaling even if the OS doesnt support, albiet not very efficiently. I thought he meant to force it into a higher power state, btw how the hell do I do that with XP? It'd be nice to stop it from scaling sometimes.

If neither the BIOS or the drivers from the vendor have a way to disable I'd say you're screwed.

Nope. It's a desktop. I'm used to waking it up with the mouse, and just want that to work in BASH like it works when X is running, and works in Windows.

Well shutting off the monitor without X running might be difficult, I know you can set a blank timeout with 'setterm -blank' but I don't think that'll shut the monitor down. A quick look in apt suggests that vbetool might be able to put the monitor to sleep, but you'd probably have to do it manually if it works.
 
The monitor already goes off after some period (10/15 min?). It doesn't get turned off (well, standby), but it is being blanked. I'm interested in waking it up, because every single time I go and wiggle the mouse, then after several seconds realize that won't do it. Every single time. So all I want is for that action to get something back on the display, when at a BASH terminal.

Anyway, I'll be checking it out later today.
 
Back
Top